HTTP event adapter is an internal event adapter that comes with WSO2 products. By default, it listens to requests on port 9763.
Configuring input HTTP event adapter
You can configure the input HTTP adapter using the management console or using a configuration file.
Configure using the management console
Follow the instructions below to configure input HTTP event adapter using the management console. This deploys the event adapter in the <PRODUCT_HOME>
/
repository/
deployment/
server/
inputeventadaptors/
directory.
- Log in to the product's management console, and click Configure.
- Click Input Event Adaptors in the Event Processor Configs menu, and then click Add Input Event Adaptor.
- Enter details as shown in the below example.
- Click Add Event Adaptor.
Configure using a configuration file
Follow the instructions below to configure input HTTP event adapter using a configuration file.
Create an XML file with the following input HTTP event adaptor configurations. Input event adapter implementation must start with
<inputEventAdaptor>
as the root element.<inputEventAdaptor name="httpInputAdaptor" statistics="disable" trace="disable" type="http" xmlns="http://wso2.org/carbon/eventadaptormanager"/>
Add the XML file to the
<PRODUCT_HOME>/repository/deployment/server/inputeventadaptors/
directory. Since hot deployment is enabled, you can simply add/remove files to deploy/undeploy to/from the server.
After an adapter is successfully added, it gets added to the list of adapters displayed under Event Processor Configs in the Configure menu of the product's management console. Click Edit to change its configuration and redeploy it. This opens an XML-based editor allowing you to edit the event adapter configurations from the UI. Do your modifications and click Update. You can also delete it, enable/disable statistics or enable/disable tracing on it using the provided options in the UI.
After you deploy the input HTTP event adapter, the endpoints to receive incoming events will be available in the following URLs:
- For super tenants -
http://localhost:9763/endpoints/<input_adaptor_name>/<topic>
orhttps://localhost:9443/endpoints/<input_adaptor_name>/<topic>
- For other tenants -
http://localhost:9763/endpoints/t/<tenant_domain>/<input_adaptor_name>/<
topic>
orhttps://localhost:9443/endpoints/t/<tenant_domain>/<input_adaptor_name>/<topic>
Configuring input HTTP event adapter message properties
The configured input event adapters are used in event builders. With input event adapter message properties, event builders are able to extract data from the incoming events to build the event streams. Message Properties specific to input event adapters of the http
type can be configured as follows.
- Log into the CEP Management Console. For detailed instructions, see Running the Product.
- Click the Inflows link of the event stream to which the relevant input event adapter is connected. As a result, Event In-Flows (<Input_Event_Adapter_Name>) opens.
Click on the relevant event builder name to open the Event Builder Details page.
The message properties of anhttp
input event adapter are described below.Property Description Topic The topic that will be used to receive messages on the HTTP input adapter Input Mapping Type The incoming event type to be mapped