Trigger execution via a TCP server is performed in the following steps:
- Start the Gravity.exe application.
- Add a TCP connection.
- Create a project (option PROJECTS). If you want to pass data received by the TCP server to the project, the project should contain a parameter of type text or binary, depending on the type of data received. Returning data from the project to the client is handled by the
OUTPUT TCP operator.
- Add a Socket-type trigger (the TRIGGERS option). GRAVITY will create a TCP server based on the selected server definition.
- Start the GravityTriggersRunner.exe server application or restart the gravity.integration service.
The project will be triggered when a TCP message is sent by a client to the server address and port specified in the trigger configuration.
Because GRAVITY creates a separate TCP server for each defined trigger, each Socket-type trigger must be configured with a different TCP connection.