jsr339-experts@jax-rs-spec.java.net

[jsr339-experts] Re: Passing data from filters to resource

From: Bill Burke <bburke_at_redhat.com>
Date: Wed, 29 May 2013 09:32:17 -0400

This test just wrote, passes in master/

https://github.com/patriot1burke/Resteasy/blob/master/jaxrs/resteasy-jaxrs-testsuite/src/test/java/org/jboss/resteasy/test/nextgen/resource/Response4Test.java

So maybe 3.0-beta-6 fixes your problem.

On 5/29/2013 8:32 AM, Bill Burke wrote:
> I wouldn't inject the ServletContext as this is a global thing, but
> instead the HttpServletRequest. Sucks we can't do this in JAX-RS. This
> was an oversight by us I think.
>
> On 5/29/2013 2:22 AM, Jan Algermissen wrote:
>> Guys,
>>
>> what is the intended way of passing data from filters to resource
>> methods?
>>
>> IIRC in a servlet environment, I can inject ServletContext and use
>> getAttribute() to retrieve the property.
>>
>> Is there any intended way to do the same in a non-Servlet environment
>> (EE Container)?
>>
>>
>> Jan
>>
>

-- 
Bill Burke
JBoss, a division of Red Hat
http://bill.burkecentral.com