Currently, we accept all OPTIONS requests and let CORS be handled in onBeforeConnect on the actor. This is for two reasons:
- WebSockets do not support CORS, so this should be implemented anyways
- Waking an actor for an OPTIONS request does not make sense
We should enable configuration of CORS per-actor in order to prevent requests from reaching an actor without having to run onBeforeConnect on the actor itself. Consider extending this mechanism to WebSockets, even though this is non-standard behavior.