Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.
Difference between revisions of "BaSyx / Documentation / Components / DataBridge / Features / Request"
(Created page with "= Request = The Request trigger is used to generate message exchanges on demand. The routes would be triggered when a request is made on the configured REST endpoint and the p...") |
|||
Line 22: | Line 22: | ||
] | ] | ||
</pre> | </pre> | ||
− | |||
− | |||
<span style=color:red>Disclaimer: The endpoint configured with trigger data accepts only the GET request. </span> | <span style=color:red>Disclaimer: The endpoint configured with trigger data accepts only the GET request. </span> | ||
+ | |||
+ | == Working Example == | ||
+ | The integration example with '''request triggered''' HTTP as a data source, JsonAta as a transformer is available on [https://github.com/eclipse-basyx/basyx-databridge/tree/main/basyx.components.databridge.examples/basyx.components.databridge.examples.httppolling-jsonata-delegator GitHub DataBridge Example]. |
Revision as of 07:02, 1 February 2023
Contents
Request
The Request trigger is used to generate message exchanges on demand. The routes would be triggered when a request is made on the configured REST endpoint and the processed data will be returned as a response.
Configuration
You can specify "trigger": "request" in routes.json [Link] configuration file. Apart from this, you have to specify the trigger data in routes.json. This trigger data comprises of the host, port, and the service path, basically this would be the endpoint when requested, triggers the specified route, and return the processed data as a response.
Sample Route Configuration with Timer
[ { "datasource": "httpsource", "transformers": [ "jsonataA" ], "trigger": "request", "triggerData": { "host": "localhost", "port": "8090", "path": "/valueA" } } ]
Disclaimer: The endpoint configured with trigger data accepts only the GET request.
Working Example
The integration example with request triggered HTTP as a data source, JsonAta as a transformer is available on GitHub DataBridge Example.