Description
If we call continuation.resume in another thread after we call continuation.suspend immediately, we may encounter a situation where resume is called on continuation before the SuspendedInvocationException causes PhaseInterceptorChain to change state to 'paused', so that ChainInitiationObserver instead of resuming the the PhaseInterceptorChain from where it was suspended, it starts it's from the beginning. This is incorrect as interceptors that has already been run are called again in this case.
With this attached testcase which expose this problem, simply use continuation api in a jaxws provider, we can see the IncomingMessageCounterInterceptor get invoked twice for one incoming messsage intermittently.