Skip navigation links

Oracle Communications Services Gatekeeper OAM Java API Reference
6.0

E55516-02


com.bea.wlcp.wlng.log.management
Interface TraceServiceMBean


public interface TraceServiceMBean

Field Summary
static boolean aspectTracingEnabled
          Aspect Tracing enabled, disable to improve log4j performance.
static boolean tracingEnabled
          Specifies whether trace should be enabled or not.

 

Method Summary
 void addContextCategory(String identifier, String category)
          Adds a category to an existing context trace file.
 void addContextFilter(String identifier, String type, String value)
          Adds one of the predefined filter types to the appender with the identified name.
 void attachAppender(String loggerName, String appenderName)
          Allows adding a named appender to named loggers.
 void attachAppenderInternal(Logger logger, String svcName)
          Internal operation that creates a FileAppender that outputs to a file with the same name as the service.
 void createContextTraceFile(String identifier, String category, String threshold)
          Creates a context trace file under root trace directory.
 void createRootContextTraceFile(String identifier)
          Creates a new root context trace file.
 void createTraceDir()
          Internal method used to create the trace directory.
 void flushBuffers()
          Flushes log buffers.
 boolean getAspectTracingEnabled()
           
 boolean getTracingEnabled()
           
 void initialize()
          Internal method to create any schema required and initialize persisted or default values.
 void removeContextTraceFile(String identifier)
          Removes a context trace file.
 void resetContextFilters(String identifier)
          Removes all filters associated with a context trace file.
 void rollOver()
          Rotates log files.
 void setAspectTracingEnabled(boolean flag)
          Scope: Cluster
 void setTracingEnabled(boolean flag)
          Scope: Cluster

 

Field Detail

aspectTracingEnabled

public static final boolean aspectTracingEnabled
Aspect Tracing enabled, disable to improve log4j performance.

Scope: Cluster

See Also:
Constant Field Values

tracingEnabled

public static final boolean tracingEnabled
Specifies whether trace should be enabled or not. True to enable, false to disable.

Scope: Cluster

See Also:
Constant Field Values

Method Detail

addContextCategory

public void addContextCategory(String identifier,
                               String category)
                        throws ManagementException
Adds a category to an existing context trace file.

Scope: Cluster

Parameters:
identifier - Identifier of the context trace file.
category - The Log4J category. The category is the package name, including subpackages, to trace on. For example, to trace on the SMPP plug-in, enter com.bea.wlcp.wlng.plugin.sms.smpp.
Throws:
ManagementException

addContextFilter

public void addContextFilter(String identifier,
                             String type,
                             String value)
                      throws ManagementException
Adds one of the predefined filter types to the appender with the identified name. The filter is a name/value pair, where the type identifies the filter type to use, and the value is the value of the filter. All trace information that matches the filter is written to the context trace file. When the Trace service receives information about a request, it checks if the request matches the context filter. If it matches, the trace information is written to file. All filters must match for the trace to be written.

Examples:
To add a filter that matches all requests from service provider ID SP1, set the type to SERVICE_PROVIDER and the value to SP1. To add a filter that matches all requests from application ID APP1, set the type to APPLICATION and the value to APP1.

Scope: Cluster

Parameters:
identifier - Identifier of the context trace file.
type - One of the defined types: SERVICE_PROVIDER, APPLICATION, APPLICATION_INSTANCE, SESSION, TRANSACTION.
value - Value to filter on for this filter type.
Throws:
ManagementException

attachAppender

public void attachAppender(String loggerName,
                           String appenderName)
Allows adding a named appender to named loggers. Each Services Gatekeeper internal service has a default FileAppender that outputs to a file with the same name as the Services Gatekeeper internal service.

Scope: Cluster

Parameters:
loggerName - Logger name.
appenderName - Name of Services Gatekeeper internal service to attach the appender to.

attachAppenderInternal

public void attachAppenderInternal(Logger logger,
                                   String svcName)
Internal operation that creates a FileAppender that outputs to a file with the same name as the service.

Scope: Cluster

Parameters:
logger - Logger.
svcName - Service name.

createContextTraceFile

public void createContextTraceFile(String identifier,
                                   String category,
                                   String threshold)
                            throws ManagementException
Creates a context trace file under root trace directory.

Scope: Cluster

Parameters:
identifier - Identifier to be used to add filters and will also result in a file named \"identifier.log\". Must be unique to the managed server.
category - Log4J category.
threshold - Log level threshold. Valid values are OFF, FATAL, ERROR, WARN, INFO, DEBUG, TRACE and ALL.
Throws:
ManagementException

createRootContextTraceFile

public void createRootContextTraceFile(String identifier)
                                throws ManagementException
Creates a new root context trace file. Adds a context trace file under root trace directory and associates it with the root logger.

Scope: Cluster

Parameters:
identifier - Identifier to be used to add filters and will also result in a file named \"identifier.log\". Must be unique per managed server.
Throws:
ManagementException

createTraceDir

public void createTraceDir()
Internal method used to create the trace directory.

Scope: Cluster


flushBuffers

public void flushBuffers()
Flushes log buffers. This method only has an effect on FileAppenders or subclasses.

Scope: Cluster


getAspectTracingEnabled

public boolean getAspectTracingEnabled()

getTracingEnabled

public boolean getTracingEnabled()

initialize

public void initialize()
                throws ManagementException
Internal method to create any schema required and initialize persisted or default values.

Scope: Cluster

Throws:
ManagementException

removeContextTraceFile

public void removeContextTraceFile(String identifier)
                            throws ManagementException
Removes a context trace file.

Scope: Cluster

Parameters:
identifier - Identifier of the context trace file.
Throws:
ManagementException

resetContextFilters

public void resetContextFilters(String identifier)
                         throws ManagementException
Removes all filters associated with a context trace file.

Scope: Cluster

Parameters:
identifier - Identifier of the context trace file.
Throws:
ManagementException

rollOver

public void rollOver()
Rotates log files. This invokes the rollOver() method on all registered RollingFileAppenders.

Scope: Cluster


setAspectTracingEnabled

public void setAspectTracingEnabled(boolean flag)
                             throws ManagementException

Scope: Cluster

Parameters:
flag - Flag to enable or disable aspect tracing.
Throws:
ManagementException

setTracingEnabled

public void setTracingEnabled(boolean flag)
                       throws ManagementException

Scope: Cluster

Parameters:
flag - Flag to enable or disable tracing.
Throws:
ManagementException

Skip navigation links

Oracle Communications Services Gatekeeper OAM Java API Reference
6.0

E55516-02


Copyright © 2008, 2015, Oracle and/or its affiliates. All rights reserved.