users@grizzly.java.net

Re: some questions about use

From: Oleksiy Stashok <oleksiy.stashok_at_oracle.com>
Date: Mon, 14 Apr 2014 13:48:16 -0700

Hi Aris,

I'm not a big Jersey expert, but IMO you have to inject Grizzly Request.
There's a known issue with the injection of Grizzly Request to a Jersey
Filter [1], so you have to use correspondent Jersey version for get this
fix (not sure if it's been released).

Thanks.

WBR,
Alexey.

[1] https://java.net/jira/browse/JERSEY-2462

On 14.04.14 13:42, Aris Alexis wrote:
> Thank you for the reply but I cannot find this getSession method.
>
> in the jersey filter what do I call?
>
> requestcontext doesn't have a getsession method.
> requestcontext.getrequest().getsession doesn't exist.
>
> i am using this version
>
> <artifactId>jersey-container-grizzly2-http</artifactId>
>
> and not the servlet version.
>
> thanks in advance
>
> Best Regards,
> Aris Giachnis
>
>
> On Mon, Apr 14, 2014 at 9:45 PM, Oleksiy Stashok
> <oleksiy.stashok_at_oracle.com <mailto:oleksiy.stashok_at_oracle.com>> wrote:
>
> Hi Aris,
>
> Grizzly has similar session API as servlet (Request.getSession()),
> it's in-memory storage.
>
> Thanks.
>
> WBR,
> Alexey.
>
> On 14.04.14 <tel:14.04.14> 09:51, Aris Alexis wrote:
>> Hi,
>>
>> If anyone can help me, I am building a rest service that uses jersey.
>> I run the http-server without servlets right now.
>>
>> I want to authenticate through a jersey filter with facebook
>> (using a third party lib) and then store a session. In the jersey
>> filter i will check if the user has a valid session id.
>>
>> How can I manage this through grizzly? How can I get a reference
>> of the current session in the method that implements the jersey
>> filter?
>>
>> What technology does grizzly use for storing sessions? is it in
>> memory or written on disk? could I change it to use something
>> like redis?
>>
>> sorry for all the questions , there is not much info about
>> grizzly out there.
>>
>> Best Regards,
>> Aris Giachnis
>
>