Types of Handlers
This page details each type of handler and what they are used for in an event stream.
Kafka​
The Kafka handler allows you to send source event data from your event stream to a specified Kafka topic. This handler is configurable with the following properties.
Kafka Handler Property | Type | Description |
---|---|---|
Connector | String | The name of the Kafka connector to send event data to. |
Topic | String | The name of the Kafka topic to send event data to. |
Partition | String | The partition to send event data to. |
Timestamp | String | The timestamp of the Kafka record. |
Key | String | The key of the Kafka record. |
Value | String | The value produced to send to the specified Kafka connector. |
Headers | PyDictionary | Allows a user to specify metadata information about the produced record's message payload, as key value pairs. |
Additional Producer Properties | PyDictionary | Allows a user to specify any other producer properties you want to add, as key value pairs. See the official Kafka documentation for available producer configurations. |
Database​
The database handler allows you to send source event data from your event stream to a specified SQL database. This handler is configurable with the following properties.
Database Handler Property | Type | Description |
---|---|---|
Database | String | The database you want to send the data to. The dropdown menu will be populated with available database connections defined in the Gateway. |
Mode | Enum | The action you want performed on the data. Selections in the dropdown menu include:
|
Table Name | String | The table in the database you want to store data to. The dropdown menu will be populated with available tables found in your database connection(s). You can also manually enter a table name and use the Automatically Create Table property to create a new table. |
Automatically Create Table | Boolean | Whether or not a new table with the required columns should be created using the entered table name. Default is enabled. |
Store timestamp to | Boolean | Whether or not a timestamp should be recorded to the specified column. If enabled, the system will use the system clock to generate the timestamp. You can choose a column from the dropdown menu, or manually create a column by manually entering a column name. |
Bypass Store and Forward System | Boolean | Whether or not the Store and Forward system should be used. Enabling this property will cause the database handler to ignore Store and Forward. Default is disabled. |
Column Mapping | User Defined | Allows a user to specify which SQL column(s) data should be mapped to using the column name, SQL column type, and value. This table will be used in conjunction with the Mode property's INSERT option. |
Where Clause Configuration | User Defined | Allows a user to specify where in the SQL table data should be updated by providing the column name, logical operator, and value. This table will be used in conjunction with the Mode property's UPDATE option. |
HTTP​
The HTTP handler sends POST and PUT requests to a specified URL. The HTTP handler is configurable with the following properties.
HTTP Handler Property | Type | Description |
---|---|---|
URL | String | The destination URL to sent the HTTP request to. |
Type | Enum | The HTTP request type you are using. Options include:
|
Headers | List | The headers you want to include as part of the HTTP request. Values will be entered in the table using key value pairs as strings, with the header type as the key. |
Body | Byte | The payload included as part of the HTTP request. This data will be encoded to byte format. |
Connect Timeout | Int | The amount of time to wait before the HTTP request times out, in milliseconds. Default is 30,000. |
Cookies Enabled | Boolean | Whether or not cookies should be enabled. A value of True will use cookies, while False will not. Default is True. |
Gateway Event​
The Gateway Event handler sends events to a different event stream. Note that the receiving event stream must have an Event Listener source configured in order to receive this event. You can define the destination of your event with the following properties.
Gateway Event Handler Property | Type | Description |
---|---|---|
Project | String | The destination project containing the event stream that the event will be sent to. You can use the dropdown menu to select your project, or use an expression to define the destination project. |
Path | String | The destination event stream that the event will be sent to. The dropdown menu will list available event streams defined within the specified project. You can also use an expression to define the path, allowing you to send events to different event streams. |
Payload | PyDictionary | The payload that is to be sent to the destination event stream. You can also use an expression to create a dynamic payload. |
Remote Gateway Name | String | The name of the remote Gateway to send events to. |
Gateway Message​
The Gateway Message handler mimics the sendMessage system function by sending a message to a targeted Gateway. The Gateway Message handler is configurable with the following properties.
Gateway Message Property | Type | Description |
---|---|---|
Project | String | The project you want to send the Gateway Message's payload to. You can use the dropdown menu to select your project, or use an expression to define the destination project. |
Message Handler | String | The name of the message handler in the Gateway Message you want to send. |
Payload | PyDictionary | The data that will be passed onto the message handler. |
Properties | PyDictionary | Allows you to specify other properties that are part of the system.util.sendMessage function, using key value pairs. Available parameters include:
|
Logger​
The logger handler logs a message to the logging system when events arrive. This handler is configurable with the following properties.
Logger Handler Property | Type | Description |
---|---|---|
Name | String | The name of your logger. You can use a simple string, or use an expression to name your logger. |
Log Level | Enum | The log level used by your logger handler. Available options include:
|
Messages | String | The message you want logged with the logging system. You can input a simple string, or use an expression to define your message. |
Script​
The script handler allows users to customize how they want to handle incoming events by executing the defined script when events arrive. The payload output from this script will be a PyObject type.
Tag​
The tag handler takes data from the event stream's source and writes the data to a specified tag. The tag handler is configurable with the following properties.
Tag Handler Property | Type | Description |
---|---|---|
Tag Path | String | The tag path to use when determining which tag to write to. You can use an expression to specify a dynamic tag path based on the event payload. |
Value | String | The value you want to write to the tag from the payload of the source event object. You can use an expression to break down the payload into individual data or metadata. See the Source Data and Metadata page for more information. |
Quality | String | The quality to write to the tag as a string. You can use an expression to write a dynamic quality. |
Timestamp | String | The timestamp to write to the tag. You can write a dynamic timestamp using an expression. |