<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>SOA Tips 'n' Tricks</title>
	<atom:link href="http://soatipsntricks.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://soatipsntricks.wordpress.com</link>
	<description>Tips 'n' Tricks from the world of IBM WebSphere SOA Products</description>
	<lastBuildDate>Fri, 13 Jan 2012 15:12:11 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='soatipsntricks.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://0.gravatar.com/blavatar/80e20c24c36085df6996a7f2334b101c?s=96&#038;d=http%3A%2F%2Fs2.wp.com%2Fi%2Fbuttonw-com.png</url>
		<title>SOA Tips 'n' Tricks</title>
		<link>http://soatipsntricks.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://soatipsntricks.wordpress.com/osd.xml" title="SOA Tips &#039;n&#039; Tricks" />
	<atom:link rel='hub' href='http://soatipsntricks.wordpress.com/?pushpress=hub'/>
		<item>
		<title>Business Objects and Lombardi Coaches</title>
		<link>http://soatipsntricks.wordpress.com/2011/10/26/business-objects-and-lombardi-coaches/</link>
		<comments>http://soatipsntricks.wordpress.com/2011/10/26/business-objects-and-lombardi-coaches/#comments</comments>
		<pubDate>Wed, 26 Oct 2011 09:34:45 +0000</pubDate>
		<dc:creator>Gabriel Telerman</dc:creator>
				<category><![CDATA[BPM]]></category>
		<category><![CDATA[Lombardi]]></category>
		<category><![CDATA[bpm]]></category>

		<guid isPermaLink="false">http://soatipsntricks.wordpress.com/?p=541</guid>
		<description><![CDATA[We&#8217;re working with IBM BPM 7.5 these days, or rather making it work, and a little idiosyncrasy of the product had us head-scratching for a few hours. You may or may not know that the Lombardi part of the product uses variables to represent business process data. You would usually define variables local to the [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=soatipsntricks.wordpress.com&amp;blog=504053&amp;post=541&amp;subd=soatipsntricks&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>We&#8217;re working with IBM BPM 7.5 these days, or rather making it work, and a little idiosyncrasy of the product had us head-scratching for a few hours.</p>
<p>You may or may not know that the Lombardi part of the product uses variables to represent business process data. You would usually define variables local to the business process definition (BPD) and use data mappings to select what data will be used as inputs and outputs to the various activities within the process.</p>
<p>You can define your own data types (business objects) for these variables. So as way of example we defined an Individual, with string attributes for first and last names. Nothing fancy.</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-1.jpg"><img class="alignnone size-full wp-image-542" style="border:1px solid black;" title="screenshot.1" src="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-1.jpg?w=630&#038;h=379" alt="" width="630" height="379" /></a></p>
<p>Then added a private variable to the BPD named individual of type Individual. Note how we did not specify a default value for the variable.</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-2.jpg"><img class="alignnone size-full wp-image-543" style="border:1px solid black;" title="screenshot.2" src="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-2.jpg?w=630&#038;h=371" alt="" width="630" height="371" /></a></p>
<p>Suppose you now create a very simple BPD to use a UI Coach to populate the individual name and a simple javascript service to write the names to the log:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-4.jpg"><img class="alignnone size-full wp-image-544" style="border:1px solid black;" title="screenshot.4" src="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-4.jpg?w=630" alt=""   /></a></p>
<p>The log activity has a simple system script service to write the individual&#8217;s attributes to the system log:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-6.jpg"><img class="alignnone size-full wp-image-546" style="border:1px solid black;" title="screenshot.6" src="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-6.jpg?w=630" alt=""   /></a></p>
<p>When you run this, the first activity will let you populate the individual variable values:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-5.jpg"><img class="alignnone size-full wp-image-545" style="border:1px solid black;" title="screenshot.5" src="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-5.jpg?w=630" alt=""   /></a></p>
<p>What happens next is not that predictable. One would assume that the UI form took the user supplied values for fname and lname and used them to initialise and populate the individual.</p>
<p>Not quite.</p>
<p>Once the Coach task completed the process moved on to the log activity and failed. Crashed and burned.</p>
<p>The BPD instance has failed and the error is in the Log activity:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-7.jpg"><img class="alignnone size-full wp-image-547" style="border:1px solid black;" title="screenshot.7" src="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-7.jpg?w=630&#038;h=482" alt="" width="630" height="482" /></a></p>
<p>The details of the error are self explanatory, the individual variable is undefined:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-8.jpg"><img class="alignnone size-full wp-image-548" style="border:1px solid black;" title="screenshot.8" src="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-8.jpg?w=630&#038;h=190" alt="" width="630" height="190" /></a></p>
<p>It turns out that complex type variables need to be explicitly initialised, particularly when Coaches are involved!</p>
<p><span style="font-family:Arial;font-size:x-small;"><a title="http://publib.boulder.ibm.com/infocenter/wle/v7r1/topic/wle/modeling/topic/init_complex_vars.html" href="http://publib.boulder.ibm.com/infocenter/wle/v7r1/topic/wle/modeling/topic/init_complex_vars.html">http://publib.boulder.ibm.com/infocenter/wle/v7r1/topic/wle/modeling/topic/init_complex_vars.html</a></span></p>
<p>So, the IBM documented approach is to use a script activity to intitialise them:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-9.jpg"><img class="alignnone size-full wp-image-549" style="border:1px solid black;" title="screenshot.9" src="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-9.jpg?w=630&#038;h=349" alt="" width="630" height="349" /></a></p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-10.jpg"><img class="alignnone size-full wp-image-550" style="border:1px solid black;" title="screenshot.10" src="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-10.jpg?w=630" alt=""   /></a></p>
<p>But we also found out in our tests that giiving the variable default values also solves the problem, even if the values are empty strings:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-11.jpg"><img class="alignnone size-full wp-image-551" style="border:1px solid black;" title="screenshot.11" src="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-11.jpg?w=630&#038;h=279" alt="" width="630" height="279" /></a></p>
<p>So, hope this tip comes useful to someone else and you can look fwd to more posts on BPM 7.5</p>
<p>I&#8217;m sure we&#8217;re not going to be short of material for quite some time&#8230;</p>
<p>ttfn</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/soatipsntricks.wordpress.com/541/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/soatipsntricks.wordpress.com/541/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/soatipsntricks.wordpress.com/541/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/soatipsntricks.wordpress.com/541/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/soatipsntricks.wordpress.com/541/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/soatipsntricks.wordpress.com/541/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/soatipsntricks.wordpress.com/541/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/soatipsntricks.wordpress.com/541/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/soatipsntricks.wordpress.com/541/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/soatipsntricks.wordpress.com/541/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/soatipsntricks.wordpress.com/541/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/soatipsntricks.wordpress.com/541/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/soatipsntricks.wordpress.com/541/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/soatipsntricks.wordpress.com/541/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=soatipsntricks.wordpress.com&amp;blog=504053&amp;post=541&amp;subd=soatipsntricks&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://soatipsntricks.wordpress.com/2011/10/26/business-objects-and-lombardi-coaches/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/53c4db1def8790eb82e156a96b43ede6?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">gtelerman</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-1.jpg" medium="image">
			<media:title type="html">screenshot.1</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-2.jpg" medium="image">
			<media:title type="html">screenshot.2</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-4.jpg" medium="image">
			<media:title type="html">screenshot.4</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-6.jpg" medium="image">
			<media:title type="html">screenshot.6</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-5.jpg" medium="image">
			<media:title type="html">screenshot.5</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-7.jpg" medium="image">
			<media:title type="html">screenshot.7</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-8.jpg" medium="image">
			<media:title type="html">screenshot.8</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-9.jpg" medium="image">
			<media:title type="html">screenshot.9</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-10.jpg" medium="image">
			<media:title type="html">screenshot.10</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/10/screenshot-11.jpg" medium="image">
			<media:title type="html">screenshot.11</media:title>
		</media:content>
	</item>
		<item>
		<title>WebSphere JDBC adapter and hierarchical objects with Oracle</title>
		<link>http://soatipsntricks.wordpress.com/2011/07/12/websphere-jdbc-adapter-and-hierarchical-objects-with-oracle/</link>
		<comments>http://soatipsntricks.wordpress.com/2011/07/12/websphere-jdbc-adapter-and-hierarchical-objects-with-oracle/#comments</comments>
		<pubDate>Tue, 12 Jul 2011 14:09:00 +0000</pubDate>
		<dc:creator>Gabriel Telerman</dc:creator>
				<category><![CDATA[Adapters]]></category>
		<category><![CDATA[Enterprise Service Bus]]></category>
		<category><![CDATA[Integration Developer]]></category>
		<category><![CDATA[Process Server]]></category>

		<guid isPermaLink="false">http://soatipsntricks.wordpress.com/?p=516</guid>
		<description><![CDATA[At my client&#8217;s we have used the JDBC adapter to integrate with Oracle tables extensively in the past. In fact, the solution in place is pretty much hinging on Oracle tables for marketing campaigns and product configuration details. So far we have always been conservative in our approach, creating integration flows one table at a [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=soatipsntricks.wordpress.com&amp;blog=504053&amp;post=516&amp;subd=soatipsntricks&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>At my client&#8217;s we have used the JDBC adapter to integrate with Oracle tables extensively in the past. In fact, the solution in place is pretty much hinging on Oracle tables for marketing campaigns and product configuration details.</p>
<p>So far we have always been conservative in our approach, creating integration flows one table at a time or working against Oracle views. Trying to not ask too much from the adapter.</p>
<p>New business requirements for a future release demand a bit more from our JDBC connectivity. We have to retrieve, update and create from multiple related tables, which is mostly fine, but we ran into a little rough patch doing the inserts.</p>
<p>It is worth mentioning than none of this would have been an issue with DB2, which supports Identity columns. The JDBC adapter understands these Identity fields and generates the Business Objects accordingly. But with Oracle things are a little different.</p>
<p>Oracle implements auto generated primary keys with a combination of Sequences and Triggers. The sequence supplies the ID value and the trigger fires before the insert populating the primary key with it.</p>
<p>Let&#8217;s take a simple example of two related tables, AUTHOR and BOOK.<br />
AUTHOR.ID will be the primary key and BOOK.AUTHID will be the foreign key relating book rows to their author. I&#8217;m using Oracle XE 10g and created the tables using the web ui.</p>
<p>You can start creating a new WID integration project and drop an outbound JDBC  adapter in the assembly. Go through the wizard as usual but make sure you click the &#8216;Edit Query&#8230;&#8217; button and check the &#8216;Prompt for additional configuration settings when adding business objects&#8217; check box, as shown in the image below:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/07/12-07-2011-12-13-13.png"><img class="alignnone size-full wp-image-517" title="12-07-2011 12-13-13" src="http://soatipsntricks.files.wordpress.com/2011/07/12-07-2011-12-13-13.png?w=630" alt=""   /></a></p>
<p>After you run the query you can start adding tables. Add the AUTHOR table first accepting all defaults.</p>
<p>Next add the BOOK table and build the child/parent relationship as in the following image:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/07/12-07-2011-14-05-30.png"><img class="alignnone size-full wp-image-519" title="12-07-2011 14-05-30" src="http://soatipsntricks.files.wordpress.com/2011/07/12-07-2011-14-05-30.png?w=630" alt=""   /></a></p>
<p>Complete the wizard (I don&#8217;t generate business graphs, clear the checkbox)</p>
<p>Now is when the manual changes happen. Open the generated BO for the AUTHOR table, I&#8217;m using the system squema and the BO is called SystemAuthor.</p>
<p>You have to manually add the UID annotation to the &#8216;id&#8217; attribute and supply the sequence name as shown below. This is done by a right-click on the metadata element.</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/07/12-07-2011-14-14-00.png"><img class="alignnone size-full wp-image-520" style="border:1px solid black;" title="12-07-2011 14-14-00" src="http://soatipsntricks.files.wordpress.com/2011/07/12-07-2011-14-14-00.png?w=630" alt=""   /></a></p>
<p>You can repeat the process for the BOOK object for good measure, though for this case it isn&#8217;t strictly required.</p>
<p>Next we have to modify the Oracle trigger:</p>
<pre>CREATE OR REPLACE TRIGGER  "BI_AUTHOR"
  before insert on "AUTHOR"
  for each row
<span style="color:red;">WHEN (new.id is NULL)</span>
begin
    select "AUTHOR_SEQ".nextval into :NEW.ID from dual;
end;</pre>
<p>The manual change highlighted in red is required because the JDBC adapter, once is told that the ID field is generated, will query the sequence and populate the attribute with the retrieved value. It also synchronises any foreign keys on child objects. But just before the insert operation, without this manual change, the trigger will fire, replace the value of the auto-gen field with the next value in the sequence and cause the parent/child relationship to be out of sync.</p>
<p>You can also modify the trigger for BOOK inserts. We don&#8217;t have child objects of BOOK in this example to worry about but it makes sense to do it for completeness and to be ready for them.</p>
<p>You can now deploy and test. One thing to watch out for is the fact that the integration test client will populate the foreign key on the child object with a default value unless you manually unset it. So make sure you explicitly set any authid book attribute to unset as below:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/07/12-07-2011-15-04-12.png"><img class="alignnone size-full wp-image-529" style="border:1px solid black;" title="12-07-2011 15-04-12" src="http://soatipsntricks.files.wordpress.com/2011/07/12-07-2011-15-04-12.png?w=630" alt=""   /></a></p>
<p>The response should look like this:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/07/12-07-2011-15-06-04.png"><img class="alignnone size-full wp-image-530" style="border:1px solid black;" title="12-07-2011 15-06-04" src="http://soatipsntricks.files.wordpress.com/2011/07/12-07-2011-15-06-04.png?w=630" alt=""   /></a></p>
<p>You can also check your tables and verify that the rows have been inserted as expected.</p>
<p>Best regards</p>
<p>Gaby</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/soatipsntricks.wordpress.com/516/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/soatipsntricks.wordpress.com/516/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/soatipsntricks.wordpress.com/516/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/soatipsntricks.wordpress.com/516/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/soatipsntricks.wordpress.com/516/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/soatipsntricks.wordpress.com/516/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/soatipsntricks.wordpress.com/516/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/soatipsntricks.wordpress.com/516/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/soatipsntricks.wordpress.com/516/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/soatipsntricks.wordpress.com/516/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/soatipsntricks.wordpress.com/516/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/soatipsntricks.wordpress.com/516/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/soatipsntricks.wordpress.com/516/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/soatipsntricks.wordpress.com/516/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=soatipsntricks.wordpress.com&amp;blog=504053&amp;post=516&amp;subd=soatipsntricks&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://soatipsntricks.wordpress.com/2011/07/12/websphere-jdbc-adapter-and-hierarchical-objects-with-oracle/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/53c4db1def8790eb82e156a96b43ede6?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">gtelerman</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/07/12-07-2011-12-13-13.png" medium="image">
			<media:title type="html">12-07-2011 12-13-13</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/07/12-07-2011-14-05-30.png" medium="image">
			<media:title type="html">12-07-2011 14-05-30</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/07/12-07-2011-14-14-00.png" medium="image">
			<media:title type="html">12-07-2011 14-14-00</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/07/12-07-2011-15-04-12.png" medium="image">
			<media:title type="html">12-07-2011 15-04-12</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/07/12-07-2011-15-06-04.png" medium="image">
			<media:title type="html">12-07-2011 15-06-04</media:title>
		</media:content>
	</item>
		<item>
		<title>SQL Exception: Unable to insert null into process_template</title>
		<link>http://soatipsntricks.wordpress.com/2011/06/21/sql-exception-unable-to-insert-null-into-process_template/</link>
		<comments>http://soatipsntricks.wordpress.com/2011/06/21/sql-exception-unable-to-insert-null-into-process_template/#comments</comments>
		<pubDate>Tue, 21 Jun 2011 10:40:53 +0000</pubDate>
		<dc:creator>Gabriel Telerman</dc:creator>
				<category><![CDATA[Enterprise Service Bus]]></category>
		<category><![CDATA[Integration Developer]]></category>
		<category><![CDATA[Process Server]]></category>

		<guid isPermaLink="false">http://soatipsntricks.wordpress.com/?p=506</guid>
		<description><![CDATA[This is an old foe that has reared its ugly head again at my client&#8217;s. One of the coding standards we have in place states that in a BPEL process, invoke activities must catch their corresponding interface faults, and if necessary throw a process specific fault to be caught at the top level of the [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=soatipsntricks.wordpress.com&amp;blog=504053&amp;post=506&amp;subd=soatipsntricks&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>This is an old foe that has reared its ugly head again at my client&#8217;s.</p>
<p>One of the coding standards we have in place states that in a BPEL process, invoke activities must catch their corresponding interface faults, and if necessary throw a process specific fault to be caught at the top level of the BPEL.</p>
<p>A developer was very diligent following this standard, which is good news, but he forgot to populate the namespace of the fault he was throwing.</p>
<p>Version 7 does this for you, which is neat, but in v6 if you don&#8217;t specify the namespace as in the image below, it will be left empty.</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/06/screenshot-45.jpg"><img class="alignnone size-full wp-image-508" style="border:1px solid black;" title="screenshot.45" src="http://soatipsntricks.files.wordpress.com/2011/06/screenshot-45.jpg?w=630" alt=""   /></a></p>
<p>If you leave the fault namespace blank, the process might not behave as expected, but it will deploy and start on your integrated test environment.</p>
<p>However, when deployed to a real environment using Oracle as the persistence mechanism this process will not start.</p>
<p>Enabling detailed trace on the server (com.ibm.bpe.*=all) revealed a rather terse <span style="font-family:Times New Roman;font-size:small;">ORACLE SQL EXCEPTION: UNABLE TO INSERT NULL into PROCESS TEMPLATE(null,tempalteId,).</span></p>
<p>Only &#8216;thanks&#8217; to past experience and recollection I was able to diagnose and correct the problem.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/soatipsntricks.wordpress.com/506/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/soatipsntricks.wordpress.com/506/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/soatipsntricks.wordpress.com/506/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/soatipsntricks.wordpress.com/506/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/soatipsntricks.wordpress.com/506/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/soatipsntricks.wordpress.com/506/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/soatipsntricks.wordpress.com/506/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/soatipsntricks.wordpress.com/506/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/soatipsntricks.wordpress.com/506/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/soatipsntricks.wordpress.com/506/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/soatipsntricks.wordpress.com/506/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/soatipsntricks.wordpress.com/506/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/soatipsntricks.wordpress.com/506/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/soatipsntricks.wordpress.com/506/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=soatipsntricks.wordpress.com&amp;blog=504053&amp;post=506&amp;subd=soatipsntricks&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://soatipsntricks.wordpress.com/2011/06/21/sql-exception-unable-to-insert-null-into-process_template/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/53c4db1def8790eb82e156a96b43ede6?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">gtelerman</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/06/screenshot-45.jpg" medium="image">
			<media:title type="html">screenshot.45</media:title>
		</media:content>
	</item>
		<item>
		<title>SCA Recursion</title>
		<link>http://soatipsntricks.wordpress.com/2011/06/13/sca-recursion/</link>
		<comments>http://soatipsntricks.wordpress.com/2011/06/13/sca-recursion/#comments</comments>
		<pubDate>Mon, 13 Jun 2011 13:03:42 +0000</pubDate>
		<dc:creator>Gabriel Telerman</dc:creator>
				<category><![CDATA[Enterprise Service Bus]]></category>
		<category><![CDATA[Integration Developer]]></category>
		<category><![CDATA[Process Server]]></category>
		<category><![CDATA[SOA]]></category>
		<category><![CDATA[WebSphere]]></category>

		<guid isPermaLink="false">http://soatipsntricks.wordpress.com/?p=487</guid>
		<description><![CDATA[A service I&#8217;m designing for a client will retrieve mortgage details to be displayed by the web tier. It is common for mortgages to consist of a main account which itself is composed of a number of sub-accounts, and it is not inconceivable for the sub-accounts themselves to have further sub-accounts. To retrieve the entire [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=soatipsntricks.wordpress.com&amp;blog=504053&amp;post=487&amp;subd=soatipsntricks&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>A service I&#8217;m designing for a client will retrieve mortgage details to be displayed by the web tier.</p>
<p>It is common for mortgages to consist of a main account which itself is composed of a number of sub-accounts, and it is not inconceivable for the sub-accounts themselves to have further sub-accounts.</p>
<p>To retrieve the entire tree my service has to call the mortgage account back-end multiple times while drilling down into accounts for sub-accounts to retrieve.</p>
<p>All those main and sub accounts are the same data type, so recursion seemed a good fit: I receive a request with a mortgage account Id, call the back end service who responds with account details, including a list of sub-account Ids, and for each sub-account I call myself, appending responses to the list of mortgage details in the final response.</p>
<p>The end result, is a response structure with nested mortgage details.</p>
<p>Let&#8217;s start by taking a look at the assembly diagram:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/06/screenshot-37.jpg"><img class="alignnone size-full wp-image-489" style="border:1px solid black;" title="screenshot.37" src="http://soatipsntricks.files.wordpress.com/2011/06/screenshot-37.jpg?w=630" alt=""   /></a></p>
<p>The MortgageAccount untyped component represents the back-end. I will be manually emulating this, so an untyped component will suffice.</p>
<p>RetrieveMortgageDetails is a BPEL microflow which references the back-end mock and also <em><strong>references itself</strong></em>.</p>
<p>I&#8217;ve implemented two interfaces, one for the microflow and another one for the mock back-end.</p>
<p>Both interfaces have a message input with a mortgage account Id but the response objects are slightly different.</p>
<p>The microflow returns a MortgageDetails object, which has as an attribute a list of MortgageDetails, as follows:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/06/screenshot-38.jpg"><img class="alignnone size-full wp-image-490" style="border:1px solid black;" title="screenshot.38" src="http://soatipsntricks.files.wordpress.com/2011/06/screenshot-38.jpg?w=630" alt=""   /></a></p>
<p>The mock back-end returns a MortgageAccount object, which has as an attribute a list of sub-account Ids:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/06/screenshot-39.jpg"><img class="alignnone size-full wp-image-491" style="border:1px solid black;" title="screenshot.39" src="http://soatipsntricks.files.wordpress.com/2011/06/screenshot-39.jpg?w=630" alt=""   /></a></p>
<p>The microflow is implemented as follows:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/06/screenshot-40.jpg"><img class="alignnone size-full wp-image-494" style="border:1px solid black;" title="screenshot.40" src="http://soatipsntricks.files.wordpress.com/2011/06/screenshot-40.jpg?w=630" alt=""   /></a></p>
<p>The first invoke calls the back-end, then for each sub-account Id in the response I call myself, appending the response to the subAccount attribute in my response to the calling client. Of course the &#8216;calling client&#8217; will be myself when traversing the nested sub-accounts, and the real client once all sub-accounts are retrieved.</p>
<p>Here&#8217;s the result of a test run:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/06/screenshot-42.jpg"><img class="alignnone size-full wp-image-497" style="border:1px solid black;" title="screenshot.42" src="http://soatipsntricks.files.wordpress.com/2011/06/screenshot-42.jpg?w=630&#038;h=480" alt="" width="630" height="480" /></a></p>
<p>You can see how the response has a main mortgage account (id 1) which has two sub-accounts (1.1 and 1.2) You can also see that sub-account 1.1 has two nested sub-accounts (1.1.1 and 1.1.2)</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/soatipsntricks.wordpress.com/487/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/soatipsntricks.wordpress.com/487/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/soatipsntricks.wordpress.com/487/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/soatipsntricks.wordpress.com/487/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/soatipsntricks.wordpress.com/487/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/soatipsntricks.wordpress.com/487/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/soatipsntricks.wordpress.com/487/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/soatipsntricks.wordpress.com/487/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/soatipsntricks.wordpress.com/487/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/soatipsntricks.wordpress.com/487/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/soatipsntricks.wordpress.com/487/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/soatipsntricks.wordpress.com/487/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/soatipsntricks.wordpress.com/487/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/soatipsntricks.wordpress.com/487/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=soatipsntricks.wordpress.com&amp;blog=504053&amp;post=487&amp;subd=soatipsntricks&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://soatipsntricks.wordpress.com/2011/06/13/sca-recursion/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/53c4db1def8790eb82e156a96b43ede6?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">gtelerman</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/06/screenshot-37.jpg" medium="image">
			<media:title type="html">screenshot.37</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/06/screenshot-38.jpg" medium="image">
			<media:title type="html">screenshot.38</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/06/screenshot-39.jpg" medium="image">
			<media:title type="html">screenshot.39</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/06/screenshot-40.jpg" medium="image">
			<media:title type="html">screenshot.40</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/06/screenshot-42.jpg" medium="image">
			<media:title type="html">screenshot.42</media:title>
		</media:content>
	</item>
		<item>
		<title>It&#8217;s Store-and-Forward, Jim, but not as we know it.</title>
		<link>http://soatipsntricks.wordpress.com/2011/03/10/its-store-and-forward-jim-but-not-as-we-know-it/</link>
		<comments>http://soatipsntricks.wordpress.com/2011/03/10/its-store-and-forward-jim-but-not-as-we-know-it/#comments</comments>
		<pubDate>Thu, 10 Mar 2011 17:24:38 +0000</pubDate>
		<dc:creator>Gabriel Telerman</dc:creator>
				<category><![CDATA[Enterprise Service Bus]]></category>
		<category><![CDATA[Integration Developer]]></category>
		<category><![CDATA[Process Server]]></category>
		<category><![CDATA[SOA]]></category>

		<guid isPermaLink="false">http://soatipsntricks.wordpress.com/?p=465</guid>
		<description><![CDATA[You might have heard of v7 formal support for store-and-fwd and wondering what this post is about. Well, it&#8217;s not about v7&#8242;s support for it. The product feature relates to its ability to recognise when a target system is unavailable, work upstream until it finds the first asynchronous interaction point, and start storing requests until [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=soatipsntricks.wordpress.com&amp;blog=504053&amp;post=465&amp;subd=soatipsntricks&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>You might have heard of v7 formal support for store-and-fwd and wondering what this post is about. Well, it&#8217;s not about v7&#8242;s support for it.</p>
<p>The product feature relates to its ability to recognise when a target system is unavailable, work upstream until it finds the first asynchronous interaction point, and start storing requests until human intervention via a dedicated Business Space widget to reopen the information flow.</p>
<p>The key points here are 1) only asynchronous interactions are supported 2) human intervention is necessary to restore the flow.</p>
<p>I&#8217;m working against a different scenario here. What I want to do is to automatically switch from synchronous to asynchronous processing of selected interactions when a target system is not available. I want synchronous consumers of my service to always get a synchronous response, either complete or partial, depending on whether my respective target systems are reachable or not.</p>
<p>I also want a retry mechanism that will continue accepting requests and process them all &#8216;offline&#8217; once the failed external system is restored.</p>
<p>And I want the business process to pick up where it left off and carry on with its activity sequence.</p>
<p>So, imagine you apply for a credit card online, and there are 3 key steps to process your application. First we score your risk, then we validate your application and last we fulfill your order.</p>
<p>You can write a short running BPEL process to orchestrate those three services and give the web front end a synchronous response.</p>
<p>Now, suppose risk scoring is a third party service that&#8217;s notorious for being down for housekeeping a few hours every day.</p>
<p>Clearly we can&#8217;t fulfill your application without having scored your risk, but neither we want to just tell you to come back later, much later, and that we are sorry but you just wasted your time filling up a form.</p>
<p>What we want is to tell you that your application has been received, it is being processed, and you can look forward to your new credit card arriving in the post real soon (or if you haven&#8217;t qualified, a communication to that effect).</p>
<p>So, lets look at a simple prototype of the short running process, without any store and forward capabilities.</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/03/screenshot-2.jpg"><img class="size-full wp-image-475 alignleft" style="border:1px solid black;" title="screenshot.2" src="http://soatipsntricks.files.wordpress.com/2011/03/screenshot-2.jpg?w=630" alt=""   /></a>Not a lot going on here. We receive a credit card application request, we prepare requests to a number of external systems, we invoke them in sequence and we reply to the client.</p>
<p>The external systems are implemented as mediation modules and stubbed with Java SCA components. I log the message and create a response from these components.</p>
<p>For the scoring service I did a bit more work. I configured a jndi string binding that I can manipulate through the admin console and depending on its value I throw a modeled fault. This is so I can emulate the system being unavailable.</p>
<p>I assume you can complete these tasks without assistance.</p>
<p>You can then run some basic tests and confirm that all your modules are hanging together and everything behaves as it should.</p>
<p>So now we can start thinking about how to approach the case when the scoring service is offline.</p>
<p>The first thing you&#8217;re going to need is a new module with a long running process implementing a new ScoringService interface with a one way operation taking the same input parameter type as the actual scoring service mediation.</p>
<p>You can think about this asynchronous LRP as a &#8216;wrapper&#8217; to the synchronous scoring service.</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/03/screenshot-4.jpg"><img class="alignnone size-full wp-image-479" style="border:1px solid black;" title="screenshot.4" src="http://soatipsntricks.files.wordpress.com/2011/03/screenshot-4.jpg?w=630&#038;h=436" alt="" width="630" height="436" /></a></p>
<p>So, this LRP is called asynchronously (there is no reply) and is instantiated once and only once. You will have to work on your correlation properties/set, so requests are routed to the running instance.</p>
<p>On initial request, an instance is created, the request is placed in a list and an attempt is made to call the scoring service. This call is likely to fail (we wouldn&#8217;t be here at all otherwise), so the fault handler executes, which puts the process in receive mode. Every additional request is appended to the list and every time we end up putting the process in receive mode again.</p>
<p>I we haven&#8217;t received a request for some time, we timeout the fault handler so we can probe the Scoring Service.</p>
<p>At some point the Scoring Service will be up and running again and for each pending request we will invoke it, get its response, remove the current pending request from the list and invoke the credit card application short running process, letting it know the scoring activity is now complete (we pass in the score result).</p>
<p>Note that &#8216;resuming&#8217; the credit card application process does not technically resume anything. It simply creates a new instance but with the scoring data already present.</p>
<p>Next you have to modify the short running process so it can detect that the Scoring Service is down, call the async &#8216;wrapper&#8217; and reply a partial response to the client.</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/03/screenshot-5.jpg"><img class="alignnone size-full wp-image-481" style="border:1px solid black;" title="screenshot.5" src="http://soatipsntricks.files.wordpress.com/2011/03/screenshot-5.jpg?w=630" alt=""   /></a></p>
<p>When this short running process is called from the UI and the Scoring Service is up, it behaves exactly as before, and the UI receives a complete response.</p>
<p>When the Scoring Service is down, the fault handler runs, the long running process is called, and the UI receives a partial response.</p>
<p>When this short running process is called by the long running one, the scoring invoke is not attempted, the process proceeds with validating and fulfilling the credit card application, and the reply goes back to the long running process, which you can use for generating customer communications.</p>
<p>This approach keeps the business logic in a single place (the short running process), and effectively deals with offline treatment of requests when a given system is down.</p>
<p>It also addresses resource management, by creating a single long running process, rather than one for each pending request.</p>
<p>And because a long running process state is persisted, all those pending requests survive a server restart, so nothing is ever lost.</p>
<p>ttfn &#8211; gabz</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/soatipsntricks.wordpress.com/465/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/soatipsntricks.wordpress.com/465/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/soatipsntricks.wordpress.com/465/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/soatipsntricks.wordpress.com/465/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/soatipsntricks.wordpress.com/465/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/soatipsntricks.wordpress.com/465/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/soatipsntricks.wordpress.com/465/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/soatipsntricks.wordpress.com/465/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/soatipsntricks.wordpress.com/465/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/soatipsntricks.wordpress.com/465/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/soatipsntricks.wordpress.com/465/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/soatipsntricks.wordpress.com/465/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/soatipsntricks.wordpress.com/465/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/soatipsntricks.wordpress.com/465/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=soatipsntricks.wordpress.com&amp;blog=504053&amp;post=465&amp;subd=soatipsntricks&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://soatipsntricks.wordpress.com/2011/03/10/its-store-and-forward-jim-but-not-as-we-know-it/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/53c4db1def8790eb82e156a96b43ede6?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">gtelerman</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/03/screenshot-2.jpg" medium="image">
			<media:title type="html">screenshot.2</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/03/screenshot-4.jpg" medium="image">
			<media:title type="html">screenshot.4</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/03/screenshot-5.jpg" medium="image">
			<media:title type="html">screenshot.5</media:title>
		</media:content>
	</item>
		<item>
		<title>WID Heap Status</title>
		<link>http://soatipsntricks.wordpress.com/2011/02/22/wid-heap-status/</link>
		<comments>http://soatipsntricks.wordpress.com/2011/02/22/wid-heap-status/#comments</comments>
		<pubDate>Tue, 22 Feb 2011 14:16:00 +0000</pubDate>
		<dc:creator>Gabriel Telerman</dc:creator>
				<category><![CDATA[Enterprise Service Bus]]></category>
		<category><![CDATA[Integration Developer]]></category>
		<category><![CDATA[Process Server]]></category>

		<guid isPermaLink="false">http://soatipsntricks.wordpress.com/?p=457</guid>
		<description><![CDATA[This is a back to basics tip, but I&#8217;m surprised by the number of questions about this from experienced developers. I like to keep an eye of how much java heap WID is using, particularly while building big workspaces. So I check &#8216;Show heap status&#8217; in General Preferences: Then you&#8217;ll see it at the bottom [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=soatipsntricks.wordpress.com&amp;blog=504053&amp;post=457&amp;subd=soatipsntricks&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>This is a back to basics tip, but I&#8217;m surprised by the number of questions about this from experienced developers.<br />
I like to keep an eye of how much java heap WID is using, particularly while building big workspaces.</p>
<p>So I check &#8216;Show heap status&#8217; in General Preferences:<br />
<a href="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-23.jpeg"><img class="alignnone size-full wp-image-458" style="border:1px solid black;" title="screenshot.23" src="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-23.jpeg?w=630" alt=""   /></a></p>
<p>Then you&#8217;ll see it at the bottom right corner:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-25.jpeg"><img class="alignnone size-full wp-image-459" style="border:1px solid black;" title="screenshot.25" src="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-25.jpeg?w=630&#038;h=166" alt="" width="630" height="166" /></a></p>
<p>WID&#8217;s default max heap is 512M. I normally change it to 1024 by editing eclipse.ini and changing -Xms512m to -Xms1024m</p>
<p>Short but sweet</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/soatipsntricks.wordpress.com/457/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/soatipsntricks.wordpress.com/457/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/soatipsntricks.wordpress.com/457/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/soatipsntricks.wordpress.com/457/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/soatipsntricks.wordpress.com/457/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/soatipsntricks.wordpress.com/457/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/soatipsntricks.wordpress.com/457/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/soatipsntricks.wordpress.com/457/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/soatipsntricks.wordpress.com/457/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/soatipsntricks.wordpress.com/457/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/soatipsntricks.wordpress.com/457/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/soatipsntricks.wordpress.com/457/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/soatipsntricks.wordpress.com/457/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/soatipsntricks.wordpress.com/457/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=soatipsntricks.wordpress.com&amp;blog=504053&amp;post=457&amp;subd=soatipsntricks&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://soatipsntricks.wordpress.com/2011/02/22/wid-heap-status/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/53c4db1def8790eb82e156a96b43ede6?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">gtelerman</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-23.jpeg" medium="image">
			<media:title type="html">screenshot.23</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-25.jpeg" medium="image">
			<media:title type="html">screenshot.25</media:title>
		</media:content>
	</item>
		<item>
		<title>Building a reusable subflow</title>
		<link>http://soatipsntricks.wordpress.com/2011/02/01/building-a-reusable-subflow/</link>
		<comments>http://soatipsntricks.wordpress.com/2011/02/01/building-a-reusable-subflow/#comments</comments>
		<pubDate>Tue, 01 Feb 2011 19:28:10 +0000</pubDate>
		<dc:creator>Gabriel Telerman</dc:creator>
				<category><![CDATA[Enterprise Service Bus]]></category>
		<category><![CDATA[Integration Developer]]></category>
		<category><![CDATA[Process Server]]></category>
		<category><![CDATA[SOA]]></category>

		<guid isPermaLink="false">http://soatipsntricks.wordpress.com/?p=387</guid>
		<description><![CDATA[A lot has been written already about performing common logic to messages using a variety of approaches, but they typically do logging using a message logger or trace primitive. They shy away from using a Service Invoke within a subflow, and for good reason, as the SI primitive&#8217;s output terminal returns the response from its [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=soatipsntricks.wordpress.com&amp;blog=504053&amp;post=387&amp;subd=soatipsntricks&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>A lot has been written already about performing common logic to messages using a variety of approaches, but they typically do logging using a message logger or trace primitive. They shy away from using a Service Invoke within a subflow, and for good reason, as the SI primitive&#8217;s output terminal returns the response from its invocation and it&#8217;s tricky to propagate the original request to the parent flow. Particularly when you don&#8217;t know what this original request looks like!</p>
<p>This post focuses on how to model you data and build a reusable subflow to perform message enrichment without knowing the specific message type you&#8217;re operating on.</p>
<p>And the reason we are using a subflow, as opposed to a service gateway pattern is because, when a subflow lives in a shared library, it can be selectively reused as if it were a mediation primitive. So we can create a new module, or a new component in an existing assembly, or add it as a primitive to an existing mediation flow. It is a very flexible approach.</p>
<p>The linchpin that enables us to build generic subflows lies in the design and modeling of interfaces and data objects. We would like the subflow to be message type agnostic, we want it to operate within the context of various interactions. In other words, we make no assumptions on the shape and size of the parent flow we might find ourselves within.</p>
<p>But we must have <em>some </em>certainties. Like, if we use the subflow (as in this example) for message enrichment, at some point we will need to navigate to elements in the message body.</p>
<p>In order to guarantee those certainties we will enforce a set of best practices at design time.</p>
<ol>
<li>Every interface operation has a single input, a single output, and a common set of faults.</li>
</ol>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-4.jpg"><img class="alignnone size-full wp-image-391" style="border:1px solid black;" title="screenshot.4" src="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-4.jpg?w=630" alt=""   /></a></p>
<ol start="2">
<li>Every message type inherits from a base type. This base type contains attributes common to all messages. These are our certainties.</li>
</ol>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-25.jpg"><img class="alignnone size-full wp-image-405" style="border:1px solid black;" title="screenshot.25" src="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-25.jpg?w=630" alt=""   /></a></p>
<p>The picture above shows the input parameter type for the retrieveCustomerDetails operation. We create the RetrieveCustomerDetailsRequest business object by inheriting from BaseRequest. The BaseRequest has a attribute that we choose to name &#8216;header&#8217; of type RequestHeader, which itself inherits from CommonHeader.</p>
<p>Any attribute we model into the CommonHeader BusinessObject is guaranteed to be present in the message. We just need to figure out how to navigate to them (later).</p>
<p>The same is true for faults: create faults that inherit from a BaseFault, add a BaseFault attribute named consistletly (this example uses &#8216;header&#8217;), and make this attribute a superset of CommonHeader. This will ensure your certainties will be also present in faults.</p>
<p>We can start building the subflow now. Create the subflow in a shared library so you can reuse it from any project depending on it.</p>
<p>The purpose of the subflow in this particular example will be to populate a regionId attribute, which is present in all messages (because is a CommonHeader attribute).</p>
<p>We can call this subflow EnrichRegionId. Below is a screen capture of the complete subflow in the mediation flow editor.</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-33.jpg"><img class="alignnone size-full wp-image-429" style="border:1px solid black;" title="screenshot.33" src="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-33.jpg?w=630" alt=""   /></a></p>
<p>At the heart of the subflow there is a Service Invoke primitive, the purpose of which is to retrieve a region code from an external system.</p>
<p>The sublow has an input and three output nodes, the input represents the request message as passed in by the parent flow, the first output will propagate the enriched request message to the parent flow, and the following two output nodes are used for propagating faults.</p>
<p><strong>For those three nodes, their terminal message types are set to anyType.</strong></p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-7.jpg"><img class="alignnone size-full wp-image-415" style="border:1px solid black;" title="screenshot.7" src="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-7.jpg?w=630" alt=""   /></a></p>
<p>What this means is that, at development time, the tooling is told that any WSDL type can be fired in or out of these terminals (at runtime this is always true, terminal type information exists for the primary benefit of the tooling).</p>
<p>This is one of the V7 improvements I like the most. I can force V6 into something similar but it is nowhere near as elegant.</p>
<p>Now, lets take a look at what&#8217;s going on in the subflow.</p>
<p>I have no idea of which message type I will receive, the service invoke primitive half way down the flow loses my request (its output terminals all relate to its own operation) and I have to find a way to propagate it to the parent flow.</p>
<p>The solution is to keep the /body part of the message in context throughout the flow, using a message element setter.</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-81.jpg"><img class="alignnone size-full wp-image-422" style="border:1px solid black;" title="screenshot.8" src="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-81.jpg?w=630" alt=""   /></a></p>
<p>I used the correlation context out of habit. I don&#8217;t have a response flow to worry about here. The context type is xsdAny, so any body type can be safely stored here. One thing to watch out for is developers modeling context data at the parent flow level. This can break things and has to be worked around (by asking developers to include an xsdAny attribute in their context objects, that the subflow can use to store the body), but lets keep it simple.</p>
<p>So that&#8217;s my request body stored away. Now we have to operate on /body attributes on a /body type which is mostly unknown.</p>
<p>All we know are the certainties we designed into our data model.</p>
<p>We also know that, for as long as we use the default binding style on our interfaces (document literal wrapped) the SMO path into the body payload will be predictable.</p>
<p>Heres what the SMO representation of an updateCustomerDetails request looks like:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-11.jpg"><img class="alignnone size-full wp-image-424" style="border:1px solid black;" title="screenshot.11" src="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-11.jpg?w=630" alt=""   /></a></p>
<p>We can get hold of /body, the &#8216;header&#8217; attribute is our designed in certainty, but we know nothing about what&#8217;s between them. All we know is that we are going to find an attribute called &#8216;header&#8217; two levels down from /body.</p>
<p>The good news is that we can use custom XPath to navigate to it:</p>
<p>In my XML map, the one that provides the Service Invoke with its input parameters, I use a custom XPath transform to retrieve a field from the body in the correlation context:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-28.jpg"><img class="alignnone size-full wp-image-425" style="border:1px solid black;" title="screenshot.28" src="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-28.jpg?w=630" alt=""   /></a></p>
<p>You can see how if hop over the uncertainties to get to what I need.</p>
<p>After the service invoke, I use a message element setter to enrich the body and propagate it to the parent flow:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-39.jpg"><img class="alignnone size-full wp-image-437" style="border:1px solid black;" title="screenshot.39" src="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-39.jpg?w=630" alt=""   /></a></p>
<p>1 enriches the message body currently in context and 2 copies it to the body propagated to the parent flow.</p>
<p>Here&#8217;s a closer look at 1:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-40.jpg"><img class="alignnone size-full wp-image-440" style="border:1px solid black;" title="screenshot.40" src="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-40.jpg?w=630" alt=""   /></a></p>
<p>The external system used to retrieve the region id is mediated, so the service invoke uses an internal interface which can return the same faults used throughout the solution. This means I can simply wire those faults to the corresponding output nodes. I&#8217;m treating service invoke timeouts and failures as serviceFaults so I can transform and wire those too.</p>
<p>At parent flow level, adding the subflow is very simple. Just drop it in the request flow editor, wire it up and accept the automatic casting proposed by WID (those Set Message Type primitives are automatically generated):</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-41.jpg"><img class="alignnone size-full wp-image-443" style="border:1px solid black;" title="screenshot.41" src="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-41.jpg?w=630" alt=""   /></a></p>
<p>The response flow is inconsequential. Simple wires for message pass-through:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-36.jpg"><img class="alignnone size-full wp-image-432" style="border:1px solid black;" title="screenshot.36" src="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-36.jpg?w=630" alt=""   /></a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/soatipsntricks.wordpress.com/387/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/soatipsntricks.wordpress.com/387/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/soatipsntricks.wordpress.com/387/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/soatipsntricks.wordpress.com/387/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/soatipsntricks.wordpress.com/387/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/soatipsntricks.wordpress.com/387/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/soatipsntricks.wordpress.com/387/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/soatipsntricks.wordpress.com/387/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/soatipsntricks.wordpress.com/387/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/soatipsntricks.wordpress.com/387/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/soatipsntricks.wordpress.com/387/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/soatipsntricks.wordpress.com/387/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/soatipsntricks.wordpress.com/387/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/soatipsntricks.wordpress.com/387/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=soatipsntricks.wordpress.com&amp;blog=504053&amp;post=387&amp;subd=soatipsntricks&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://soatipsntricks.wordpress.com/2011/02/01/building-a-reusable-subflow/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/53c4db1def8790eb82e156a96b43ede6?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">gtelerman</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-4.jpg" medium="image">
			<media:title type="html">screenshot.4</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-25.jpg" medium="image">
			<media:title type="html">screenshot.25</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-33.jpg" medium="image">
			<media:title type="html">screenshot.33</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-7.jpg" medium="image">
			<media:title type="html">screenshot.7</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-81.jpg" medium="image">
			<media:title type="html">screenshot.8</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-11.jpg" medium="image">
			<media:title type="html">screenshot.11</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-28.jpg" medium="image">
			<media:title type="html">screenshot.28</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-39.jpg" medium="image">
			<media:title type="html">screenshot.39</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-40.jpg" medium="image">
			<media:title type="html">screenshot.40</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-41.jpg" medium="image">
			<media:title type="html">screenshot.41</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/02/screenshot-36.jpg" medium="image">
			<media:title type="html">screenshot.36</media:title>
		</media:content>
	</item>
		<item>
		<title>Capturing HTTP Status Code on One-Way Web Service Operations</title>
		<link>http://soatipsntricks.wordpress.com/2011/01/20/capturing-http-status-code-on-one-way-web-service-operations/</link>
		<comments>http://soatipsntricks.wordpress.com/2011/01/20/capturing-http-status-code-on-one-way-web-service-operations/#comments</comments>
		<pubDate>Thu, 20 Jan 2011 15:12:40 +0000</pubDate>
		<dc:creator>Gabriel Telerman</dc:creator>
				<category><![CDATA[Enterprise Service Bus]]></category>
		<category><![CDATA[Integration Developer]]></category>
		<category><![CDATA[Process Server]]></category>
		<category><![CDATA[SOA]]></category>
		<category><![CDATA[SOAP/HTTP]]></category>
		<category><![CDATA[Web Services]]></category>
		<category><![CDATA[WebSphere]]></category>

		<guid isPermaLink="false">http://soatipsntricks.wordpress.com/?p=339</guid>
		<description><![CDATA[I am working on a project using WID/WPS/WESB v6.2.0.2 and was asked recently if a mediation flow could capture HTTP response codes from a back-end web service one-way operation. Naturally my advice was that if an operation describes neither response nor faults, the client is not expected to care about what happens after the request [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=soatipsntricks.wordpress.com&amp;blog=504053&amp;post=339&amp;subd=soatipsntricks&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I am working on a project using WID/WPS/WESB v6.2.0.2 and was asked recently if a mediation flow could capture HTTP response codes from a back-end web service one-way operation.</p>
<p>Naturally my advice was that if an operation describes neither response nor faults, the client is not expected to care about what happens after the request is posted to the service.</p>
<p>Nonetheless, I set about providing a solution, which I would class as a &#8216;trick&#8217;, and hence worthy of a first post in this appropriately named blog.</p>
<p>In summary, the trick consists in calling the web service using an import with HTTP bindings using SOAP/HTTP data serialisation format and basically lying on the import interface. Shameless, but effective.</p>
<p>So, let me show you the trick in more detail.</p>
<p>Lets pretend we have a CustomerService with an addCustomer one-way operation that accepts a Customer as input. Go ahead and create a library named LB_Customer, an interface named CustomerService and a DataObject called Customer.</p>
<p>Then create a module called CustomerService with a Java SCA component just logging the Customer attributes and a web services export. I chose SOAP1.1/HTTP using JAX-RPC. Well, I had no choice. This is the standard in this project.</p>
<p>So, here&#8217;s the assembly:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-11.jpeg"><img class="alignnone size-full wp-image-351" style="border:1px solid black;" title="screenshot.1" src="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-11.jpeg?w=630" alt=""   /></a></p>
<p>Here&#8217;s the CustomerService interface:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-21.jpeg"><img class="alignnone size-full wp-image-345" style="border:1px solid black;" title="screenshot.2" src="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-21.jpeg?w=630" alt=""   /></a></p>
<p>And here&#8217;s the Customer data type:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-3.jpeg"><img class="alignnone size-full wp-image-342" style="border:1px solid black;" title="screenshot.3" src="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-3.jpeg?w=630" alt=""   /></a></p>
<p>Oh, and the very simple Java component code:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-41.jpeg"><img class="alignnone size-full wp-image-352" style="border:1px solid black;" title="screenshot.4" src="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-41.jpeg?w=630" alt=""   /></a></p>
<p>You can go ahead, deploy and test. We&#8217;re done with the pretence and we can move on to the real trick.</p>
<p>Now create a mediation module, call it MM_CustomerService and do <strong><em>not </em></strong>make the library a dependency. Within this mediation project create your own copy of the Customer data type and the CustomerService interface, but make the addCustomer operation request-response and create a new Response data type.</p>
<p>Here&#8217;s the mediation&#8217;s private CustomerService interface:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-51.jpeg"><img class="alignnone size-full wp-image-348" style="border:1px solid black;" title="screenshot.5" src="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-51.jpeg?w=630" alt=""   /></a></p>
<p>And here&#8217;s the Response data type, also private to the mediation:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-6.jpeg"><img class="alignnone size-full wp-image-349" style="border:1px solid black;" title="screenshot.6" src="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-6.jpeg?w=630" alt=""   /></a></p>
<p>The private Customer data type is an exact copy of the one in the library used by the target service.</p>
<p>At this point it might be worth showing you my business integration view, so you can check all your bits and pieces are in the right place:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-7.jpeg"><img class="alignnone size-full wp-image-350" style="border:1px solid black;" title="screenshot.7" src="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-7.jpeg?w=630" alt=""   /></a></p>
<p>Now comes the hack. You have to make sure the CustomerService interface which is part of the MM_CustomerService mediation project has the <strong>same namespace</strong> as the one in the library. So go ahead and change it. Go to the interface properties and change the namespace to http://LB_Customer/CustomerService. I told you there was some lying involved.</p>
<p>Now you can assign this interface to your mediation flow component, both as an interface and a reference. Then drop an import into the assembly, wire it to the mediation flow component&#8217;s reference and accept the creation of a matching interface on the import.</p>
<p>Right-click on the import and select Generate Binding&#8230;-&gt; HTTP Binding. You will have to provide the endpoint URL. You can copy it from the binding tab on the properties for the web services export on the CustomerService assembly.</p>
<p>Here&#8217;s a screenshot of the complete assembly:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-8.jpeg"><img class="alignnone size-full wp-image-353" style="border:1px solid black;" title="screenshot.8" src="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-8.jpeg?w=630" alt=""   /></a></p>
<p>Go to the properties for the HttpImport, Binding tab, and select SOAP (HTTP) as the default data format. You will need to check the box to show deprecated data formats.</p>
<p>Here&#8217;s how you select the data binding:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-9.jpeg"><img class="alignnone size-full wp-image-354" style="border:1px solid black;" title="screenshot.9" src="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-9.jpeg?w=630" alt=""   /></a></p>
<p>And here&#8217;s the main Binding Properties tab:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-20.jpeg"><img class="alignnone size-full wp-image-375" style="border:1px solid black;" title="screenshot.20" src="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-20.jpeg?w=630" alt=""   /></a></p>
<p>Finally go to the Method bindings tab, select the addCustomer bound method and change the HTTP method from GET to POST.</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-10.jpeg"><img class="alignnone size-full wp-image-355" style="border:1px solid black;" title="screenshot.10" src="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-10.jpeg?w=630" alt=""   /></a></p>
<p>Now let&#8217;s implement the mediation flow.</p>
<p>The request flow is a doddle. We simply let the message pass through:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-111.jpeg"><img class="alignnone size-full wp-image-357" style="border:1px solid black;" title="screenshot.11" src="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-111.jpeg?w=630" alt=""   /></a></p>
<p>The response flow requires a couple of XML transformations for the out and fail terminals:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-12.jpeg"><img class="alignnone size-full wp-image-358" style="border:1px solid black;" title="screenshot.12" src="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-12.jpeg?w=630" alt=""   /></a></p>
<p>The two transformations operate at message root level and map the StatusCode and ReasonPhrase from the smo HTTPHeader to the response body:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-13.jpeg"><img class="alignnone size-full wp-image-359" style="border:1px solid black;" title="screenshot.13" src="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-13.jpeg?w=630" alt=""   /></a></p>
<p>You can build, and deploy the two modules now.</p>
<p>Then test the mediation flow component. I&#8217;m assuming you&#8217;re more than familiar with the integration test client.</p>
<p>What happened?</p>
<p>On this first run I can see in the Events pane that we invoked the http import and that the response fail terminal was fired, routing the response flow to the MapFail xml transform. You can also see the response values. HTTP status code 500</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-15.jpeg"><img class="alignnone size-full wp-image-364" style="border:1px solid black;" title="screenshot.15" src="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-15.jpeg?w=630" alt=""   /></a></p>
<p>So this is rather good news! Yes, something is not quite right yet but it proves that we are doing what we are supposed to. Capturing HTTP response codes for a service which is, in WSDL/SOAP terms, one-way.</p>
<p>If you have a Console view to hand, you can flounder around for an explanation to this minor frustration, but I&#8217;d rather just save you time and show you the relevant log section:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-16.jpeg"><img class="alignnone size-full wp-image-365" style="border:1px solid black;" title="screenshot.16" src="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-16.jpeg?w=630" alt=""   /></a></p>
<p>So, it looks like we are missing a SOAPAction header.</p>
<p>I&#8217;m still in fits about understanding the purpose of this header. But I understand that there must be a SOAPAction HTTP header for this to work.</p>
<p>So, go back to the properties for the HTTP Import and add an HTTP header named SOAPAction. I used a single white space for its value as there must be a value present.</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-17.jpeg"><img class="alignnone size-full wp-image-366" style="border:1px solid black;" title="screenshot.17" src="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-17.jpeg?w=630" alt=""   /></a></p>
<p>Now rebuild, republish and retest.</p>
<p>Sweet! We get a 200 OK and we can see in the log the target service doing the sysouts!</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-18.jpeg"><img class="alignnone size-full wp-image-368" style="border:1px solid black;" title="screenshot.18" src="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-18.jpeg?w=630" alt=""   /></a></p>
<p>And one last thing you may want to do is to stop the CustomerServiceApp (on the Servers view) and retest. You will get the anticipated 404 Not Found:</p>
<p><a href="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-19.jpeg"><img class="alignnone size-full wp-image-369" style="border:1px solid black;" title="screenshot.19" src="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-19.jpeg?w=630" alt=""   /></a></p>
<p>That&#8217;s it, hope you enjoyed this magic trick and feel free to contribute comments and observations, particularly if you get a chance to try something similar on v7.</p>
<p>ttfn</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/soatipsntricks.wordpress.com/339/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/soatipsntricks.wordpress.com/339/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/soatipsntricks.wordpress.com/339/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/soatipsntricks.wordpress.com/339/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/soatipsntricks.wordpress.com/339/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/soatipsntricks.wordpress.com/339/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/soatipsntricks.wordpress.com/339/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/soatipsntricks.wordpress.com/339/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/soatipsntricks.wordpress.com/339/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/soatipsntricks.wordpress.com/339/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/soatipsntricks.wordpress.com/339/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/soatipsntricks.wordpress.com/339/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/soatipsntricks.wordpress.com/339/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/soatipsntricks.wordpress.com/339/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=soatipsntricks.wordpress.com&amp;blog=504053&amp;post=339&amp;subd=soatipsntricks&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://soatipsntricks.wordpress.com/2011/01/20/capturing-http-status-code-on-one-way-web-service-operations/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/53c4db1def8790eb82e156a96b43ede6?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">gtelerman</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-11.jpeg" medium="image">
			<media:title type="html">screenshot.1</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-21.jpeg" medium="image">
			<media:title type="html">screenshot.2</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-3.jpeg" medium="image">
			<media:title type="html">screenshot.3</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-41.jpeg" medium="image">
			<media:title type="html">screenshot.4</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-51.jpeg" medium="image">
			<media:title type="html">screenshot.5</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-6.jpeg" medium="image">
			<media:title type="html">screenshot.6</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-7.jpeg" medium="image">
			<media:title type="html">screenshot.7</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-8.jpeg" medium="image">
			<media:title type="html">screenshot.8</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-9.jpeg" medium="image">
			<media:title type="html">screenshot.9</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-20.jpeg" medium="image">
			<media:title type="html">screenshot.20</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-10.jpeg" medium="image">
			<media:title type="html">screenshot.10</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-111.jpeg" medium="image">
			<media:title type="html">screenshot.11</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-12.jpeg" medium="image">
			<media:title type="html">screenshot.12</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-13.jpeg" medium="image">
			<media:title type="html">screenshot.13</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-15.jpeg" medium="image">
			<media:title type="html">screenshot.15</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-16.jpeg" medium="image">
			<media:title type="html">screenshot.16</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-17.jpeg" medium="image">
			<media:title type="html">screenshot.17</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-18.jpeg" medium="image">
			<media:title type="html">screenshot.18</media:title>
		</media:content>

		<media:content url="http://soatipsntricks.files.wordpress.com/2011/01/screenshot-19.jpeg" medium="image">
			<media:title type="html">screenshot.19</media:title>
		</media:content>
	</item>
		<item>
		<title>New Author &#8211; Gaby Telerman</title>
		<link>http://soatipsntricks.wordpress.com/2011/01/18/new-author/</link>
		<comments>http://soatipsntricks.wordpress.com/2011/01/18/new-author/#comments</comments>
		<pubDate>Tue, 18 Jan 2011 20:05:19 +0000</pubDate>
		<dc:creator>andrewferrier</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://soatipsntricks.wordpress.com/?p=336</guid>
		<description><![CDATA[Folks, some good news. After recently deciding to mothball this blog, Gaby Telerman has stepped up to the plate and offered to write some new articles on WebSphere Process Server. He doesn&#8217;t have a definite posting schedule, but watch this space&#8230; more content to come! Thanks, Gaby.<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=soatipsntricks.wordpress.com&amp;blog=504053&amp;post=336&amp;subd=soatipsntricks&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Folks, some good news. After recently deciding to mothball this blog, Gaby Telerman has stepped up to the plate and offered to write some new articles on WebSphere Process Server. He doesn&#8217;t have a definite posting schedule, but watch this space&#8230; more content to come! Thanks, Gaby.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/soatipsntricks.wordpress.com/336/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/soatipsntricks.wordpress.com/336/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/soatipsntricks.wordpress.com/336/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/soatipsntricks.wordpress.com/336/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/soatipsntricks.wordpress.com/336/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/soatipsntricks.wordpress.com/336/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/soatipsntricks.wordpress.com/336/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/soatipsntricks.wordpress.com/336/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/soatipsntricks.wordpress.com/336/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/soatipsntricks.wordpress.com/336/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/soatipsntricks.wordpress.com/336/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/soatipsntricks.wordpress.com/336/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/soatipsntricks.wordpress.com/336/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/soatipsntricks.wordpress.com/336/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=soatipsntricks.wordpress.com&amp;blog=504053&amp;post=336&amp;subd=soatipsntricks&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://soatipsntricks.wordpress.com/2011/01/18/new-author/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/a6743880175c8767ceeb624bc474f52d?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">andrewferrier</media:title>
		</media:content>
	</item>
		<item>
		<title>SOA Tips &#8216;n&#8217; Tricks &#8211; Being Mothballed</title>
		<link>http://soatipsntricks.wordpress.com/2010/12/04/soa-tips-n-tricks-being-mothballed/</link>
		<comments>http://soatipsntricks.wordpress.com/2010/12/04/soa-tips-n-tricks-being-mothballed/#comments</comments>
		<pubDate>Sat, 04 Dec 2010 14:30:05 +0000</pubDate>
		<dc:creator>andrewferrier</dc:creator>
				<category><![CDATA[Enterprise Service Bus]]></category>
		<category><![CDATA[Process Server]]></category>
		<category><![CDATA[WebSphere]]></category>

		<guid isPermaLink="false">http://soatipsntricks.wordpress.com/?p=332</guid>
		<description><![CDATA[Folks, I&#8217;ve recently taken on a new role working with IBM customers on Dojo (and if that interests you, I&#8217;ve launched a great new blog I&#8217;m very excited about at dojotipsntricks.com, so please go check that out), so there aren&#8217;t likely to be any new posts on this blog. However, I&#8217;ll leave it in place [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=soatipsntricks.wordpress.com&amp;blog=504053&amp;post=332&amp;subd=soatipsntricks&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Folks, I&#8217;ve recently taken on a new role working with IBM customers on <a href="http://www.dojotoolkit.org/">Dojo</a> (and if that interests you, I&#8217;ve launched a great new blog I&#8217;m very excited about at <a href="http://dojotipsntricks.com/">dojotipsntricks.com</a>, so please go check that out), so there aren&#8217;t likely to be any new posts on this blog. However, I&#8217;ll leave it in place for some time &#8211; hopefully there&#8217;s still some useful content on here for those working with WebSphere ESB, Process Server, and the other things I&#8217;ve written about over the past few years. Thanks for your attention!</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/soatipsntricks.wordpress.com/332/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/soatipsntricks.wordpress.com/332/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/soatipsntricks.wordpress.com/332/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/soatipsntricks.wordpress.com/332/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/soatipsntricks.wordpress.com/332/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/soatipsntricks.wordpress.com/332/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/soatipsntricks.wordpress.com/332/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/soatipsntricks.wordpress.com/332/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/soatipsntricks.wordpress.com/332/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/soatipsntricks.wordpress.com/332/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/soatipsntricks.wordpress.com/332/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/soatipsntricks.wordpress.com/332/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/soatipsntricks.wordpress.com/332/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/soatipsntricks.wordpress.com/332/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=soatipsntricks.wordpress.com&amp;blog=504053&amp;post=332&amp;subd=soatipsntricks&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://soatipsntricks.wordpress.com/2010/12/04/soa-tips-n-tricks-being-mothballed/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/a6743880175c8767ceeb624bc474f52d?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">andrewferrier</media:title>
		</media:content>
	</item>
	</channel>
</rss>
