Displaying BO/SMO contents in WebSphere ESB 6.1

Previously, I wrote about how to dump Service Message Objects to the SystemOut log using a custom mediation. This solution involved using a small amount of Java code.

In later revisions of WebSphere Integration Developer 6.0.2, and in version 6.1, it is now possible to do this with a visual snippet, which makes it even easier. Place a custom mediation in your flow, and use the ‘Visual’ mode. The key to this technique is the pre-supplied print BO to log visual snippet in the utility section of the standard supplied visual snippets. If you hook this up to the smo input (and add a constant string print for good measure, to make reading the log easier), your visual custom mediation will look a bit like this:

Print BO to log example - version 2

This will provide output similar to that shown in the previous tip.

(Note: in fact, you can use this standard visual snippet to print any Business Object, not just a Service Message Object).

Advertisements

3 Responses to Displaying BO/SMO contents in WebSphere ESB 6.1

  1. Carlos Yaconi says:

    Thank you very much for this tip. I’m using it to figure out why a XSLT transformation only “works” when the ESB test environment is started up in debug mode.
    If I put this custom module just before the XSLT module, the mediation works fine and the transformation is done OK, but if I took away the log module, then the XSLT transformation don’t do anything and output just the root node of my SMO.
    BTW, if I start the server in debug mode, everything works fine, with or without log module…
    weird, right?

  2. Pingback: Setting up WebSphere ESB to Consume Messages from JBoss « SOA Tips ‘n’ Tricks

  3. Pingback: Accessing WS-Addressing Headers inside a Mediation Flow « SOA Tips ‘n’ Tricks

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: