AutoWebActorHandler first creates a session and then tries creating an actor based on the current HttpServerExchange.
In cases where the first HTTP path requested it not handled by any defined WebActors (a case which is now possible since the HTTP handlers can be chained), a new session will be created with a null actor reference, leaving the user of the session unable to initiate a WebActor even when the requested path should be handled by it (that is, only till the session invalidates).
I think the session should be created only if an actor relevant to the exchange was found.
An easy fix, though not ideal, would be to check the actorRef in AutoContextProvider and invalidate the session if no actorRef is found.
AutoWebActorHandler
first creates a session and then tries creating an actor based on the currentHttpServerExchange
. In cases where the first HTTP path requested it not handled by any definedWebActor
s (a case which is now possible since the HTTP handlers can be chained), a new session will be created with a null actor reference, leaving the user of the session unable to initiate aWebActor
even when the requested path should be handled by it (that is, only till the session invalidates). I think the session should be created only if an actor relevant to the exchange was found. An easy fix, though not ideal, would be to check the actorRef inAutoContextProvider
and invalidate the session if no actorRef is found.