Configuring logging for loggers created within a custom application.

Configuring logging for loggers created within a custom application.

book

Article ID: KB0090670

calendar_today

Updated On:

Products Versions
TIBCO ActiveMatrix Service Grid -
Not Applicable -

Description

Description:
Steps to configure logging for loggers created within a custom application are listed below.

Issue/Introduction

Configuring logging for loggers created within a custom application.

Resolution

1. Add a logger, for example 'HelloWorldLogger", to a TIBCO service-oriented architecture(SOA) application's Java component implementation. For more details, refer to the TIBCO ActiveMatrix Service Grid 3.3.0 documentation > Composite Development>  Application Logging.


2). Using the TIBCO Activematrix Administrator GUI, deploy the application to a TestNode.

 

3). Create a new file based appender. For example, "HelloWorldLoggerAppender" from the Administrator GUI (Shared Object>Logging Appender).


4). In Administrator, create a new logging configuration for the application.


    a). Select the application name from "Applications" and click on Configuration> Logging> Uncheck "Use the node's logging configuration".


    b). Click "Add" and type in the logger name "HelloWorldLogger".


    c). Click on 'Set Appender" and select the appender "HelloWorldLoggerAppender" created in step 3 and also assign a logging level.


    d). "Save and apply" the changes.


Note: You can also accept the default logging configuration ("Use the node's logging configuration") which is to use the logging configuration of the node on which the component is deployed. In this case, logs are written based on the settings given under "root" logging configuration for the node ("root" logger configuration in Infrastructure> Nodes>"TestNode">Configuration> Logging).