1 Reply Latest reply: Jun 16, 2010 3:03 PM by 843830 RSS

    How do I obtain the raw JBI message for logging?

    843830
      I have created a set of web services, using ESB BPEL.

      The production servers to which these are deployed do not allow packet sniffing - against security rules.

      In order to be able to debug, I need to be able to see exactly what message is arriving; I know that I can use BPEL logging to get the XML sent to the server.log, which is my fallback position (although I get an exception logged as well:
      java.util.logging.ErrorManager: 5: Error in extracting Name Value Pairs
      java.lang.NullPointerException
      at org.glassfish.openesb.addons.logndc.NDCProvider$FlexMap.getMap(NDCProvider.java:447)
      at org.glassfish.openesb.addons.logndc.NDCProvider$FlexMap.keySet(NDCProvider.java:475)
      at com.sun.enterprise.server.logging.UniformLogFormatter.getNameValuePairs(UniformLogFormatter.java:185)
      at com.sun.enterprise.server.logging.UniformLogFormatter.uniformLogFormat(UniformLogFormatter.java:307)
      at com.sun.enterprise.server.logging.UniformLogFormatter.format(UniformLogFormatter.java:151)
      at java.util.logging.StreamHandler.publish(StreamHandler.java:179)
      at com.sun.enterprise.server.logging.FileandSyslogHandler.publish(FileandSyslogHandler.java:508)
      at java.util.logging.Logger.log(Logger.java:458)
      at java.util.logging.Logger.doLog(Logger.java:480)
      at java.util.logging.Logger.log(Logger.java:503)
      at com.sun.jbi.engine.bpel.core.bpel.trace.BPELTraceManager.logMessages(BPELTraceManager.java:198)
      at com.sun.jbi.engine.bpel.core.bpel.trace.BPELTraceManager.doTraceOnStart(BPELTraceManager.java:133)
      at com.sun.jbi.engine.bpel.core.bpel.model.runtime.impl.SequenceUnitImpl.doAction(SequenceUnitImpl.java:85)
      at com.sun.jbi.engine.bpel.core.bpel.model.runtime.impl.CodeReUseHelper.executeChildActivities(CodeReUseHelper.java:65)
      at com.sun.jbi.engine.bpel.core.bpel.model.runtime.impl.CatchAllUnitImpl.doAction(CatchAllUnitImpl.java:128)
      at com.sun.jbi.engine.bpel.core.bpel.model.runtime.impl.BPELProcessInstanceImpl.doFaultHandlingIfPossible(BPELProcessInstanceImpl.java:1142)
      at com.sun.jbi.engine.bpel.core.bpel.model.runtime.impl.BPELProcessInstanceImpl.doResumeAction(BPELProcessInstanceImpl.java:750)
      at com.sun.jbi.engine.bpel.core.bpel.model.runtime.impl.ActivityUnitImpl.doPassControlToParent(ActivityUnitImpl.java:253)
      at com.sun.jbi.engine.bpel.core.bpel.model.runtime.impl.StructuredActivityUnitImpl.doResumeAction(StructuredActivityUnitImpl.java:143)
      at com.sun.jbi.engine.bpel.core.bpel.model.runtime.impl.ActivityUnitImpl.doPassControlToParent(ActivityUnitImpl.java:253)
      at com.sun.jbi.engine.bpel.core.bpel.model.runtime.impl.VirtualThrowUnitImpl.doThrowAction(VirtualThrowUnitImpl.java:83)
      at com.sun.jbi.engine.bpel.core.bpel.model.runtime.impl.AbstractThrowUnitImpl.doAction(AbstractThrowUnitImpl.java:47)
      at com.sun.jbi.engine.bpel.core.bpel.engine.impl.BPELInterpreter.execute(BPELInterpreter.java:162)
      at com.sun.jbi.engine.bpel.core.bpel.engine.BusinessProcessInstanceThread.execute(BusinessProcessInstanceThread.java:98)
      at com.sun.jbi.engine.bpel.core.bpel.engine.impl.BPELProcessManagerImpl.process(BPELProcessManagerImpl.java:1031)
      at com.sun.jbi.engine.bpel.core.bpel.engine.impl.EngineImpl.process(EngineImpl.java:289)
      at com.sun.jbi.engine.bpel.core.bpel.engine.impl.EngineImpl.process(EngineImpl.java:1291)
      at com.sun.jbi.engine.bpel.BPELSEInOutThread.processRequest(BPELSEInOutThread.java:420)
      at com.sun.jbi.engine.bpel.BPELSEInOutThread.processMsgEx(BPELSEInOutThread.java:252)
      at com.sun.jbi.engine.bpel.BPELSEInOutThread.run(BPELSEInOutThread.java:183)
      <the raw xml message then appears in the server.log here>
      )

      In our environment, the server.log captures everything it captures, and we log using log4j into different logs, that are then monitored and parsed for various informations.

      I want to pass in the raw XML message into our audit-logger (which is a web service invocation); how do I do this?

      I have tried using string($input-xml), but that is not allowed "input-xml is a WSDL type" - I have to put string($input-xml.parameters) instead, and that gets rid of all of the XML tags.

      We need to see the badly formed XML arriving, so we can tell the coder on the other side "this is the issue, friend".

      How do I do it?

      Thank you!

      Martin