On May 5, 2008, at 4:45 AM, harbhanu wrote:
I want to know more about the specifics of different states in the
interceptor chain to which an interceptor can be attached.

I have tried looking at the documentation but IMO it doesn't discuss it in
depth.

According to the test that I did, the state transition is as follows
....snip.....

The phases are controlled by the PhaseManager in the Bus. If you look in the PhaseManagerImpl.java at:
https://svn.apache.org/repos/asf/cxf/trunk/rt/core/src/main/java/org/apache/cxf/phase

You can see the full list of phases that we have defined.

That said, you can easily configure new phases in there if you need some additional work you want done.


If possible, please let me know about the message transformation that takes
place.

Well, the interceptors themselves are the ones that do any transformation or processing. All of the CXF functionality is done via interceptors that live in the chain. Thus, any processing that goes on is specific to the interceptors that are put in place by the binding, the bus, the endpoint, etc..

Also, point me to any resource which discusses this in depth.

Couple more questions regarding interceptors:

How can I pass information between different layers of interceptors?

The Message object implements Map so you can store anything you want on the message itself.

Alternatively, if you need information across the message exchange (aka: you need information from the in interceptors to do some out processing), you can store stuff on the Exchange (which also implements Map) which is retrievable from the message.


How can I modify the execution of a particular message during the message flow since I don't see any context which can be modified for the same. ?

I guess I'd need more details about what you are trying to do. The Message contains a reference to the PhaseChain that is currently being executed. From your interceptor, you can completely modify the chain (for phases that have not yet run). You can add interceptors, delete them, etc...

I hope that helps!


Daniel Kulp
[EMAIL PROTECTED]
http://www.dankulp.com/blog

Reply via email to