Webservices in Action, Axis2

Dennis Sosnoski

Axis2 can get new services or get modified on-the-fly.
Axis2 has more flexible processing and can say at which state a given process should run (ex. encryption/decryption).


Deployment
It now uses a .aar jar-file with a META-INF/services.xml to describe the services.

For databinding, XMLBeans is included, but other frameworks can be used.
(Not Castor though)

XMLBeans must be build up from the bottom and up, meaning that you have to create the lowest element first, and then add it to its parent. Once an element is added, it can’t be changed.

If you use Axis Data Binding (ADB):
  • Slower thant XMLBeans
  • Don’t support local types

Or use JIBX, which is Dennis’s own framework.
  • Data transfer classes stay the same
  • Use existing code on server.

If you develop webservices, it’s always good to use tcpmon to debug what’s actual transmitted over the wire.

Axis2 supports asynchronous communication with a so the reply may for example come back as an email.

WS-Security
Axis2 supports WS-security:
  • Signing
  • Encryption
  • X-509
  • And so on…

WS-ReliableMessaging
  • Acknowledgement of messages received
  • All the same issues as JMS

WS-AtomicTransaction
  • Two-phase commit.

Links
http://www.sosnoski.com