Network Deployment (Distributed operating systems), v8.0 > Reference > Troubleshoot tips


Log Common Base Events in WAS

The following practices ensure consistent use of Common Base Events within your components, and between your components and WAS components.

Follow these guidelines:

The following sample Logger.properties file entry demonstrates how to associate the com.ibm.componentX logger with the com.ibm.componentX event factory:

com.ibm.componentX.eventfactory=com.ibm.componentX

The following sample code demonstrates the use of the same event factory setting for direct (Part 1) and indirect (Part 2) Common Base Event logging:

<?xml version="1.0" encoding="UTF-8"?>

<TemplateEvent>
  version="1.0.1"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance
  xsi:noNamespaceSchemaLocation="templateEvent.xsd">

<CommonBaseEvent>

<sourceComponentId application="My application" component="com.ibm.componentX"/>
<extendedDataElements CommonBaseEventname="Sample ExtendedDataElement name" type="string">
<values>Sample ExtendedDataElement value </values>
</extendedDataElements>
< /CommonBaseEvent>

< /TemplateEvent>

Log with Common Base Event API and the Java logging API
Log Common Base Events in WAS
Add logging and tracing to the application

+

Search Tips   |   Advanced Search