Sunday, October 9, 2016

OWSM Log Policy

During development/debugging you are required to view the input/output SOAP messages within your SOA environment.

One of the ways to do this is viewing the message in the EM console. Another way is to enable oracle/log_policy. Enabling the policy will write all the input/output messages to diagnostic logs which is very helpful at time. The following are the steps to enable log policy

1. Attaching Log Policy to Service
2. Increasing the log level associated with the log policy.


1) Attaching Log Policy.

a. Click on the composite which contains the service against which you want to enable the logs.

 b. Click on Policy Configuration. Click on Attach/Detach Policy.

c. Select oracle/log_policy and attach it. Click on Validate and then Ok to save it.
















2) The next step is to increasing the log level associated with the log policy.

a. For this go to SOA Infrastructure->Logs->Logs configuration



b. Select View as "Loggers with Persistent log level State" & change the log level of oracle.owsm.msg.logging to Trace:32 (Finest)

































c. On saving it you would be getting confirmation of the changes.






















d. Click on the log file tab in the lab configuration screen. Here you can check to which location the log file is getting created.















Test the log policy by executing a test request. You should be able to see the SOAP Request/Response of the service against which you have associated the log policy.