<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
   <channel>
      <title>SOS</title>
      <link>http://blogs.iona.com/sos/</link>
      <description>Services on SOA</description>
      <language>en</language>
      <copyright>Copyright 2007</copyright>
      <lastBuildDate>Fri, 16 Nov 2007 14:37:13 +0100</lastBuildDate>
      <generator>http://www.sixapart.com/movabletype/</generator>
      <docs>http://blogs.law.harvard.edu/tech/rss</docs> 

            <item>
         <title>EJB 3.0 and JBossWS</title>
         <description><![CDATA[A couple of you have contacted me for the code for this <a href="http://blogs.iona.com/sos/2006/08/ejb_30_and_jbossws.html#comments">post</a>, you should now be able to download it <a href="http://blogs.iona.com/sos/axis_jboss_client.zip">here</a>. 

Apologies I didnt make it available sooner.
]]></description>
         <link>http://blogs.iona.com/sos/2007/11/ejb_30_and_jbossws_1.html</link>
         <guid>http://blogs.iona.com/sos/2007/11/ejb_30_and_jbossws_1.html</guid>
        
        
         <pubDate>Fri, 16 Nov 2007 14:37:13 +0100</pubDate>
      </item>
            <item>
         <title>Hola, Barcelona: Tales from the ServerSide Java Symposium Europe</title>
         <description>
I love working for IONA. Last week they sent me to the lovely city of Barcelona, to share a speaking slot at The ServerSide Java Symposium Europe. Met some great people there, and got to see some of the town too. Gotta love that Gothic Quarter... Anyway, for those that didn&apos;t make it and would like to know what&apos;s going on in the Java/Open Source/Developer landscape, read on...

The session I was speaking at was with Ted Neward, on &quot;Pragmatic XML web services with CXF and .Net&quot;. Very pleased with the attendance, about 90-100 delegates. We covered code-first service design, .Net interoperability, RESTful services, scripting languages (DSLs) and JSON, Lots of interest afterwards, including around my WSDL Versioning Best Practice. All good - thanks Ted!

The SOA Industry Leaders panel session, with Oisin Hurley (IONA), Gregor Hohpe (Google) and Martin Fowler (ThoughtWorks), and chaired by Ted, was packed out. If I can sum up the prevailing theme in four words, then it&apos;s &quot;Complexity Bad. Pragmatism Good&quot;. Stacks, technologies or even architectures that try to do everything are out; in their place pragmatic approaches, based on proven, readily available tools, are preferred. For example: 
	
	* There seems to be low interest in JEE and EJB3 - many are choosing to use Spring instead as a Java container. Developers, architects and their managers are voting with their downloads and using tools like Tomcat, Spring, Hibernate and a host of other staple open source frameworks to get the job done.

	* There is serious disillusionment around WS-*. Martin Fowler refers to the extended suite of Web Services specifications antagonistically as &quot;WS Death Star&quot;, raising questions about the validity and veracity of specs that are barely-implemented and infrequently used. For example: is WS-Transactions really necessary? Distributed transactions are hard enough as it is, why should doing it with web services make it any better?  What about WS-Reliable Messaging? There are lots of applications out there where sending SOAP or XML over JMS is more than enough already: no WS-RM required! I&apos;m a pragmatist at heart, and much of this kind of thought really does resonate with me, Still, I&apos;m not keen to throw the baby out with the bath water: there&apos;s some good stuff in WS-*. I found myself musing at the conference about what a a tragedy it would be if we as an industry decide to bin WS-* and start all over again, only to run into the same problems (again) a few years down the line. Hmmm. Let me be clearer: if you&apos;re going to mock WS-*, then earn the right to do so first by suggesting a viable alternative.

	* There are clear signs SOA fatigue in the community; to the point where people really don&apos;t care about the term any more. When the panel was asked &quot;what is a service anyway?&quot;, they laughed nervously and tried to evade the question with nebulous answers. Ted probed further &quot;Is a database a service?&quot; (I actually do know the answer to that one …): when faced with the panel&apos;s answer &quot;it depends&quot;, you&apos;re left thinking that if a service is all things to all people, then it&apos;s really not that meaningful a concept at all. But enough of this pedantry: the important thing is the unanimous agreement that it&apos;s more important to Use the Right Architectural Approach: be it REST, EDA, SEDA, SOA or whatever, than to apply the same architectural solution all the time. This plays perfectly to the strengths of ServiceMix, CXF, ActiveMQ and Camel: by supporting Enterprise Integration Patterns in general, these tools can be used to implement all these architectures.
	
	* Even Java is getting something of a grilling when it comes to complexity. As a general purpose language, you can do whatever you like with Java; however, you sometimes end up having to write lots of code to provide additional support for design patterns used in your solution. Some modern scripting languages, for example Ruby, provide language features that innately support common patterns, resulting in less code. As a case in point, consider RabbitMQ, a fully fledged AMQP broker, written in less than 8000 lines of Erlang. I can&apos;t see Java disappearing any time soon, but I can see growth in alternative languages.  It’s worth noting here that Camel itself provides a &quot;Java DSL (Domain Specific Language&quot;; by providing a language that innately supports numerous enterprise integration patterns, you can implement these patterns with much less code.	
	
Google played a large role at the conference; I really enjoyed their presentation on GWT (Google Web Toolkit). Here&apos;s the GWT pitch: AJAX programmers today end up writing pretty complex code, typically relying on lots of cutting and pasting of existing examples in order to design their page. GWT allows you to design your browser-based GUI in Java using the GWT API; GWT tools then automatically converts your Java to appropriate JavaScript for your pages. You end up with a rich, compact, fast-download, JavaScript UI. This is very neat and I&apos;ve enjoyed playing with it. One big implication of GWT is that if its successful then there&apos;s going to be a lot more JavaScript clients there. I&apos;ve made the mistake in the past to assume that in a WS world, everything&apos;s a Java/C++ or .Net client: however, with lots of GWT client applications now in the offing, there will be a greater demand for RESTful services that return either JSON or raw XML. I&apos;m glad that CXF is ahead of the curve here in its support for implementing these services.

And finally: the really, really interesting stuff at TSSJS has got to be the stuff people are doing with JavaSpaces. I&apos;ve only flirted with it myself, but I&apos;m fascinated at the ability to easily construct scalable, dynamic Grid applications using spaces. I&apos;d like to put together a nice demo with John Davies (if I get the time) showing how to build a nice compute service. At the front end there&apos;ll be a nice, well behaved REST/WS interface. At the back? Well you won&apos;t have to worry about that: spaces will make it fly along.
</description>
         <link>http://blogs.iona.com/sos/2007/07/hola_barcelona_tales_from_the.html</link>
         <guid>http://blogs.iona.com/sos/2007/07/hola_barcelona_tales_from_the.html</guid>
        
        
         <pubDate>Fri, 06 Jul 2007 11:49:47 +0100</pubDate>
      </item>
            <item>
         <title>SOA - its not just for Christmas</title>
         <description><![CDATA[Just back from some great days in Stockholm, at a SOA conference there. Great event, great people - at the end of the event the organisers asked me to prepare an executive summary, which I'm attaching inline below. In a nutshell: SOA is maturing nicely, but EDA and REST have a big part to play in SOA solutions. 

<hr/>

The "SOA for the Services Industry" conference took place this year in Stockholm, bringing together battle-hardened SOA practitioners, industry visionaries and solution providers, under the banner theme "Beyond the Introduction: Managing SOA for a Decade". The event lived up to its promise of bringing to bear the idealism and purity of the SOA architectural vision with on-the-ground experience and real-life use-cases.  IONA Technologies was delighted to sponsor and chair this event.

A recurring theme that emerged throughout the presentations, panel discussion and conversations throughout the event was that "SOA is just part of the solution". Many of the case studies, drawn from the airline, financial services and telecom industries, showed that while a SOA-based architecture formed the backbone of their thinking, Event Driven Architecture (EDA) also formed a key role. One delegate captured this succinctly, saying "our business is event-driven ". Gartner's proposal for a "SOA 2.0", which emerged mid-last year amidst much debate and mixed acceptance, declares EDA to be a key differentiator from its predecessor; however, some delegates felt that EDA is already a de facto part of existing SOA solutions. Case studies showed also that the principals behind REST architecture, as defined in Roy Fielding's thesis, are also immensely important in designing distributed scalable systems.

Delegates found some agreement on the idea that SOA does not always have to be an enterprise endeavor - the principals and technologies behind SOA can be applied at an application or project level to good benefit. In fact, one delegate was keen to point out that the feudal nature of his organization meant that any attempt to impose an enterprise-wide methodology was simply doomed to fail for political reasons alone. By applying SOA principals in the small there was a greater change of building a groundswell and ultimate acceptance. Applying all elements of SOA architecture, from services creation and deployment right through to orchestration and choreography, just "for the sake of it", is clearly misguided; one delegate went as far as to say "It's almost better to have no SOA at all, than a badly done SOA".

The use of SOA as a business facilitator, supporting and easing mergers, acquisitions and outsourcing programmes was demonstrated in a number of presentations in the telecoms and airline sectors. The importance of governance and organizational training in achieving SOA success was also stressed. All were agreed that SOA is perhaps now far more a people problem than a technical problem: aligning an organization to understand and capitalize on SOA, or rather, aligning a SOA to facilitate and support an organization’s DNA, may be the greatest challenge. 

And, in the long term, remember that a SOA is "not just for Christmas": SOA practitioners must consider the cost of ongoing deployment, evolution and maintenance of SOA systems. Planning for success requires strategic thinking around version control, ownership and scaling is crucial for success in the long term. 

The event was organized by Inoventa; for more information on the event, and to download conference materials, go to http://www.inoventa.com/


]]></description>
         <link>http://blogs.iona.com/sos/2007/05/soa_its_not_just_for_christmas.html</link>
         <guid>http://blogs.iona.com/sos/2007/05/soa_its_not_just_for_christmas.html</guid>
        
        
         <pubDate>Thu, 17 May 2007 18:35:41 +0100</pubDate>
      </item>
            <item>
         <title>Design for Success: Best Practices for WSDL Versioning</title>
         <description><![CDATA[Consider this: if you're designing a service right now, there's a chance that you want this service to be successful, and reused in production for a long while to come. With success (and reuse) comes evolutionary change to the WSDL contract: new users will typically demand more functionality, or use your service in ways you didn't originally anticipate. You need to be able to cater for this change, allowing your contract to be improved over time without breaking existing service consumers. 

I've put together some thoughts on how to support minor and major releases of WSDL contracts, where a "minor" point release of the contract maintains on-the-wire compatibility with existing service consumers. The technique involves a scheme for embedding major- and minor-version information in WSDL namespaces; the approach is described in more detail in the attached PDF paper. 

Would be interested to hear if anyone out there has some improvements on the scheme, or alternatively, has a more elegant approach to the problem of WSDL versioning? In the meantime, if you're designing for success, then do think about versioning - the sooner the better.

<a href="http://blogs.iona.com/sos/20070410-WSDL-Versioning-Best-Practise.pdf">Download PDF Paper on WSDL Versioning</a>
]]></description>
         <link>http://blogs.iona.com/sos/2007/04/design_for_success_best_practi.html</link>
         <guid>http://blogs.iona.com/sos/2007/04/design_for_success_best_practi.html</guid>
        
        
         <pubDate>Tue, 24 Apr 2007 20:02:25 +0100</pubDate>
      </item>
            <item>
         <title>QCon London, Celtix Enterprise and AMQP</title>
         <description><![CDATA[I got to go to QCon in London this year, and decided to put together something challenging for my presentation. I'd been playing with Unified Business Language (UBL 2.0), and posed the question: how easy would it be to build a Celtix Enterpise server that can accept a UBL invoice in a variety of formats (XML, SOAP, JSON) over a number of transports (AMQP, JMS and HTTP)? 

Finding the answer turned out to be a lot of fun: Using Eclipse, WTP and Celtix Enterprise I quickly got a WSDL contract together for the service, along with bindings for XML and SOAP payloads. After that, implementation was straightforward JAX-WS - all the details are provided in my slideware, which I'm attaching to this blog. Using JSON was a little tricky, but thanks to some help from Dan Diephouse (Thanks Dan!) I used the Jettison STAX implementation with an XML binding to produce both Badgerfish and mapped JSON. It's a pragmatic approach, but I'd prefer it if there was a bona-fide JSON binding for WSDL that handles these detail, taking JSON support out of the code and into the contract. Maybe that's something we should get into the Apache CXF roadmap?

While it's always great to put a lovely demo together and have it work on the day, its doubly rewarding to see how relevant this stuff is: AMQP is a hot topic right now and the ability to simply configure AMQP in to a pure-Java JAX-WS client or service is really nice. Also, as Sailesh Panchal of Travelex was keen to point out in his presentation, the ability to support XML and SOAP payloads over multiple transports is hugely important in terms of producing really reusable services, supporting both REST and SOA architectures. 

Next up? I'd like to push my demo a little further to get some performance stats over different payload and protocol combinations: I've heard talk that JSON parsing can be up to 100x faster than XML parsing: let's see if that really holds true. Also, I'm keen to test the fundamental premise of AMQP: on-the-wire interoperability between different messaging middlewares. Right now my client, service and broker are all Apache QPID, the AMQP implementation that comes bundled in Celtix enterprise. I'd like to see what happens if when I swap the qpid broker with open-amqp or RabbitMQ... watch this space for more...

<a href="http://blogs.iona.com/sos/IONA-Multi-protocol%20open-source%20web%20services%20with%20JAXWS%20and%20Celtix-QCon-2007.pdf">Download Ade's slideset</a>]]></description>
         <link>http://blogs.iona.com/sos/2007/03/qcon_london_celtix_enterprise_1.html</link>
         <guid>http://blogs.iona.com/sos/2007/03/qcon_london_celtix_enterprise_1.html</guid>
        
        
         <pubDate>Tue, 20 Mar 2007 21:35:17 +0100</pubDate>
      </item>
            <item>
         <title>Micro-orchestration: using the Celtix Router as an application container</title>
         <description>Usually when I think of JAX-WS application development I like to think in terms of the classic contract-first development model: generate your stubs from the WSDL file using wsdl2java, then implement your endpoint in Java. The endpoint can then be deployed from a standalone server mainline, or any of the containers supported by Celtix such as ServiceMix (JBI) or Spring. I was happily surprised recently when an inventive customer recently suggested an interesting alternative. They proposed the following (non-obvious) development scenario: why not design your application as a route and deploy in the Celtix router?

The idea is beautiful in its simplicity: write your application logic as a set of Plain Old Java Objects (POJOs), and then use the Celtix Router (based on the Mule container) to string them all together. At the start of the route, deploy a Celtix listener, based on a formal WSDL contract: the router can listen for requests, unmarshall incoming data to Java objects (using JAX-B), and then forward these objects to your business logic. The router will let you chain a whole set of POJOs, allowing you to design your application as a pipeline of modular and reusable POJO-based business components. And, at the end of the chain, you can let Celtix consume the POJO results and marshal them back onto the wire, either as a synchronous response to the original invocation, or onward to another remote service in an asynchronous application.

I worked with the customer to put together a POC, and we&apos;re building on this POC towards a production-ready deployment. 

Ultimately, this approach allows you to design applications as mini orchestrations, providing the flexibility of an orchestration engine without the penalty of remote message invocations between each component. I like it.</description>
         <link>http://blogs.iona.com/sos/2007/02/microorchestration_using_the_c.html</link>
         <guid>http://blogs.iona.com/sos/2007/02/microorchestration_using_the_c.html</guid>
        
        
         <pubDate>Tue, 27 Feb 2007 21:42:46 +0100</pubDate>
      </item>
            <item>
         <title>Rapid SOA service test and simulation with Artix</title>
         <description><![CDATA[In any production distributed system, testing is crucial: services don't make it into the production environment unless they've passed rigorous tests in unit, system, and user-acceptance environments. Running services in non-production environments is typically easy if you have all the deployment artifacts close to hand, and a bed of appropriate sample data to fuel testing - generally, in any solid development environment, this is going to be the case.

Many services, however, do not live in isolation: the implementation of their business logic may require other services further down-stream. So, in order to test your service, you've got to deploy the down-stream services as well. Sometimes, however, you don't have access to the back-end service deployment artifacts, so you can't deploy an instance of this service in your test environment.

I worked recently with a customer who had exactly this problem: their system depended on a third-party service for which no test environment was readily available. As a result, they could not test their own service in a timely fashion; instead, they had to negotiate a "testing window" with the third-party, and run all their tests within this testing window. The delays in making these test windows available were seriously impacting this customers ability to roll-out new releases of their product, holding up their design, test and development process.

So - how does Artix solve this problem? Using Artix it's possible to rapidly build and deploy a service simulator (or "stub") that can be deployed in a test environment, allowing you to continue with the testing of your core systems. Using Artix allows you to pursue a number of different "Service Simulation" strategies: 

<ul>
<li><strong>Randomized Service Simulator.</strong>Using Artix's code generation tooling, a service implementation can be generated, compiled and deployed in minutes that generates randomized responses to incoming requests. This is a great way to ensure that connectivity between your software and the stub is being exercised, and can assist in performance and stability testing. One draw back of this approach is that, if your own system performs data validation, then the random values returned may be inappropriate.
</li>

<li><strong>Black-box Service Simulator.</strong>Using the Artix "Universal Test Harness" framework, you can define a set of pre-canned responses, providing rules on when each response should be used. For example, if a <code>valdateCreditCardNo()</code> operation arrives with a well-known test string such as <code>"1234-1234-1234-1234"</code>, then return a response that indicates a successful validation.

Black-box stubs can be built in a matter of hours, and are suitable for stateless services where all the information required to return a valid response is present in the incoming message. The approach is called "black-box" because it treates the service as a black box and does not attempt to simulate internal business logic of the service.
</li>
 
<li><strong>White-box Service Simulator.</strong> There are times when black-box approaches (outlined above) are not rich enough to simulate the required behaviour. For example, consider an interaction where a test client invokes <code>getCustomerDetails(String id)</code>,<code>  updateCustomerDetails(String id, Details d)</code> and then <code>getCustomerDetails(String id)</code>. A typical client-side test would expect that the second call to <code>getCustomerDetails()</code> would return a different response from the original call, where the customer's details have been updated accordingly. 
 
Recall that the black-box approach is good for simulation of stateless services; here, the service is stateful: it must rememember the customer's details across different invocations. This use-case requires white-box simulation, where code is implementated that simulates some of the service's internal business logic. Artix provide a set of productivity tools, through its tight integration with Eclipse, that allow such services to be rapidly constructed within a day or two.  
</li> 
 
The simulation approach you should use is goind to depend on the semantics of the service, and the kind behaviour you want to simulate. ]]></description>
         <link>http://blogs.iona.com/sos/2007/02/rapid_soa_service_test_and_sim.html</link>
         <guid>http://blogs.iona.com/sos/2007/02/rapid_soa_service_test_and_sim.html</guid>
        
        
         <pubDate>Thu, 08 Feb 2007 08:37:00 +0100</pubDate>
      </item>
            <item>
         <title>Getting people started with Web Services</title>
         <description><![CDATA[One of my responsibilities as Principal Consultant in IONA Technologies is developing training material for our Web Services offerings - some time ago we realised that the best people to write training material are people who are using the products day-in, day-out on customer sites on real customer projects. Given my previous existance as a lecturer in <a href="http://www.nuim.ie">National University of Ireland, Maynooth</a> I was keen to lend my efforts to our training program.

So - what should a basic web services training course contain? When I started contributing to our Celtix, Artix and Axis developer-training material I took a really pragmatic approach: what does a developer need to know to be effective after a 3 or 4 day course? Here's some guiding principles I came up with - if you're teaching yourself web services, or even writing your own training material, then you might use these principals to focus your activities. 

<ul>

<li><strong>Understand WSDL and XSD.</strong> You can't design web services without an understanding of WSDL and XML Schema. Believe me, I've tried; even when you adopt a "code-first" approach you end up getting dogged down if you don't understand the fundamentals. Any web services course worth its salt should teach XML schema, show to use WSDL for RPC (both in RPC style and Wrapped-doc-literal), and show how to use WSDL for document-style message. 
</li>

<li><strong>Start Simple.</strong> There's nothing like "Hello, World!" to demonstrate the absolute bare minimum of a web services application: how to write a client, create a proxy to a service, invoke, recieve on the far end, and implement back-end code. I'm a big fan of getting the "bread-and-butter" right; if I know that students understand "Hello, World!" then we can move swiftly on to the more advanced material that's so much more rewarding.
</li>

<li><strong>Build a Real Service.</strong> While there is nothing quite like "Hello, World" to get the basics right, students need to build something more complex to flex their new web services muscles. In my training courses I build a web service for receiving a sufficiently complex data structure (an Invoice). I find it pushes understanding of both XML and the mappings to the designated programming language.
</li>

<li><strong>Teach Best Practise from the Start.</strong> This may sound obvious, but so often I've come across software exercises, code samples and WSDL/XSD contracts that make me cringe. If you're going to give an example, then give a good example, and make sure if conforms to accepted best practise. If, on the first formal introduction to a subject, students are submitted to sloppy work, they may inject this sloppiness into their own work. Remember, they may not know any better, but you as an instructor should.
</li>

<li><strong>Teach the Development Environment.</strong> At some point students will go back to their day jobs and build and implement their own services. If they're going to do this then they've got to fully understand the development environment; this includes environment variables, third-party tooling, kit installation, and build/make systems. Don't try to to hide these details by providing a sandbox  environment where everying has been set up under the covers: engage your students in setting up and configuring their own environment correctly.
</li>

<li><strong>Teach Students to Help Themselves.</strong> There's only so much you can cover in a course; eventually students are going to encounter some problem after the course and will get stuck. It's important to teach techniques to get them unstuck, for example, how to configure and turn up logging, or view messages on the wire. And on that point, when it comes to configuration, make sure they know the fundamentals of configuring the web services toolkit, and then where to go for more information. The last thing any student wants is a lengthy, yawning, shopping list of configuration variables - leave that to documentation.
</li>

<li><strong>Teach Security.</strong> I like to think that any service worth its salt needs some element of security, even if just at the level of secure transport, like HTTPS, and simple username/password authentication schemes via HTTP Basic Authentication or Web Services Security Extensions (WSSE). Implementing a service with a straightforward username-password authentication scheme is fun, and it can spark off discussion about more complex security considerations.
</li>

</ul>

We've put these principals to the test in our Artix and Celtix and Web Services Bootcamp standard material, and our student feedback has been terrific. When students get this fundamental material, they're ready to devour more advanced web services topics, like reliable messaging, transactions, routing, replication and session-managment strategies. Most importantly, though, with the basics in place, they're ready to get to work designing, building and deploying web services.]]></description>
         <link>http://blogs.iona.com/sos/2007/02/getting_people_started_with_we.html</link>
         <guid>http://blogs.iona.com/sos/2007/02/getting_people_started_with_we.html</guid>
        
        
         <pubDate>Thu, 01 Feb 2007 15:18:27 +0100</pubDate>
      </item>
            <item>
         <title>Porting JAX-WS applications across web services toolkits</title>
         <description><![CDATA[One of the proposed benefits of a specification like JAX-WS or JAX-RPC is that you can easily move your application code from an existing web-services toolkit to another - the specification-compliant APIs used in one toolkit should be compatible with those of another toolkit. 

I recently put this idea to the test when I migrated a load of ObjectWeb Celtix application code to CXF. For those that don't know, Celtix, the open source ESB that originally resided at ObjectWeb, moved to Apache last year, merging with the XFire project to become CXF. CXF has an substantially different runtime to ObjectWeb Celtix, and can be considered an entirely different toolkit.

By the way, IONA's "Celtix Enterprise" product contains CXF as its JAX-WS core runtime. Just for clarity, I use the terms "Objectweb Celtix" and "Celtix Enterprise" instead of "Celtix" on its own, to distinguish between the original ObjectWeb project and the IONA offering based on CXF.

So - how did I get on? The porting turned out to be much easier than I thought: JAX-WS does have its advantages. As you'd expect, however, my porting effort was not uneventful. Here are some areas to look out for if you're attempting something similar.

<strong>Packaging, building and environment</strong>

The development environment changed (slightly) from ObjectWeb Celtix to CXF; for example, instead of a <code>CELTIX_HOME</code> environment variable you should set <code>CXF_HOME</code>. Also, an obvious difference is that the classpath has changed significantly: you need to modify your Ant files so that the new JARs are picked up. 

Some other not-so-obvious issues arise: I went looking for some XML Schema definitions for configuration beans in CXF and couldn't find them under  the CXF installation directory; it turns out that these schema are all held in a JAR file in the CXF distribution.

<strong>Toolkit specific APIs</strong>

While the JAX-WS specification covers the bulk of the APIs for implementing your service and creating an endpoint, every toolkit typically supplies its own APIs to do additional things such as configuration, registration of handlers, etc. ObjectWeb Celtix had the concept of a Bus, implemented by the class <code>org.objectweb.Celtix.Bus</code>. CXF also has a Bus concept; however, the CXF Bus is is located in a different class (<code>org.apache.cxf.Bus</code>) and has a different API for instance creation. 

If your application relies heavily on toolkit-specific APIs then you will have to take this into account when you being a porting or migration activity

<strong>Implementation glitches</strong>

I was surprised to find some implementation differences on the interpretation of the specification. Thankfully, these were small and easily fixed; however, the experience has pointed out that there's no substitute for testing. 

For example, if you call the JAX-WS <code>getPort()</code> API on a client side service object then, in CXF, you must specify the target namespace of the WSDL contract as the namespace of the port name, like this:

<pre>
HelloWorld helloWorld = helloWorldService.getPort(
    new QName("http://www.my/wsdl/target/namespace",     
    "SOAPOverHTTPEndpoint"),
    HelloWorld.class );
</pre>

In Celtix you could leave the namespace of the port name as an empty string "". If you do this in CXF then the call to <code>getPort()</code>  will fail. It turns out that this latter behaviour (in CXF) is more in keeping with the JAX-WS specification (see Section 4.2.3 of the JAX-WS Specification).

Based on my experience, I put some notes on the "Celtix Migration Page" in the <a href="http://cwiki.apache.org/CXF20DOC/celtix-migration-guide.html"> CXF user guide</a>. If I come up with any other migration issues then I'll submit them there to keep them in the one place.]]></description>
         <link>http://blogs.iona.com/sos/2007/02/porting_jaxws_applications_acr_1.html</link>
         <guid>http://blogs.iona.com/sos/2007/02/porting_jaxws_applications_acr_1.html</guid>
        
        
         <pubDate>Thu, 01 Feb 2007 14:54:53 +0100</pubDate>
      </item>
            <item>
         <title>just starting with CXF (celtixfire)</title>
         <description><![CDATA[The <a href="http://incubator.apache.org/projects/cxf.html">Apache CeltiXFire</a> project has just recently been renamed to CXF.  Which is much more userfriendly for the mouth at any rate, (Celtixfire is a bit of tongue twister).

I am only a newbie and only getting started on it now.  I successfully imported the project into Eclipse thanks to Dan Kulp's <a href="http://cwiki.apache.org/confluence/display/CXF/Setting+up+Eclipse">explanation</a>.

The only problem Ive come across so far was when building the project (out in the command line) using Maven 2.0.4 my <CXF_install_dir>/trunk/distribution/target directory was not being created.  "mvn install" needs to be run in the trunk and distribution directory, however I found running "mvn -e install" more useful for error output.  Maven runs fine from the distribution directory (<CXF_install_dir>/trunk/distribution) directory but from the trunk directory (<CXF_install_dir>/trunk) it generated a build error.

java.lang.NoClassDefFoundError: org/apache/cxf/configuration/CommandlineConfiguration
        at java.lang.Class.getDeclaredMethods0(Native Method)


It seemed this was caused by out-of-date binaries. To make sure you update these, use "mvn clean install" instead of just "mvn install".  If clean fails (which it did for me!), delete the */target directories manually.  Clean out the local repository, i.e. remove the org.apache.cxf directory in c:\Documents and Settings\<your username>\.m2\repository. Then run "mvn -e install".

After this my build worked and the <CXF_install_dir>/trunk/distribution/target directory was created.

The project is now complete with distribution jars and demos <CXF_install_dir>\distribution\src\main\release\samples and up and running in Eclipse.  ]]></description>
         <link>http://blogs.iona.com/sos/2006/10/just_starting_with_cxf_celtixf.html</link>
         <guid>http://blogs.iona.com/sos/2006/10/just_starting_with_cxf_celtixf.html</guid>
        
        
         <pubDate>Thu, 19 Oct 2006 20:27:53 +0100</pubDate>
      </item>
            <item>
         <title>EJB 3.0 and JBossWS</title>
         <description><![CDATA[Ive spent a few days playing around with EJB 3.0 and JBoss WebServices.  After JBoss was J2EE-1.4 certified they decided to develop their own SOAP stack independent of Apache Axis. This implementation is JBoss 4.04GA.  Here I explain how to set up a working example of JBossWS in Eclipse. I also highly recommend you download Eclipse 3.2 and WTP 1.5, which contains better WSDL and XML editors and a better J2EE view for launching and managing your JBoss Server.

<ul>
<li>Download the latest version of the <a href="http://labs.jboss.com/portal/jbossas/download/index.html">JBoss Application Server 4.04</a>.  Usually when I install a JBoss AS I download a zip file and unzip it in my JBoss_Home  folder however to correctly configure the JBoss WebServices components it is necessary to  <strong>to run the JBoss AS 4.04 GA Installer</strong>.  The "Run Installer" option is the last one on the right hand side. Using the former approach causes configuration nightmares later on.</li>

<li>You are given a list of installation options (some of which are; "all"- full J2EE 1.4 server with enterprise extensions, "default" - base J2EE 1.4 server profile, "ejb3" - An ejb3 profile supporting the full ejb3 spec with tomcat).  For the purpose of JBoss WebServices developement it is only necessary to chose "ejb3".
</li>

<li>After finishing the installation you have successfully installed JBoss AS 4.04 and JBossWS 1.0.0 GA. However there a relatively critical bug found in JBossWS 1.0.0 where the application continously resolves an external URL meaning that deployed WebServices behind a firewall or offline wont work.  To this end the next step is to install the latest <a href="http://labs.jboss.com/portal/jbossws/downloads">JBossWS 1.02 GA</a></li>

<li>After downloading the zip file, no installer this time, unzip JBossWS to it's JBossWS_home directory. Its not necessary to install it in the JBoss AS 4.04 directory. One thing to take note of however, in the zip file there is no root directory so you need to create a dedicated JBossWS directory otherwise it gets very messy.</li>

<li>Open <JBossWS_Home>\Install.txt and follow the directions.</li>

<li>The first line reads: "Copy lib/jbossws-client.jar to <JBOSS_HOME>/client/" but should read: "Copy lib/jboss-jdk1.5/jbossws-client.jar to <JBOSS_HOME>/client/" </li>

<li>Dont forget to download the latest <a href="	http://repository.jboss.com/jboss/jbossxb/1.0.0.CR6/">jboss-xml-binding.jar</a> as explained in point 3</li>

<li>Unzip <JBossWS_Home>\jbossws-samples-1.0.2.GA.zip to your eclipse work space. This approach is better than the eclipse import approach as it means you are not overwriting the original directory.</li>

<li>Now start your Eclipse IDE and select the eclipse workspace (where you extract the JBossWS samples directory)</li>

<li>From the menu option "File" chose "new java project", in the "Create a Java Project" wizard, choose "Create new project in workspace", insert the exact name of the folder that you extracted into your workspace (jbossws-samples-1.0.2.GA).  It is always good practice in the "Create a Java Project" wizard to select the last radio button under "project layout" - "create separate source and output folders".  You will now see a message at the bottom of the wizard "The specified location already exists...". Click next and Eclipse will create a JBossWS project</li>

<li>Open your project in navigator. Rename ant.properties.example to ant.properties, it is defined like this in the build file imported-build.xml found under the "common" direcory. This file is imported in the build.xml</li>

<li>In ant.properties update the variable jboss.jdk15.home with your JBoss AS 4.04 GA directory. The other variables do need to be adjusted (assuming you are using the default container)</li>

<li>Run the clean task</li>

<li>In the Navigator or Package view the EJB3 Bean code can be seen in the JSR181 directory.  Here we have the bean code (EJB3Bean01.java), the Remote Interface (EJB3RemoteInterface.java) and an interface used by client deployment (EndpointInterface.java)</li>

<li>Note we have no Home Interface as we would have had in J2EE 2.1.  A remote client finds relevant bean using the remote business Interface.  From the specification section 3.2.1:<em> In EJB 3.0, a remote client accesses a session bean through the bean’s remote business interface. For a session bean client and component written to the EJB 2.1 and earlier APIs, the remote client accesses  the session bean through the session bean’s remote home and remote component interfaces. Compatibility Note: The EJB 2.1 and earlier API required that a remote client access the session bean by means of the session bean’s remote home and remote component interfaces. These interfaces remain available for use with EJB 3.0</em>  Therefore we no longer have the factory pattern of J2EE 2.1 where we use a home interface to create a remote interface, rather we have a handle on the remote interface from the outset. This is much more similiar to what CORBA and Java programmers have been traditionally used to.</li>

<li>Also note that the bean type is now defined by an annotation, for example in EJB3Bean01.java we have defined "@Stateless" which is a standard JSR 181 annotation now used in EJB 3.0</li>

<li>As well as other JSR 181 Annotations we also have JBoss specific annotations; @RemoteBinding, @PortComponent, @SecurityDomain, @HandlerChain </li>

<li>The following libraries are required on the classpath to get the project to build, from <JBoss_Home>/client directory jbossall-client.jar, jboss-jaxrpc.jar, jbossws-client.jar, jboss-ejb3x.jar</li>

<li>Build the project by running the main task in build.xml.  If you view the project outside of eclipse in Internet Explorer you will see this genereated the output directory containing amongst others the lib folder.  In the lib folder an *.ejb3 file is generated.  This is the deployable ejb bean.  Both *.ejb3 or *.jar extensions can be used in EJB 3.0.  Deploy the bean in the JBoss/Server/default/deploy directory</li>

<li>Go to http://localhost:8080/jbossws to view a list of deployed services.  */jbossws-samples-jsr181ejb/EJB3Bean01?wsdl will be listed as a deployed service.  If you click on the service you'll be prompted for a username and password.</li>

<li>The authentication requirements are now defined by JBoss specific annotations in the bean code. (Previously this was done by config in JBoss). The (JSR181 annotaion) @RolesAllowed defines the role "friend". The annotation @SecurityDomain defines the security domain as JBossWS.  In the login-config.xml we can see that jbossws-user.properties defined as the user.properties file which contains the username/password kermit/thefrog</li>

<li>Submit the username and password on the webclient to view a generated WSDL that represents the JBoss WebService Bean.</li>

<li>As a further step, its useful to take the generated WSDL above and create a simple client (in my example I used Axis). </li>

<li>Taking the generated WSDL as is and running WSDL2Java to generate the client causes some problems as the WSDL is missing necessary definitions, in the JBoss example the following had to be added to the generated WSDL:  
<em><definitions name="TestService"
	targetNamespace="http://org.jboss.ws/samples/jsr181ejb"
    xmlns="http://schemas.xmlsoap.org/wsdl/" 
    xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" 
    xmlns:tns="http://org.jboss.ws/samples/jsr181ejb"
    xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" 
    xmlns:xsd="http://www.w3.org/2001/XMLSchema">
</li>
</em>

<li>After creating the client it is also necessary to add the username and password properties:
                   <em>endpt_i = (EndpointInterface) locator.getPort(
					new QName("", "EndpointInterfacePort"), 
					EndpointInterface.class
				); 
				
		((Stub)endpt_i)._setProperty(Stub.ENDPOINT_ADDRESS_PROPERTY, 
                                                                                                              endpointUrl); 
		((Stub)endpt_i)._setProperty(Stub.USERNAME_PROPERTY, "kermit");
		((Stub)endpt_i)._setProperty(Stub.PASSWORD_PROPERTY, "thefrog");
</li>
</ul>
</em>

The above 2 projects (The Jboss sample and Axis Client) I can make available to anyone who is interested.  

Now Im off to configure Apache CeltiXfire!]]></description>
         <link>http://blogs.iona.com/sos/2006/08/ejb_30_and_jbossws.html</link>
         <guid>http://blogs.iona.com/sos/2006/08/ejb_30_and_jbossws.html</guid>
        
        
         <pubDate>Fri, 25 Aug 2006 15:10:49 +0100</pubDate>
      </item>
            <item>
         <title>CeltiXfire</title>
         <description><![CDATA[The Celtix project from ObjectWeb and the XFire project from Codehaus are merging in the apache incubator to form CeltiXfire.

You can subscribe to the mailing list or download sourcecode from <a href="http://cwiki.apache.org/confluence/display/CXF/CeltiXfire+Welcome+Page">here</a>.

We'll keep you posted on how we get on with this new project!

Margo.]]></description>
         <link>http://blogs.iona.com/sos/2006/08/celtixfire.html</link>
         <guid>http://blogs.iona.com/sos/2006/08/celtixfire.html</guid>
        
        
         <pubDate>Fri, 25 Aug 2006 14:38:32 +0100</pubDate>
      </item>
            <item>
         <title>Integration in the retail industry</title>
         <description>Recently Margo and I have visited an ISV who produces software solutions for the retail industry. In one of the meetings I learned that retail is a business of low margins and extreme competition. This is specifically true for countries like Germany. As if I asked for an example of this claim I heard in the news that a very large US superstore chain would retreat from the german retail market in order to concentrate forces into markets where they can grow faster.

So when margins are low, prices cannot be raised, costs must be kept down. The software that these folks write is to harmonize the demand and supply in a way that customers would never stand in front of empty shelves while at the same time, the store&apos;s stock is never full. In the past, this optimisation was part of the staff&apos;s responsibility and based on vast experience, however with the variety of products these days and the dynamicity of the labour market it is impossible to build the keen sense for quick and slow selling items. Also, more and more stores are branches of a chain where smart logistics is to be applied. Smart software is required here to forecast demand.

One of the most complex parts of managing a supply chain is the integration of the various parties in this chain: stores, warehouses, manufacturers, shipping companies. To complicate things, goods and the corresponding data does not flow into one direction only. Flows are back and forth, e.g. if goods are returned due to quality problems.

For instance, one integration use case is when orders are sent from the store to the warehouse. Orders from all stores will be consolidated to create another order to the manufacturer. In some cases, the manufacturer&apos;s shipping company sends the goods directly to the store, in some cases these products are sent to the warehouse for redistribution.

Sounds like a big integration task!

Another example is the creation of orders. Orders are based on forecasts. Forecasts are based on existing sales data. The sales data needs to be transferred from the stores to a central location for calculating the forecast and the orders. The current solution that transfers sales data to the central server is based on a simple yet proprietary protocol. It works no problem. However their customers need to operate and support this proprietary protocol and have no real alternative. The ISV considers using an Enterprise Service Bus to open up the architecture of their product to use any protocol.

Now what does this have to do with Open Source?

The ISV has OEM licensed its product to a large SCM software company. The inclusion of commercial third-party products into their product &quot;could&quot; mean that existing contracts need to be renegotiated. Hence, this ISV envisages open source software as a strategy for creating value for customers, Partners and themselves without having to change business processes.

Another note I wanted to add is that, the described use case with the transfer of sales data is a challenging one for us and the Celtix product. The integration we&apos;re seeing here is not an integration of functionality, i.e. classical application integration. We&apos;re looking at integration of data sources and sinks. To my mind, there are many such integration problems out there. We&apos;ve just seen a tiny bit of it.
</description>
         <link>http://blogs.iona.com/sos/2006/08/integration_in_the_retail_indu_1.html</link>
         <guid>http://blogs.iona.com/sos/2006/08/integration_in_the_retail_indu_1.html</guid>
        
        
         <pubDate>Fri, 18 Aug 2006 17:23:31 +0100</pubDate>
      </item>
            <item>
         <title>Services in OpenSource</title>
         <description>Sending out an SOS...
 
...as Sting would say. We, along with some of our colleauges in the Services department, are starting this blog to capture thoughts, observations, wisdom and wit as we tackle Open Source and freeware technologies.  Having worked traditionally with licensed products we are coming across a myriad of new experiences in the dark murky waters of Open Source. Slowly but surely however we are learning the nuances and tricks of the OpenSource world.  We hope our experiences will be of interest to you.  Please feel free to comment, contribute or flame.</description>
         <link>http://blogs.iona.com/sos/2006/08/services_in_opensource.html</link>
         <guid>http://blogs.iona.com/sos/2006/08/services_in_opensource.html</guid>
        
        
         <pubDate>Thu, 17 Aug 2006 11:05:15 +0100</pubDate>
      </item>
      
   </channel>
</rss>
