Comparison Between Axis axis2 and cxf

Source: Internet
Author: User

Axis, Axis2 and CXF: Surveying the WS Landscape

By Bjorn Townsend

01 Sep 2007 | TheServerSide.com

  • Digg This
  • Stumble
  • Delicious

Download the open source tools & platforms eguide

Learn more about open source tools & platforms such:

  • What's new in spring 2.0?
  • Using hibernate & Tomcat
  • Struts action Mapping
  • Challenges in framework construction

It's an exciting time to be in open source web services development. two new next-generation web services frameworks have been released in the last year and a half, both under the umbrella of the Apache Software Foundation. these frameworks are Apache Axis2, which hit 1.0 at the end of each L, 2006 and is currently in the release candidate stage for version 1.3, and Apache CXF, which released version 2.0 (the first version released under that name) in early July 2007.

Both frameworks also evolved from existing projects. axis2 came from the well-known axis 1.x series. cxf is literally the offspring of the xfire and celtix projects, as those two projects have pooled their codebases and development teams to give rise to cxf. the delta between the old projects and their new versions is significant in each case. axis2 is a total rewrite of axis from the ground up, using a new modular architecture that allows its functionality to be more easily extended. cxf has also been extensively retooled from its xfire and celtix origins.

This leads to a few questions. shocould existing applications using Axis 1.x, XFire or Celtix move to the new versions of those projects? If a developer does decide to migrate his or her application to one of the new frameworks, which one shoshould they use? Conversely, if one is writing a new web service from the ground up and no migration is required, which one shold they use? Is one framework inherently better than the other?

Let's tackle these questions in order. Firstly, shocould existing applications migrate? The answer to that question depends largely on the point in its lifecycle your application has reached. A project which is very static and mature, with few or no changes expected in the foreseeable future, probably doesn't need to migrate as the current framework is serving its needs well enough. if the application's performance or functionality is impacted by bugs, it might be worth migrating, participant ularly for users of Axis 1.x, as most of the developer community around Axis has refocused its resources around Axis2. An Axis 1.5 release is in the works, but it may not happen for every months down the road.

As for which project to migrate to, it might be easiest to move to the next generation of your current framework. both axis2 and cxf provide migration guides that give developers tips on how to migrate from their previous versions, but as of this writing neither project has provided migration tools or guides for porting web services from one framework to another. in such a migration, though, it's always worth looking at all the options available. axis2 and cxf each take different approaches to Web service development, and these approaches will appeal more to some developers than others.

This brings us to a good point to compare axis2 and cxf on their own merits. they are of course in gateways comparable; of necessity web services frameworks must fill in all the same blks, but since both projects are very young, each has certain areas that are more well-developed than others. the chief differences are as follows:

  • CXF has support for WS-Addressing, WS-Policy, WS-RM, WS-Security, and WS-I BasicProfile. axis2 supports each of these partition t for WS-Policy, which will be supported in an upcoming version.
  • CXF was written with Spring in mind; Axis2 is not.
  • Axis2 supports a wider range of data bindings, including xmlbeans, jibx, jaxme and jaxbri as well as its own native data binding, ADB. note that support for jaxme and jaxbri are still considered experimental in axis2 1.2. cxf currently supports only jaxb and aegis; Support for xmlbeans, jibx and Castor will come in cxf 2.1.
  • Axis2 supports multiple extensions ages -- there is a C/C ++ version available in addition to the Java version.

In comparing these frameworks, though, it's just as important to look at their approach to developing web services as it is to compare features. from a developer perspective, both frameworks behave very differently from one another. axis2 has taken an approach that makes it in always ways resemble an application server in miniature. axis2 comes packaged with a WAR that can be deployed on a servlet container such as Tomcat that is designed to make web services easier to manage and deploy on the fly. the Axis2 Web Administration module allows Axis2 to be configured dynamically while applications are running -- new services can be uploaded, activated or deactivated and their parameters may be changed. the administration UI also allows modules to be enabled on one or more running services. the only downside to using the UI for these purposes is the fact that configuration changes made through it are not persistent -- they go away when the servlet container is restarted.

Axis2 lends itself towards Web services that stand alone, independent of other applications, and offers a wide variety of functionality, and a good model for adding more functionality as time goes on through its modular architecture. some developers may find that a little too cumbersome or heavy-duty for their needs. these developers might prefer to look at Apache cxf.

Cxf concentrates on developer ergonomics and embeddability. most configuration is done via the API instead of cumbersome XML files, spring integration is heavily emphasized, including support for spring 2.0, and cxf's APIs and spring configuration mirror one another fairly closely. cxf emphasizes code-first design, using simple APIs to make development of services from existing applications easier (and its embeddability helps too ).

Whichever framework you choose, you'll have the benefit of an active and stable open source community. each of these frameworks has effecate backing: axis2 is backed by wso2, and cxf by Iona. both have lively developer communities. axis2 has been around longer but cxf is catching up quickly. my recommendation is this: If multilanguage support is important, axis2 is the clear choice. if you care about an implementation focused on Java with tight integration into projects like spring, cxf is a better choice, special for embedding web services inside of other programs. if the new features in these projects are not important, and you're relatively happy with axis1, you shoshould consider staying on this and keep up with the latest maintenance releases until you have a business reason to migrate.

About the Author

Bjorn Townsend has spent the last two years working as an Open Source Engineer at SourceLabs Inc. his focus is on Java web services, networking and IT infrastructure. his is a frequent contributor to a number of Open Source projects.

 

 

Excerpt

Http://www.theserverside.com/news/1363958/Axis-Axis2-and-CXF-Surveying-the-WS-Landscape

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.