REST properties
Properties to configure to be able to send an HTTP request to the server end and get the corresponding response information from the server end.
The underlying HTTP client used by the connector is the default HTTP client that is embedded within Java.
REST connection
Select REST in the list and configure the connection.
Configuration
Select your engine from the list and set the main and advanced settings.
Property | Configuration |
---|---|
Base URL | Type in the URL address of the REST Web server to be invoked. |
Authentication | Select the way you want to authenticate to the server:
|
Property | Configuration |
---|---|
Connection timeout (ms) | Sets the maximum number of milliseconds that a user will wait for a connection to be available. If this time is exceeded and the connection is still unavailable, an exception is thrown. |
Connection timeout (ms) | Sets the maximum waiting time in milliseconds for a connection to be considered as alive. An exception will occur if the timeout expires before there is data available to read. |
After configuring the connection, give it a display name (mandatory) and a description (optional).
REST dataset
Property | Configuration | |
---|---|---|
Dataset name | Enter a display name for the dataset. This name will be used as a unique identifier of the dataset in all Talend Cloud apps. | |
Connection | Select your connection in the list. If you are creating a dataset based on an existing connection, this field is read-only. | |
Type | Select the type of dataset you want to create:
|
Property | Configuration |
---|---|
Resource | Enter the HTTP resource you want to consume from the REST API. |
HTTP method | Select the HTTP request method in the list. |
Answer body format | Select the body format of the message that you will receive as a
response from the server end:
|
Query parameters | Specify the URI query parameters in the form of name-value pairs. |
Property | Configuration |
---|---|
Get status and headers | Enable this option to request both the status and headers. By default, only the body is returned. |
Maximum number of redirects | Set the maximum number of redirects that the connector should follow. If you enter 0, no redirection is done. If you enter -1, the restriction gets deactivated. |
Redirect only on same host | Enable this option if you want redirections to be performed only when using the same host. |
Force GET method for 302 redirection | Enable this option to send the redirection request with the GET method if the redirection code is 302. |
Local network access
By default, the Remote Engine Gen2 is configured to prevent the REST connector from accessing services inside the Remote Engine Gen2, and thus your local network URLs.
- open this file to edit it:
default/docker-compose.yml if you are using the engine in the AWS USA, AWS Europe, AWS Asia-Pacific or Azure regions.
eap/docker-compose.yml if you are using the engine as part of the Early Adopter Program.
- find these parameters in both the
CONNECTORS_ENABLE_LOCAL_NETWORK_ACCESS: "true" CONNECTORS_ENABLE_MULTICAST_NETWORK_ACCESS: "true"
, and sections of the file and change the value to true: - save your changes and restart the Remote Engine Gen2 to take these changes into account.