Domanda

I have a CXF Rest Service and I am trying to create a logging mechanism that will log specific request and response details.

All the details I want to be written into a file in one write. As a result I am looking forward to create an Interceptor that will be invoked in the RECEIVE and in the SEND phase. Until now I haven't find any way to do it.

Is it possible to create an Interceptor registered in two phases of two different chains?

Thanks

È stato utile?

Soluzione

Just got an answer from the cxf-user mailing lists which is

It’s not possible to register the exact same interceptor object in two phases. You can register two separate interceptors of the same class on different phases, but not the same exact object. The phase needs to be set at construction time.

Daniel Kulp

So the answer is No.

link to post

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top