-
-
Notifications
You must be signed in to change notification settings - Fork 202
Closed
Labels
Milestone
Description
We're trying to use jooby inside a Servlet container. In that setup, we also have a Filter that adds request scoped info into each request (using HttpServletRequest#setAttribute).
Unfortunately, there's no way to access those attributes using jooby's Request object. We have an ugly workaround in place, using a ThreadLocal and a jooby before filter:
before((req, rsp) -> {
req.set("attributeName", someThreadLocal.get());
});A possible solution, would be merging the HttpServletRequest#attributes into jooby's locals attributes. I have a patch that implements that, I can open a PR if it seems like a good enough solution. Let me know.