I would definitely double check that both filters use the same HttpContext and aren't having their own default ones created. Can't say for sure it will solve your problem, but I know that not using the same HttpContext across servlets will pretty much guarantee they won't share anything.

- Rob

On 12/12/2012 1:49 PM, Reto Bachmann-Gmür wrote:
On Dec 12, 2012 6:13 AM, "Rob Walker" <[email protected]> wrote:
One thing you don't mention is your bundle and alias usage structure.
Both filters are registered using the whiteboard extension and with the
identical pattern.

Cheers,
Reto

Also, Filters (to my knowledge) weren't ever really a part of the OSGi
HttpService spec - so you should be prepared for some digging and
experimentation!
Are you registering the servlets used yourself within your own code (i.e.
using the HttpService registerServlet call? If so, then one thing you could
try is to make sure you create your own HttpContext for the register
servlet call, and use the same instance of that object for every servlet
you register. I'm not 100% sure that will cure your case, but worth a try.
Also possible you might need both the above and the
shared_servlet_context_attributes flag set
-- Rob


On 11/12/2012 10:19 PM, Reto Bachmann-Gmür wrote:
Helo

I'm trying to integrate an application that makes extensive use of
ServletContext for communication between components via attributes.
Unfortunately it seems that different Filters have different
servletContexts so that the attributes set to the context of one filter
cannot be accessed from the context of another filter. I also tries
setting
org.apache.felix.http.shared_servlet_context_attributes to "true" but
this
didn't make any difference.

Any idea how to have a shared ServletContext?

Cheers,
Reto

--


Ascert - Taking systems to the edge
[email protected]
+27 21 300 2028 ext 5119
www.ascert.com


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]


--


Ascert - Taking systems to the edge
[email protected]
+27 21 300 2028 ext 5119
www.ascert.com


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to