This week's giveaway is in the EJB and other Java EE Technologies forum.
We're giving away four copies of EJB 3 in Action and have Debu Panda, Reza Rahman, Ryan Cuprak, and Michael Remijan on-line!
See this thread for details.
The moose likes Web Services and the fly likes cxf interceptor question Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Web Services
Bookmark "cxf interceptor question" Watch "cxf interceptor question" New topic

cxf interceptor question

Praful Thakare
Ranch Hand

Joined: Feb 10, 2001
Posts: 613

Is there a way to tell cxf to stop only user defined interceptors when is invoked?
I am in situation where it kills even the default interceptors like JAXRSOutInterceptor.

to give some background, I have to kill interceptors if one of the interceptor throws fault but still write something to response.
currently I am writing using ServletOutputStream taking from

but its not a good way as I cannot handle the ouput type (either xml or json).

Any Pointers?

All desirable things in life are either illegal, banned, expensive or married to someone else !!!
Praful Thakare
Ranch Hand

Joined: Feb 10, 2001
Posts: 613
finally with lot of debugging thru cxf code , found following way to do this....

This works only if you invoke the method programatically from Interceptor that will execute this code, do NOT throw fault from interceptor as it will always respond back with 500 error message.

hope it helps someone ...
Consider Paul's rocket mass heater.
subject: cxf interceptor question
Similar Threads
Confused with Built in Inerceptors in Struts2
Help need to exclude list of bean classes from interceptors
Create Session in Restful Service.
interceptor not working
Query rgd interceptor invocation order