Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add server configurations guidelines to WSO2 IS documentation #4766

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
49 changes: 49 additions & 0 deletions en/includes/guides/customize/actions/setting-up-actions.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,3 +70,52 @@ The following are some of the troubleshooting steps that you may take to resolve
1. Ensure that your external service is up and running and that there are no connectivity issues.

2. Confirm that the request and response payloads conform to the expected formats as defined by the REST API contract.

## Configuring HTTP Client Connections

You can configure the HTTP connection settings in the deployment.toml file located in `<IS_HOME>/repository/conf/` to fine-tune connections initiated by WSO2 Identity Server to external services implementing actions.

<table>
<thead>
<tr class="header">
<th>Property</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr class="odd">
<td>http_client.read_timeout</td>
<td>
<p>Configures the maximum time (in milliseconds) the server will wait for a response from the external service</p>
</td>
</tr>
<tr class="even">
<td>http_client.request_timeout</td>
<td><p>Configures the time (in milliseconds) to wait for obtaining a connection from the connection pool</p></td>
</tr>
<tr class="odd">
<td>http_client.connection_timeout</td>
<td><p>Configures the timeout (in milliseconds) for establishing a connection to the external service</p></td>
</tr>
<tr class="even">
<td>http_client.connection_pool_size</td>
<td><p>Configures the size of the HTTP connection pool used for outbound requests</p></td>
</tr>
<tr class="odd">
<td>http_client.retry_count</td>
<td><p>Determines the number of retry attempts are made in case of connection failures. <a href="{{base_path}}/guides/customize/actions/understanding-actions/#time-out-and-retry">Explore more for allowed status codes</a> where retries can happen</p></td>
</tr>
</tbody>
</table>

Sample configuration is as follows:

```toml
[actions]
http_client.read_timeout = 6000
http_client.request_timeout = 3000
http_client.connection_timeout = 3000
http_client.connection_pool_size = 10
http_client.retry_count = 1

```
5 changes: 3 additions & 2 deletions en/includes/guides/customize/actions/understanding-actions.md
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,6 @@ The following diagram illustrates the sequence of these steps:
<td>requestId</td>
<td><p>A unique correlation identifier that associates the request received by {{product_name}}.</p></td>
</tr>
</tr>
<tr class="odd">
<td>actionType</td>
<td><p>Indicates the execution point within the {{product_name}} runtime where your external service is called. Refer to <a href="#explore-action-types">Explore Action Types</a> for a list of supported trigger points.</p></td>
Expand Down Expand Up @@ -163,7 +162,6 @@ If the error response includes an acceptable payload, it is treated as an error
<td>502</td>
<td><p>Bad Gateway.</p></td>
</tr>
</tr>
<tr class="odd">
<td>503</td>
<td><p>Service Unavailable.</p></td>
Expand All @@ -175,6 +173,9 @@ If the error response includes an acceptable payload, it is treated as an error
</tbody>
</table>

!!! note
Refer to [Configuring HTTP Client Connections]({{base_path}}/guides/customize/actions/setting-up-actions/#configuring-http-client-connections) to adjust timeouts, connection pooling, and retries in deployment.toml for optimal performance.

Requests will not be retried if the external service responds with HTTP status codes 200 (OK), 400 (Bad Request), 401 (Unauthorized), or any other codes not listed above as retry scenarios.

### Troubleshooting
Expand Down