The logger event publisher logs the output events in XML, text, and JSON formats.
Creating a logger event publisher
For instructions on creating a logger event publisher, see Publishing Events .
Configuring adapter properties
Specify the Dynamic Adapter Properties, when creating a logger event publisher using the management console as shown below.
After entering the above adapter properties, select the Message Format which you want to apply on the published events . Also, click Advanced to define custom output mappings based on the Message Format you selected. For more information on custom output mapping types, see Output Mapping Types.
You can also d efine the respective adapter properties of the event publisher based on the transport type within the <to>
element of the event publisher configuration in the <PRODUCT_HOME>/repository/deployment/server/eventpublishers/
directory as follows.
<eventPublisher name="LoggerOutputEventAdapter" statistics="disable" trace="disable" xmlns="http://wso2.org/carbon/eventpublisher"> .................... <to eventAdapterType="logger"> <property name="uniqueId">log_id</property> </to> </eventPublisher>
The above adapter properties are described below.
Adapter Property | Description | Configuration file property | Example |
---|---|---|---|
Unique Identifier | A string of characters to uniquely identify a log entry | uniqueId | log_id |