Tracing Event Publishing
Event publishing means actions are taken that are invisible. So when no event arrives and no error is reported, you don’t know what happened. Was the event generated by the application correctly? Did the event action match the subscription? Was it skipped because of the filter or selection that was used?
To answer such questions, the tracing facility is available. When switching on tracing, a file is created showing the event publishing activity and the objects being processed. The file contents will indicate any publisher activity and any events being processed and/or sent. It will also be visible if an event message does not match the event actions, filter or selection from the subscription. The trace file includes the Show request that is used to get the component instances and attribute values for an event. In case the Show fails or gives unexpected results, you can use that request in the LN Studio Test Tool to test or debug the Show method using the same selection and filter.
To switch on tracing, add the following setting in your BW configuration:
-set_BOL_PUBLISHER_TRACE=/tmp/ trace_publisher
After the ‘=’, specify the file where you want the trace to be written. Make sure that you have sufficient permissions to write a file in that location.
If you want to trace the detection of standard events and the actual publishing of all events, you must set this in the BW that receives the SubscribeEvent request. If you want to trace application-specific events, you must also set this in the BW where you run the application process that publishes the event. You can use two different file names, if you wish.
- If a bshell is already running for a BDE and a SubscribeEvent request is received for the same company and destination, then the publishing for the second BDE will get the same trace settings as the first one, because it is done by the same bshell.
- If all publishers for a company are stopped and a user reactivates them through the tlbct5500m000 session, then the trace setting from that user’s BW configuration is used.
Note that this allows you to change the trace settings without re-subscribing: simply start BW using the desired trace setting, then stop all publishers for a company through the tlbct5500m000 session and then reactivate them again. You need to stop all publishers for a company before reactivating them again, in order to stop the bshell! After that the user’s trace settings are used.