views:

98

answers:

1

I'd like to assign an unique identifier to a soap request as soon as it arrives at my (GlassFish 2) server. I suppose I use a handler for this.

But where can I store such an ID? I need it to relate log-lines from multiple classes. For this I need some sort of context-object. Anyone an idea?

+1  A: 

What you want is to open a session with the client (i.e. stateful SOAP instead of stateless). This blog post contains some answers.

And you have to pass the session ID to the client. Otherwise, you can't tell if a second request is coming from the same client or not.

Aaron Digulla
That's a solution I hadn't thought of. But I don't need to relate multiple requests, but just log-lines. I'll update my question accordingly.
doekman