<?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/"
	>

<channel>
	<title>Transentia &#187; Tools</title>
	<atom:link href="http://wordpress.transentia.com.au/wordpress/tag/tools/feed/" rel="self" type="application/rss+xml" />
	<link>http://wordpress.transentia.com.au/wordpress</link>
	<description>transentia pty. ltd.; development, consulting, training at the leading-edge of technology</description>
	<lastBuildDate>Tue, 13 Dec 2011 03:01:38 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2</generator>
		<item>
		<title>Enabling load balancing and failover in Apache CXF</title>
		<link>http://wordpress.transentia.com.au/wordpress/2011/07/13/enabling-load-balancing-and-failover-in-apache-cxf/</link>
		<comments>http://wordpress.transentia.com.au/wordpress/2011/07/13/enabling-load-balancing-and-failover-in-apache-cxf/#comments</comments>
		<pubDate>Wed, 13 Jul 2011 10:19:00 +0000</pubDate>
		<dc:creator>bob</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://wordpress.transentia.com.au/wordpress/?p=1440</guid>
		<description><![CDATA[An excellent blog post at NoBlogDefFound. Here&#8217;s the premise: A while ago we&#8217;ve faced the requirement of load-balancing web services clients based on Apache CXF. Also the clients should automatically fail-over when some of the servers are down. To make it even worse, the list of servers target addresses was to be obtained from external [...]]]></description>
			<content:encoded><![CDATA[<p>An excellent blog post at <a href="http://nurkiewicz.blogspot.com/2011/05/enabling-load-balancing-and-failover-in.html">NoBlogDefFound</a>.</p>
<p>Here&#8217;s the premise:</p>
<blockquote><p>A while ago we&#8217;ve faced the requirement of load-balancing web services clients based on <a href="http://cxf.apache.org/">Apache CXF</a>. Also the clients should automatically fail-over when some of the servers are down. To make it even worse, the list of servers target addresses was to be obtained from external service and updated at runtime. &#8230;If we only knew Apache CXF already supports all these features (almost) out of the box?</p></blockquote>
<p>Well worth remembering for future projects.</p>
]]></content:encoded>
			<wfw:commentRss>http://wordpress.transentia.com.au/wordpress/2011/07/13/enabling-load-balancing-and-failover-in-apache-cxf/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The Agile Coach Toolkit</title>
		<link>http://wordpress.transentia.com.au/wordpress/2011/07/11/the-agile-coach-toolkit/</link>
		<comments>http://wordpress.transentia.com.au/wordpress/2011/07/11/the-agile-coach-toolkit/#comments</comments>
		<pubDate>Mon, 11 Jul 2011 09:43:35 +0000</pubDate>
		<dc:creator>bob</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Agile]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://wordpress.transentia.com.au/wordpress/?p=1431</guid>
		<description><![CDATA[Games, sessions, presentations themed as &#8220;Agile Every Day&#8230;Transforming Work into Play&#8221; and released under the Creative Commons 2.0 license.]]></description>
			<content:encoded><![CDATA[<p>Games, sessions, presentations themed as &#8220;<a href="http://www.agilecoach.net/">Agile Every Day&#8230;Transforming Work into Play</a>&#8221; and released under the Creative Commons 2.0 license.</p>
]]></content:encoded>
			<wfw:commentRss>http://wordpress.transentia.com.au/wordpress/2011/07/11/the-agile-coach-toolkit/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>A Great JBoss Resource</title>
		<link>http://wordpress.transentia.com.au/wordpress/2011/07/10/a-great-jboss-resource/</link>
		<comments>http://wordpress.transentia.com.au/wordpress/2011/07/10/a-great-jboss-resource/#comments</comments>
		<pubDate>Sat, 09 Jul 2011 18:00:17 +0000</pubDate>
		<dc:creator>bob</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://wordpress.transentia.com.au/wordpress/?p=1414</guid>
		<description><![CDATA[I am sure that I will be visiting http://www.mastertheboss.com/ a fair bit. So should you, if you are a JBoss developer. If you aren&#8217;t a JBoss developer: what&#8217;s holding you back?]]></description>
			<content:encoded><![CDATA[<p>I am sure that I will be visiting <a href="http://www.mastertheboss.com/">http://www.mastertheboss.com/</a> a fair bit.</p>
<p>So should you, if you are a <a href="http://www.jboss.org/jbossas">JBoss</a> developer.</p>
<p>If you aren&#8217;t a JBoss developer: <a href="http://www.badbossology.com/">what&#8217;s holding you back</a>?</p>
]]></content:encoded>
			<wfw:commentRss>http://wordpress.transentia.com.au/wordpress/2011/07/10/a-great-jboss-resource/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>SQL-99 Complete, Really</title>
		<link>http://wordpress.transentia.com.au/wordpress/2011/07/09/sql-99-complete-really/</link>
		<comments>http://wordpress.transentia.com.au/wordpress/2011/07/09/sql-99-complete-really/#comments</comments>
		<pubDate>Sat, 09 Jul 2011 04:05:11 +0000</pubDate>
		<dc:creator>bob</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://wordpress.transentia.com.au/wordpress/?p=1408</guid>
		<description><![CDATA[This section of the AskMonty Knowledgebase beta contains the full text of the book SQL-99 Complete, Really, by Peter Gulutzan &#038; Trudy Pelzer. I have already admitted to being an SQL Klutz, so having this sort of thing readily at hand is very worthwhile.]]></description>
			<content:encoded><![CDATA[<p>This section of the <a href="http://kb.askmonty.org/en/sql-99">AskMonty Knowledgebase beta</a> contains the full text of the book <em>SQL-99 Complete, Really</em>, by Peter Gulutzan &#038; Trudy Pelzer.</p>
<p>I have <a href="2009/03/19/you-learn-something-new-every-day/">already</a> <a href="2009/12/23/a-visual-explanation-of-sql-joins/">admitted</a> to being an SQL <a href="http://dictionary.reference.com/browse/klutz">Klutz</a>, so having this sort of thing readily at hand is very worthwhile.</p>
]]></content:encoded>
			<wfw:commentRss>http://wordpress.transentia.com.au/wordpress/2011/07/09/sql-99-complete-really/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Crazy Cool?</title>
		<link>http://wordpress.transentia.com.au/wordpress/2011/07/09/crazy-cool/</link>
		<comments>http://wordpress.transentia.com.au/wordpress/2011/07/09/crazy-cool/#comments</comments>
		<pubDate>Sat, 09 Jul 2011 03:53:02 +0000</pubDate>
		<dc:creator>bob</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://wordpress.transentia.com.au/wordpress/?p=1400</guid>
		<description><![CDATA[I really can&#8217;t decide whether this actually IS crazy cool, or just the ultimate in BWC*. Still here it is&#8230;Linux booting into a PC emulated in JavaScript inside a browser. The obligatory screen shot: It worked for me in IE9, on my iPad 1 and iPhone 4. What it does do, it does surprisingly quickly: [...]]]></description>
			<content:encoded><![CDATA[<p>I really can&#8217;t decide whether this actually IS crazy cool, or just the ultimate in BWC*.</p>
<p>Still here it is&#8230;<a href="http://bellard.org/jslinux/">Linux booting into a PC emulated in JavaScript inside a browser</a>.</p>
<p>The obligatory screen shot:</p>
<p><img src="http://wordpress.transentia.com.au/wordpress/wp-content/uploads/2011/07/JSInBrowser.png" alt="" title="JSInBrowser" width="529" height="458" /></p>
<p>It worked for me in IE9, on my iPad 1 and iPhone 4.</p>
<p>What it does do, it does surprisingly quickly: it boots faster than my <a href="thecus.com">linux-based NAS</a>&#8230;</p>
<p>Even the tcc compiler works!</p>
<p>Sadly, only lo0 exists.</p>
<p>As the developer suggests, this could be a great way of teaching introductory Linux/C.</p>
<p>* <small><em>Because We Can</em></small></p>
]]></content:encoded>
			<wfw:commentRss>http://wordpress.transentia.com.au/wordpress/2011/07/09/crazy-cool/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>If I Said You Had A Beautiful Body, Would You Hold It Against Me?</title>
		<link>http://wordpress.transentia.com.au/wordpress/2011/05/10/if-i-said-you-had-a-beautiful-body-would-you-hold-it-against-me/</link>
		<comments>http://wordpress.transentia.com.au/wordpress/2011/05/10/if-i-said-you-had-a-beautiful-body-would-you-hold-it-against-me/#comments</comments>
		<pubDate>Tue, 10 May 2011 11:39:30 +0000</pubDate>
		<dc:creator>bob</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[GPars]]></category>
		<category><![CDATA[Grails]]></category>
		<category><![CDATA[Griffon]]></category>
		<category><![CDATA[Groovy]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://wordpress.transentia.com.au/wordpress/?p=1261</guid>
		<description><![CDATA[I have been meaning to put this stuff up for simply ages. For the Open Source Developers&#8217; Conference 2009 I created a number of &#8220;mini fliers&#8221; that we placed around the conference&#8217;s public areas in an effort to attract attendees to come to the Groovy BOF that we were holding. The first rule of advertising [...]]]></description>
			<content:encoded><![CDATA[<p>I have been meaning to put this stuff up for simply <em>ages</em>.</p>
<p>For the <a href="http://2009.osdc.com.au/">Open Source Developers&#8217; Conference 2009</a> I created a number of &#8220;mini fliers&#8221; that we placed around the conference&#8217;s public areas in an effort to attract attendees to come to the Groovy BOF that we were holding.</p>
<p>The first rule of advertising is to get people&#8217;s attention. Doesn&#8217;t matter how corny your effort is. Hell&#8230;the cornier the better! </p>
<p>Thus:</p>
<p><img src="http://wordpress.transentia.com.au/wordpress/wp-content/uploads/2011/05/groovy_osdc_beautiful_body.png" alt="" title="groovy_osdc_beautiful_body" width="776" height="155" style="border:1px solid #222222" /></p>
<p>There are many more gems like this in the <a href='http://wordpress.transentia.com.au/wordpress/wp-content/uploads/2011/05/Groovy-Lines-For-OSDC-BOF.docx'>source document</a> (Microsoft Word format. Ahhh the <a href="http://en.wikipedia.org/wiki/Irony">irony</a>. Please don&#8217;t hold it against me&#8230;).</p>
<p>Hope these can be useful to someone else.</p>
<p>Enjoy!</p>
]]></content:encoded>
			<wfw:commentRss>http://wordpress.transentia.com.au/wordpress/2011/05/10/if-i-said-you-had-a-beautiful-body-would-you-hold-it-against-me/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Unit Testing XQuery Using OSB&#8217;s API</title>
		<link>http://wordpress.transentia.com.au/wordpress/2010/11/20/unit-testing-xquery-using-osbs-api-2/</link>
		<comments>http://wordpress.transentia.com.au/wordpress/2010/11/20/unit-testing-xquery-using-osbs-api-2/#comments</comments>
		<pubDate>Sat, 20 Nov 2010 04:09:56 +0000</pubDate>
		<dc:creator>bob</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Groovy]]></category>
		<category><![CDATA[OSB]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Retrospectives]]></category>
		<category><![CDATA[SOA]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[XQuery]]></category>

		<guid isPermaLink="false">http://wordpress.transentia.com.au/wordpress/?p=1183</guid>
		<description><![CDATA[As regular readers (all one[?] of you) will know, I have recently been subjected to the woeful Oracle Service Bus. Concomitant with my attempts to be a good modern developer, one of the first entries on my Fings Wot I Need To Find Out More About list went something like: Given that almost all of [...]]]></description>
			<content:encoded><![CDATA[<p>As regular readers (all one[?] of you) will know, I have <a href="http://wordpress.transentia.com.au/wordpress/2010/11/07/the-emperors-new-service-bus/">recently</a> been subjected to the <a href="http://www.crazymcphee.net/x/2010/07/12/the-ordeal-of-installing-oracle-service-bus-on-a-windows-based-developer-workstation/">woeful</a> Oracle Service Bus.</p>
<p>Concomitant with my attempts to be a good modern developer, one of the first entries on my <em>Fings Wot I Need To Find Out More About</em> list went something like:</p>
<blockquote><p>Given that almost all of the actual &#8216;code&#8217; in my system will be XQuery transformations, how do I unit-test those transformations with JUnit? It is obviously important that I use the weblogic API/Jars, not some external or third-party system.</p></blockquote>
<p><strong>Roughly six months</strong> later I am finally in a position to answer that question!</p>
<p>Took me a few goes (turns out that there are a number of different potential red-herring APIs to filter out and reject, including BEAs <a href="http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.92.2337&amp;rep=rep1&amp;type=pdf">xdbc</a>), a number of visits to <a href="http://www.javamonamour.org/2010/05/xquery-and-unit-tests.html">other</a> <a href="http://biemond.blogspot.com/2008/11/using-xquery-in-jdeveloper-11g-and.html">people</a>&#8216;s <a href="http://blogs.oracle.com/knutvatsendvik/2010/03/unit_testing_framework_for_xquery.html">attempts</a> and about 20 messages on the Oracle forum (gotta say I appreciated the comment &#8220;I just wanted to praise your discipline and devotion to research and investigation. Kudos!&#8221; that I picked up along the way&#8230;) but here I am.</p>
<p>This is the Groovy JUnit4 test class, just to prove that it can be done:</p>
<pre>package transentia.test

import org.junit.*
import transentia.XQueryTransformer

class XQTest {
  def xqt

  @Before
   void setup() {
    xqt = new XQueryTransformer("xqueries/Messier.xq",
                                 src: new File("xml/Messier.xml"),
                                 str: 'hello, world',
                                 n: 42,
                                 b: true,
                                 dt: new Date(),
                                 f: Math.PI,
                                 nd: null as Date)
  }

  @Test
  void testTransform() {
    xqt.withString { str -&gt;
      println str
    }
  }

  @Test
  void testSlurping() {
    xqt.withString { str -&gt;
      def data = new XmlSlurper().parseText(str).declareNamespace(oth: "http://other")
      assert data.'oth:m'.size() == 5
      assert data.'oth:m'[3].text() == 'Scorpius'
    }
  }

  @Test
  void testParsing() {
    xqt.withString { str -&gt;
      def data = new XmlParser().parseText(str)
      assert data.'oth:m'.size() == 5
      assert data.'oth:m'[4].text() == 'Serpens'
    }
  }
}</pre>
<p>Pretty trivial.</p>
<p>This is the XQuery that is under test:</p>
<p><img src="http://wordpress.transentia.com.au/wordpress/wp-content/uploads/2010/11/Messier.xq_.png" alt="" title="Messier.xq" width="600" class="alignnone size-full wp-image-1225" /></p>
<p>(Strangely, wordpress simply <em>refuses</em> to display this file without barfing. Can&#8217;t for the life of me work out why, hence the above is an image. <a href='http://wordpress.transentia.com.au/wordpress/wp-content/uploads/2010/11/Messier.xq_.txt'>Here&#8217;s the real file</a>)</p>
<p>Notice the &lt;destination:m?&gt; bit? That trailing question mark is a BEA extension to the standard XQuery language: <a href="http://download.oracle.com/docs/cd/E13167_01/aldsp/docs30/xquery/extensions.html">&#8220;Optional Indicator in Direct Element and Attribute Constructors.&#8221;</a> Very useful but not widely advertised/supported (which basically accounts for why it took me 6 months to work out how to handle it).</p>
<p>Next is the XML file:</p>
<pre>&lt;?xml version="1.0" standalone="yes" ?&gt;
&lt;MESSIER xmlns="http://transentia"&gt;
  &lt;M INDEX="1"&gt;
    &lt;CONSTELLATION&gt;Taurus&lt;/CONSTELLATION&gt;
    &lt;DESCRIPTION&gt;Diffuse Nebula&lt;/DESCRIPTION&gt;
  &lt;/M&gt;
  &lt;M INDEX="2"&gt;
    &lt;CONSTELLATION&gt;Aqarius&lt;/CONSTELLATION&gt;
    &lt;DESCRIPTION&gt;Globular Cluster&lt;/DESCRIPTION&gt;
  &lt;/M&gt;
  &lt;M INDEX="3"&gt;
    &lt;CONSTELLATION&gt;Canes Venatici&lt;/CONSTELLATION&gt;
    &lt;DESCRIPTION&gt;Globular Cluster&lt;/DESCRIPTION&gt;
  &lt;/M&gt;
  &lt;M INDEX="4"&gt;
    &lt;CONSTELLATION&gt;Scorpius&lt;/CONSTELLATION&gt;
    &lt;DESCRIPTION&gt;Globular Cluster&lt;/DESCRIPTION&gt;
  &lt;/M&gt;
  &lt;M INDEX="5"&gt;
    &lt;CONSTELLATION&gt;Serpens&lt;/CONSTELLATION&gt;
    &lt;DESCRIPTION&gt;Globular Cluster&lt;/DESCRIPTION&gt;
  &lt;/M&gt;
  &lt;M INDEX="6"&gt;
    &lt;DESCRIPTION&gt;ONLY FOR TESTING&lt;/DESCRIPTION&gt;
  &lt;/M&gt;
&lt;/MESSIER&gt;</pre>
<p>This file is just a tiny amount of fixture data for testing.</p>
<p>The missing &lt;CONSTELLATION&gt; element within the final &lt;M&gt; element should &#8216;trigger&#8217; the XQuery engine to elide the empty &lt;destination:m /&gt; element that it would normally produce; thus the tests are all expecting 5 elements in the transformed XML, not 6 as in the source.</p>
<p>And now&#8230;without further ado&#8230;the <a href="http://en.wikipedia.org/wiki/Pièce_de_résistance">pièce de résistance</a>:</p>
<pre>
package transentia

import org.apache.xmlbeans.XmlObject
import org.apache.xmlbeans.XmlOptions
import org.apache.xmlbeans.XmlDateTime
import org.apache.xmlbeans.XmlBoolean
import org.apache.xmlbeans.XmlInteger
import org.apache.xmlbeans.XmlDouble
import org.apache.xmlbeans.XmlString

class XQueryTransformer {
  private final resultXML

  public XQueryTransformer(map, xQueryTransformSource) {

    XmlObject xmlObject = XmlObject.Factory.newInstance()
    XmlOptions options = new XmlOptions()

    options.setXqueryVariables(createOptions(map))

    XmlObject[] results = xmlObject.execQuery(new File(xQueryTransformSource).text, options)

    resultXML = results[0].xmlText(new XmlOptions().setSavePrettyPrint().setSavePrettyPrintIndent(2))
  }

  private createOptions(map) {
    def optionsMap = [:]
    map.each { k, v ->
      switch (v?.class) {
        case Date:
          XmlDateTime dt = XmlDateTime.Factory.newInstance();
          dt.setDateValue(v)
          optionsMap.put(k, dt)
          break
        case Boolean:
          XmlBoolean b = XmlBoolean.Factory.newInstance();
          b.set(v)
          optionsMap.put(k, b)
          break
        case [BigInteger, Integer, Long, Short, Byte, byte, short, int, long]:
          XmlInteger i = XmlInteger.Factory.newInstance();
          i.setBigIntegerValue(v as BigInteger)
          optionsMap.put(k, i)
          break
        case [BigDecimal, Float, Double, float, double]:
          XmlDouble xd = XmlDouble.Factory.newInstance();
          xd.setDoubleValue(v as double)
          optionsMap.put(k, xd)
          break
        case String:
          XmlString string = XmlString.Factory.newInstance();
          string.setStringValue(v);
          optionsMap.put(k, string)
          break
        case File:
          def txt = v.text

          // look for the prologue < ?xml ...?> processing instruction
          def m = txt =~ /(\< \?xml[^>]*\>)/
          if (m.count > 0) {
            def xmlPI = m[0][1]
            txt = """${xmlPI}
<temp42 :root42 xmlns:temp42='temp42'>${txt[xmlPI.size()..-1]}</temp42>
"""
          }
          else
            txt = "<temp42 :root42 xmlns:temp42='temp42'>${txt}</temp42>"

          // all the messing around with xml processing instruction/adding a new root above is because
          // selectChildren seems to be required. Don't know why...
          optionsMap.put(k, XmlObject.Factory.parse(txt).selectChildren("temp42", "root42")[0])
          break

        case null:
          XmlObject n = XmlObject.Factory.newInstance()
          n.setNil()
          optionsMap.put(k, n)
          break

        default:
          throw new Exception("Unhandled type: ${v.class}")
          break
      }
    }
    optionsMap
  }

  def withString(c) {
    c.call resultXML
  }
}
</pre>
<p>I&#8217;ve <a href="/wordpress/2010/02/23/the-old-groovy-switch-eroo-again/">said</a> it <a href="/wordpress/2009/03/11/inventing-a-new-statement-for-groovy-in-10- minutes/">before</a> and I&#8217;ll most likely say it again: <em>love</em> the Groovy switch statement!</p>
<p>A bit of clarification for the &#8216;File&#8217; case is in order, I guess because it&#8217;s quite confusing! I found that I had to wrap a dummy <temp42 :root42> root element around the original root <messier> element in order to immediately select only the single child element (the original </messier><messier>)&#8230;this is why I need to isolate the processing instruction: the opening tag has to go between the PI and the </messier><messier> tags. It seemed easiest to do this with simple string manipulation&#8230;</p>
<p>Here is the tricky bit&#8230;the various jars that need to be placed on the classpath:</p>
<pre>
oracle.nlsrtl_11.1.0\orai18n-collation.jar
oracle.xdk_11.1.0\xquery.jar
com.bea.core.xml.xmlbeans_2.0.0.0_2-5-1.jar
com.bea.core.xquery.xmlbeans-interop_1.3.0.0.jar
com.bea.core.binxml_1.3.0.0.jar
oracle.xdk_11.1.0\xml.jar
com.bea.core.xquery_1.3.0.0.jar
oracle.xdk_11.1.0\xmlparserv2.jar
com.bea.core.xquery.beaxmlbeans-interop_1.3.0.0.jar
weblogic.server.modules.xquery_10.3.3.0.jar
</pre>
<p>(Note the ordering: this is what <a href="http://confluence.jetbrains.net/display/IDEADEV/IDEA+X+EAP">IntelliJ X EAP</a> worked out for me; who am I to argue&#8230;)</p>
<p>And to cut out any confusion, here&#8217;s what I have in my Intellij project:</p>
<pre>
C:\DEVELOPMENT\XQueryTester&gt;tree /f /a
Folder PATH listing for volume Bugblatter
Volume serial number is 42E3-A91B
C:.
|   XQueryTester.iml
|
...
|
+---lib
|   |   com.bea.core.binxml_1.3.0.0.jar
|   |   com.bea.core.xml.xmlbeans_2.0.0.0_2-5-1.jar
|   |   com.bea.core.xquery.beaxmlbeans-interop_1.3.0.0.jar
|   |   com.bea.core.xquery.xmlbeans-interop_1.3.0.0.jar
|   |   com.bea.core.xquery_1.3.0.0.jar
|   |
|   +---modules
|   |   \---features
|   |           weblogic.server.modules.xquery_10.3.3.0.jar
|   |
|   +---oracle.nlsrtl_11.1.0
|   |       orai18n-collation.jar
|   |
|   \---oracle.xdk_11.1.0
|           xml.jar
|           xmlparserv2.jar
|           xquery.jar
|
...
|
+---src
|   \---transentia
|       |   XQueryTransformer.groovy
|       |
|       \---test
|               XQTest.groovy
|
+---xml
|       Messier.xml
|
\---xqueries
        Messier.xq

C:\DEVELOPMENT\XQueryTester&gt;
</pre>
<p>All requisite jars can be found within the OSB 11g installation.</p>
<blockquote><p><strong>Update 2011 01 01</strong>; at least one person has read this and given me some feedback:</p>
<p><em>I needed to add com.bea.core.antlr_2.7.7.jar to the build path as<br />
well. Maybe it&#8217;s because I use Eclipse and not IDEA.</em></p>
<p>Thanks, Morten!</p></blockquote>
<p>The proof, as &#8216;they&#8217; say is in the pudding&#8230;</p>
<p>Here&#8217;s the passing case:</p>
<p><img src="http://wordpress.transentia.com.au/wordpress/wp-content/uploads/2010/11/XQTestSuccess.png" /></p>
<p>Now for the failing case (with the ? taken out of the XQuery transformation):</p>
<p><img src="http://wordpress.transentia.com.au/wordpress/wp-content/uploads/2010/11/XQTestFailure.png" /></p>
<p>Take a good look at the way the failed assertion is represented in the above screenshot. Something else to love about Groovy!</p>
<p>Hope this helps some other OSB user actually trying to <em>embrace</em> good software engineering practices.</p>
<p>The above isn&#8217;t perfect but it&#8217;s better than nothing. Use it; improve it; share it. Please let me know what you have done&#8230;</p>
<p>Restating something I said in the Oracle SOA Suite forums:</p>
<blockquote><p>
IMHO it is RIDICULOUS that what we are trying to achieve here is not clearly described and supported for OSB.</p>
<p>For something like Apache Camel or Spring Integration testing is a complete no-brainer. For OSB it seems almost impossible to do properly. For me this is a (/one of the) killer points AGAINST OSB.
</p></blockquote>
<p>Its a shame that this is not available from Oracle but then one can&#8217;t really expect them to go to all that trouble of carefully crafting a tool like OSB with maximum lock-in potential and then make the APIs openly accessible, can one?<br />
(&#8230;and <strong>yes</strong> I <strong>do</strong> know the genesis of <a href="http://xmlbeans.apache.org/">Apache XMLBeans</a>&#8230;)</p>
<p>Ooohhhh&#8230;hope I&#8217;m not breaking any licensing rules here&#8230;don&#8217;t want to tangle with Oracle&#8217;s lawyers, after all!</messier></temp42></p>
]]></content:encoded>
			<wfw:commentRss>http://wordpress.transentia.com.au/wordpress/2010/11/20/unit-testing-xquery-using-osbs-api-2/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Why Spring?</title>
		<link>http://wordpress.transentia.com.au/wordpress/2010/10/18/why-spring/</link>
		<comments>http://wordpress.transentia.com.au/wordpress/2010/10/18/why-spring/#comments</comments>
		<pubDate>Mon, 18 Oct 2010 10:15:41 +0000</pubDate>
		<dc:creator>bob</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Agile]]></category>
		<category><![CDATA[Grails]]></category>
		<category><![CDATA[Griffon]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Rant]]></category>
		<category><![CDATA[Retrospectives]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://wordpress.transentia.com.au/wordpress/?p=1098</guid>
		<description><![CDATA[While taking a break from wrestling with the absurdly abominable Oracle Service Bus (OSB), I attempted to explain why, IMHO, the Spring Framework was the way to go. I&#8217;ve been known to say: &#8220;Don&#8217;t start a Java application without Spring. Ever.&#8221; The primary reason for this is versatility. I can and have used Spring to: [...]]]></description>
			<content:encoded><![CDATA[<p>While taking a break from wrestling with the absurdly abominable Oracle Service Bus (<a href="/wordpress/2010/09/13/the-emperors-new-service-bus/">OSB</a>), I attempted to explain why, IMHO, the <a href="http://www.springframework.org/">Spring Framework</a> was the way to go.</p>
<p>I&#8217;ve been known to say: &#8220;Don&#8217;t start a Java application without Spring. Ever.&#8221;</p>
<p>The primary reason for this is versatility. I can and have used Spring to:</p>
<ul>
<li>Develop various species of plain &#8216;ole web applications</li>
<li>Develop webflow-based web applications</li>
<li>Develop reporting applications incorporating <a href="http://www.eclipse.org/birt/phoenix/">eclipse BIRT</a></li>
<li>Develop Swing-based desktop applications (using <a href="http://www.steema.com/teechart/java">TeeChart</a>)</li>
<li>Develop batch processing systems</li>
<li>Helped develop XML pipeline processing systems (alongside <a href="http://www.stylusstudio.com/">Stylus Studio</a>&#8216;s XML processing framework)</li>
<li>Develop system integration processing flows</li>
<li>&#8230;and probably a few more bits and pieces&#8230;</li>
</ul>
<p>The Spring-oriented skills I have built up have let me work in a substantially standardized way regardless of the situation.</p>
<p>That&#8217;s pretty darned good, if you ask me!</p>
<p>Is this same story true of the obnoxious OSB? No.<br />
Is it true for any implementation of the J(2)EE spec.? No. From any vendor? No.<br />
Is it true for other frameworks like JBoss Seam. No.</p>
<p>Anyone know of any other framework out there offering similar flexibility, &#8216;cos I&#8217;m darned if I do.</p>
<p>The Spring framework isn&#8217;t standing still, either&#8230;it&#8217;s the foundation for both <a href="http://www.grails.org/">Grails</a> and <a href="http://griffon.codehaus.org/">Griffon</a>. As I have adopted these technologies, my productivity has increased greatly. I am &#8220;standing on the backs of Giants.&#8221; This is a <em>Really Good Thing</em>.</p>
<p>Let&#8217;s add a modicum of &#8220;<a href="http://www.systems-thinking.de/">Systems Thinking</a>&#8221; here. Rather than wasting time training a multitude of staff in a multitude of (typically short-lived)  siloed technologies&#8230;some of which are honestly horrid&#8230;it makes much more sense to build a solid core of experience with a solid core technology.</p>
<p>Whoops! Here I go advocating a standards-based ICT world&#8230;again.</p>
<p>&#8216;Standards.&#8217; &#8220;Systems Thinking.&#8221; How naive am I!</p>
<p><em>[...edit...]</em><br />
Received an email from Manning the publishers a while back:</p>
<p><a href="http://wordpress.transentia.com.au/wordpress/wp-content/uploads/2010/10/bestofdecade.png"><img src="http://wordpress.transentia.com.au/wordpress/wp-content/uploads/2010/10/bestofdecade.png" alt="" title="bestofdecade" width="629" height="326" class="alignnone size-full wp-image-1243" /></a></p>
<p>I know that this is not a scientific measure of &#8216;goodness&#8217; (if one were even possible), but it speaks volumes <em>to me&#8230;</em></p>
]]></content:encoded>
			<wfw:commentRss>http://wordpress.transentia.com.au/wordpress/2010/10/18/why-spring/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>LogMX: The Universal Log File Viewer</title>
		<link>http://wordpress.transentia.com.au/wordpress/2010/09/01/logmx-the-universal-log-file-viewer/</link>
		<comments>http://wordpress.transentia.com.au/wordpress/2010/09/01/logmx-the-universal-log-file-viewer/#comments</comments>
		<pubDate>Wed, 01 Sep 2010 09:56:42 +0000</pubDate>
		<dc:creator>bob</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://wordpress.transentia.com.au/wordpress/?p=1022</guid>
		<description><![CDATA[I was introduced to this nice tool today. Thanks Chris! Here&#8217;s the blurb: LogMX is an intuitive and easy-to-use cross platform tool for developers and administrators working with log &#038; trace files. Neat-o. Both free and commercial versions exist&#8230;]]></description>
			<content:encoded><![CDATA[<p>I was introduced to <a href="http://www.logmx.com/index.php">this nice tool</a> today. Thanks Chris!</p>
<p>Here&#8217;s the blurb:</p>
<blockquote><p>LogMX is an intuitive and easy-to-use cross platform tool for developers and administrators working with log &#038; trace files.</p></blockquote>
<p>Neat-o.</p>
<p>Both free and commercial versions exist&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://wordpress.transentia.com.au/wordpress/2010/09/01/logmx-the-universal-log-file-viewer/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Good Words On SVG From Microsoft</title>
		<link>http://wordpress.transentia.com.au/wordpress/2010/08/29/good-words-on-svg-from-microsoft/</link>
		<comments>http://wordpress.transentia.com.au/wordpress/2010/08/29/good-words-on-svg-from-microsoft/#comments</comments>
		<pubDate>Sun, 29 Aug 2010 00:39:34 +0000</pubDate>
		<dc:creator>bob</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://wordpress.transentia.com.au/wordpress/?p=1008</guid>
		<description><![CDATA[Really looking forward to Microsoft support for SVG in IE9&#8230; They seem to be finally &#8220;getting it.&#8221; As I said before: About Bloody Time! It would have made my life on an earlier project a whole lot easier.]]></description>
			<content:encoded><![CDATA[<p>Really looking forward to Microsoft support for SVG in IE9&#8230;</p>
<p>They seem to be finally <a href="http://blogs.msdn.com/b/ie/archive/2010/08/27/more-on-svg.aspx">&#8220;getting it.&#8221;</a></p>
<p>As I said before: <a href="/wordpress/2010/01/11/about-bloody-time/">About Bloody Time!</a> It would have made my life on an <a href="/wordpress/2009/02/05/oh-babi/">earlier project</a> a <em>whole lot easier.</em></p>
]]></content:encoded>
			<wfw:commentRss>http://wordpress.transentia.com.au/wordpress/2010/08/29/good-words-on-svg-from-microsoft/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

