Apama 10.3 | Apama Documentation | Connecting Apama Applications to External Components | Standard Connectivity Plug-ins | Codec Connectivity Plug-ins | The Diagnostic codec connectivity plug-in
The Diagnostic codec connectivity plug-in
The Diagnostic codec can be used to diagnose issues with connectivity plug-ins. It logs the events that go through a connectivity chain in either direction.
To reference the Diagnostic codec, an entry such as the following is required in the connectivityPlugins section of the configuration file (see also Configuration file for connectivity plug-ins):
libraryName: DiagnosticCodec
class: DiagnosticCodec
You can then add the diagnosticCodec at any point in a connectivity chain. With no further configuration, the codec logs to the correlator log file at INFO level.
An example configuration may look as follows:
- apama.eventMap
- diagnosticCodec:
tag: host
output: logger
logLevel: DEBUG
- myCodec # the codec being inspected
- diagnosticCodec:
tag: transport
output: logger
logLevel: DEBUG
- myTransport
The following configuration options are available:
Configuration option
tag: string
If a chain has multiple diagnosticCodec instances, you can specify a tag for each instance to distinguish it from other instances. string is the tag that is used to prefix the messages from the current instance. Default: empty.
output: mode
Defines the file to which the codec logs its output. mode can be one of the following:
*logger - Default. The codec logs to the correlator log file at the log level that is defined with logLevel.
*file - The codec logs to the file that is defined with fileName.
logLevel: level
Applies when the logger mode is defined. level can be any correlator log level. Default: INFO.
fileName: file
Applies when the file mode is defined. file is either the path to a file or one of the special strings stdout or stderr. Default: stdout.
When writing to the correlator log file, the Diagnostic codec replaces any non-printable ASCII characters (those with ASCII values less than 0x20, which includes tab and newline) with an underscore (_) character.

Copyright © 2013-2018 | Software AG, Darmstadt, Germany and/or Software AG USA, Inc., Reston, VA, USA, and/or its subsidiaries and/or its affiliates and/or their licensors.