A typical websocket-based application may use a combination of REST and websocket endpoints, with the following security config for setting the identity state:
builder .identity() .stateless()
Unfortunately there is no such thing as request scope for a websockets message handler method, so attempting to inject the Identity bean results in the following exception:
org.jboss.weld.context.ContextNotActiveException:
WELD-001303
: No active contexts for scope type javax.enterprise.context.RequestScoped
|