This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
As far as I know we can set up web service with JAX-PRC or SAAJ. It seems that SAAJ is simpler than JAX-RPC for me, because it don't need to use WSDL. Is there any difference between them? How to choose between them? Please help! Thanks in advance!
I would consider JAX-RPC easier than SAAJ because JAX-RPC has a higher abstraction level. SAAJ is about constructing SOAP message by hand while JAX-RPC is closer to "pure" objects. I'm not quite sure why you're worried about having to use WSDL? The WSDL document is exactly what makes web services development a breeze -- because you can generate the client and service code automatically. Besides, if you use SAAJ, you'll need to examine the WSDL to figure out what kind of message the service expects to receive... I'd suggest using The Java Web Services Tutorial as a first step (you can probably skip most chapters as they're not directly related to web services).
Also, you do not have to write WSDL by hand. Using tools like Java2WSDL, you simply code a JAX-RPC Service Endpoint Interface (just a Java interface, that's all) and it will generate the WSDL for you... Because of this I'd consider JAX-RPC to be lightyears simpler than SAAJ... Kyle