I\'m looking for an example, how to implement a longpoling mechanism in java. I would love to use a stateless EJB.
I know that something like that would work:
JAX-WS provides support for invoking Web services using an asynchronous client invocation and supports both a callback and polling model. Have a look at: