0

I need to catch all SOAP request messages. The purpose of inspecting SOAP request messages is reading specific value (such as IP adress). I read this tutorial

http://www.mkyong.com/webservices/jax-ws/jax-ws-soap-handler-in-server-side/

But as far as I can understand, when I need to add handler on my project,

an annotation must be added like

@HandlerChain(file="handler-chain.xml")

And also handler-chain.xml must be implemented.

--

So, I'm going to implement a library to get all soap request IP adress and log them all. But if I use soap handler, I have to make some configuration on project that I added my library.

My purpose is creating Plug and Play library. If I add my library into a project, it must be start reading Ip adress from request message without making as above.

So, is it possible? How can I do it?

Eren
  • 632
  • 1
  • 8
  • 16

1 Answers1

0

No it is not possible. Think about this logically. If your service does not make any call, does not create any objects (i.e. does not reference it the library in any way) then no code from that library will be run and therefore it will not be able to do anything. Using the message handler is the most minimalistic and least intrusive way I have found (and it is the way I do it) do handle such problem.

Xargos
  • 633
  • 8
  • 19