[jbossws-issues] [JBoss JIRA] (JBWS-3586) Message log browser functionality

Jim Ma (JIRA) issues at jboss.org
Fri Sep 18 04:33:00 EDT 2015


    [ https://issues.jboss.org/browse/JBWS-3586?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13110310#comment-13110310 ] 

Jim Ma edited comment on JBWS-3586 at 9/18/15 4:32 AM:
-------------------------------------------------------

There is already view log button to monitor all log file content under folder $\{jboss.server.log.dir\} in wildfly and EAP6. We can simply leverage this feature to browser SOAP message instead of integrate CXF's logbrowser gui with wildfly/EAP6 console.  All soap message log can be handled in seperate logger categories and write into another log file. By view this log file, user can retrive all  soap message recorded by cxf logging interceptors.
This is the simple step to configure and view logged soap message. 
* Execute this script to add file handler and logger categories:
{code}
  connect
   batch
  /subsystem=logging/periodic-rotating-file-handler=SOAPMSG:add(file={path=>"soapmsg.log", relative-to=>"jboss.server.log.dir"},  named-formatter=PATTERN, suffix=.yyyy-MM-dd, append=true)
  /subsystem=logging/logger=org.apache.cxf.services:add(level=INFO, handlers=[SOAPMSG])
  /subsystem=logging/logger=org.apache.cxf.services:write-attribute(name="use-parent-handlers", value="false")
  run-batch
 {code}
_Note: This will log soap message for all endpoints. If user only wants to view one specific endpoint , the logger can be created with service name and port name's local part like:_
{code}  /subsystem=logging/logger=org.apache.cxf.services.EndpointSevice.EndpointPort:add(level=INFO, handlers=[SOAPMSG])
  /subsystem=logging/logger=org.apache.cxf.services.EndpointSevice.EndpointPort(name="use-parent-handlers", value="false"){code}
_The deployed endpoint has this @WebServbice annotion:_
 {code}@WebService(name="TestEndpoint", serviceName="EndpointService", portName="EndpointPort", targetNamespace="http://jbossws.jboss.org/test")
   public class TestEndpoint {
      ...
   }{code}
* Log in wildfly/EAP admin console and go to Runtime->Sever->Standalone Server>Log Files -> View and select the soap message output file soapmsg.log to view the inbound/outbound soap message.
  soap message can be accessed with CLI:
  {code}  /subsystem=logging/:read-log-file(name=soapmsg.log){code}





was (Author: jim.ma):
There is already view log button to monitor the log file content under $\{jboss.server.log.dir\} in wildfly and EAP6. We can simply leveraget this funcionality to browser SOAP message instead of integrate CXF's logbrowser gui with wildfly/EAP6 console.  All soap message log can be handled in seperate logger categories and write into another log file instead of server.log.
This is the simple step to configure the soap message monitor. 
* Execute this script to add file handler and logger categories:
{code}
  connect
   batch
  /subsystem=logging/periodic-rotating-file-handler=SOAPMSG:add(file={path=>"soapmsg.log", relative-to=>"jboss.server.log.dir"},  named-formatter=PATTERN, suffix=.yyyy-MM-dd, append=true)
  /subsystem=logging/logger=org.apache.cxf.services:add(level=INFO, handlers=[SOAPMSG])
  /subsystem=logging/logger=org.apache.cxf.services:write-attribute(name="use-parent-handlers", value="false")
  run-batch
 {code}
_Note: This will log soap message for all endpoints. If only want to view one specific endpoint , the logger can be created with service name and port name's local part like:_
{code}  /subsystem=logging/logger=org.apache.cxf.services.EndpointSevice.EndpointPort:add(level=INFO, handlers=[SOAPMSG])
  /subsystem=logging/logger=org.apache.cxf.services.EndpointSevice.EndpointPort(name="use-parent-handlers", value="false"){code}
_The deployed endpoint has this @WebServbice annotion:_
 {code}@WebService(name="TestEndpoint", serviceName="EndpointService", portName="EndpointPort", targetNamespace="http://jbossws.jboss.org/test")
   public class TestEndpoint {
      ...
   }{code}
* Log in wildfly/EAPadmin console and go to Runtime->Sever->Standalone Server>Log Files -> View and select the soap message output file soapmsg.log to view the inbound/outbound soap message.
  soap message can be accessed with CLI:
  {code}  /subsystem=logging/:read-log-file(name=soapmsg.log){code}




> Message log browser functionality
> ---------------------------------
>
>                 Key: JBWS-3586
>                 URL: https://issues.jboss.org/browse/JBWS-3586
>             Project: JBoss Web Services
>          Issue Type: Feature Request
>          Components: jbossws-cxf, jbossws-integration, productivity
>            Reporter: Alessio Soldano
>            Assignee: Jim Ma
>             Fix For: jbossws-cxf-5.2.0.Final
>
>
> I'd like to see a SOAP message log browsing functionality for JBossWS / JBoss AS. This should basically be something like the Apache CXF LogBrowser [1] yet integrated with the AS management / console.
> We should also evaluate whether it's possible to convert CXF generated logs into the JBossWS SPI Records [4] (in any case, any AS level handling of cxf stuff needs to be hidden behind JBossWS SPI).
> Finally we might explore additional functionalities / uses of logs which could be implemented; see for instance [2] and [3].
> [1] http://cxf.apache.org/docs/logbrowser-configuration.html
> [2] http://cxf.apache.org/docs/debugging-and-logging.html#DebuggingandLogging-ATOMlogging
> [3] http://sberyozkin.blogspot.it/2012/07/cxf-log-browser-demo.html
> [4] https://community.jboss.org/wiki/JBossWS-RecordsManagement



--
This message was sent by Atlassian JIRA
(v6.4.11#64026)


More information about the jbossws-issues mailing list