This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Web Services Certification (SCDJWS/OCEJWSD) and the fly likes Handlers Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Certification » Web Services Certification (SCDJWS/OCEJWSD)
Bookmark "Handlers" Watch "Handlers" New topic


Roy Pozarelli
Ranch Hand

Joined: Oct 17, 2009
Posts: 39
In prepping for the certification I have the following question:
in javax.xml.rpc.handler.Handler you have handleRequest(MessageContext context) and handleResponse(MessageContext context)
in<C extends MessageContext> you have handleMessage(C context)

Now it seems to me that you have to use the MessageContext field MESSAGE_OUTBOUND_PROPERTY to make the distinction between in/out bound message direction vs. the "rpc" handler that had the container making that distinction, i.e. the logic was moved from the container to the implementor of the handler.

WHY was this done?

Is there another idea here in that the purpose of the handler should not care about direction? i.e. it should be performing the same behavior irrespective of the direction of the message?

OCP Java SE 6 Programmer,
OCM Java SE 6 Developer
OCE Web Components
MySQL Certified Administrator & Developer,
OMG Certified UML Prof. Fund., Int., Adv.
davide boleso
Ranch Hand

Joined: Jul 15, 2012
Posts: 39
Hello reading your question I noticed it's not clear to me wich specification are used for the exam
I was sure the exam was based on where you have only logicalHanderl and soapHandler
according to your question you are using that are organized differently
wich API are required for the exam ?

I agree. Here's the link:
subject: Handlers
Similar Threads
Request and Response handlers (Axis2)
Question about design of WS clients and their handlers
Question about message handlers and their interaction with a WS client
remove namespace from webservice response
JAX-RPC web service soap message handler issues