You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Uwe Schäfer <uw...@codesmell.de> on 2013/06/28 07:46:18 UTC

clustering and failover

hi

quick question about clustering: am i right to believe that putting 
session/pagemap data in a memcached-like storage has advantages over the 
tomcat session clustering in terms of latency and robust failover behaviour?
i mean, the latter obviously has the data nearby (when assuming sticky 
sessions) whereas the first needs to grab it from (and push it to) 
external storage every time even though it is far more selective about 
what it needs.

i was wondering if tomcat session clustering can effectivly update only 
the dirty parts of the session data?

i'd love any kind of feedback on that topic INCLUDING 'depends'-answers :)

cu uwe

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: clustering and failover

Posted by Martin Grigorov <mg...@apache.org>.
Hi Uwe,

There are no pagemaps since 1.5.0.
Only the last used stateful page instance is kept in the memory (as an
attribute in the http session).
The Memcached Session Manager for Tomcat is just an internal of how Tomcat
will manage its http sessions.
For the application there is no change at all. Wicket still will use the
Servlet APIs and Tomcat will do something different than what it does by
default without exposing this to you.

On the other hand if you provide your own implementation of Wicket's
ISessionStore (I know the code in 1.5/6.x better than 1.4.x but I guess it
is similar in 1.4.x too) then you can store Wicket's Session and the last
stateful page instance in something else than the Http Session, e.g. in
Memcached/Hazelcast/Redis/....

In all cases your app should be able to work without sticky sessions
because if a Tomcat node goes down for any reason then your clients will be
directed to other node(s).



On Sun, Jun 30, 2013 at 2:09 PM, uwe schaefer <uw...@codesmell.de> wrote:

> On 06/29/2013 03:49 PM, William Speirs wrote:
>
>> Another consideration is if you're using any authentication
>> Been there, still have the bite marks from that :-)
>>
>
> *g* thanks Bill, i planned to do session clustering, but have the pagemap
> seperate, so that i hopefully would not run into this.
>
> cu uwe
>
>
>
> ------------------------------**------------------------------**---------
> To unsubscribe, e-mail: users-unsubscribe@wicket.**apache.org<us...@wicket.apache.org>
> For additional commands, e-mail: users-help@wicket.apache.org
>
>

Re: clustering and failover

Posted by uwe schaefer <uw...@codesmell.de>.
On 06/29/2013 03:49 PM, William Speirs wrote:
> Another consideration is if you're using any authentication
> Been there, still have the bite marks from that :-)

*g* thanks Bill, i planned to do session clustering, but have the 
pagemap seperate, so that i hopefully would not run into this.

cu uwe


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: clustering and failover

Posted by William Speirs <ws...@apache.org>.
Another consideration is if you're using any authentication that
relies upon the tomcat session, then bouncing to another box (if
you're doing round-robin load balanced) would mean your users will
have to reauthenticate.

Been there, still have the bite marks from that :-)

Bill-

On Fri, Jun 28, 2013 at 4:50 PM, uwe schaefer <uw...@uwe-schaefer.org> wrote:
> On 06/28/2013 09:19 AM, Martin Grigorov wrote:
>
> Hi Martin,
>
> i already saw and consider your memcached-based session management, thanks.
> the reason i ask the wicket mailing list is, that i assume that wicket only
> needs part of the pagemap (namely the current page) to serve a request, so
> that - hopefully - the data needed to serve a single request can be smaller
> if the pagemap is kept seperate from the session.
>
> is this assumption correct?
>
> cu uwe
>
>
>> I think you should ask this question in Tomcat mailing list.
>> Also check https://code.google.com/p/memcached-session-manager/
>>
>>
>> On Fri, Jun 28, 2013 at 8:46 AM, Uwe Schäfer <uw...@codesmell.de> wrote:
>>
>>> hi
>>>
>>> quick question about clustering: am i right to believe that putting
>>> session/pagemap data in a memcached-like storage has advantages over the
>>> tomcat session clustering in terms of latency and robust failover
>>> behaviour?
>>> i mean, the latter obviously has the data nearby (when assuming sticky
>>> sessions) whereas the first needs to grab it from (and push it to)
>>> external
>>> storage every time even though it is far more selective about what it
>>> needs.
>>>
>>> i was wondering if tomcat session clustering can effectivly update only
>>> the dirty parts of the session data?
>>>
>>> i'd love any kind of feedback on that topic INCLUDING 'depends'-answers
>>> :)
>>>
>>> cu uwe
>>>
>>> ------------------------------**------------------------------**---------
>>> To unsubscribe, e-mail:
>>> users-unsubscribe@wicket.**apache.org<us...@wicket.apache.org>
>>> For additional commands, e-mail: users-help@wicket.apache.org
>>>
>>>
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>
> For additional commands, e-mail: users-help@wicket.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: clustering and failover

Posted by uwe schaefer <uw...@uwe-schaefer.org>.
On 06/28/2013 09:19 AM, Martin Grigorov wrote:

Hi Martin,

i already saw and consider your memcached-based session management, thanks.
the reason i ask the wicket mailing list is, that i assume that wicket 
only needs part of the pagemap (namely the current page) to serve a 
request, so that - hopefully - the data needed to serve a single request 
can be smaller if the pagemap is kept seperate from the session.

is this assumption correct?

cu uwe

> I think you should ask this question in Tomcat mailing list.
> Also check https://code.google.com/p/memcached-session-manager/
>
>
> On Fri, Jun 28, 2013 at 8:46 AM, Uwe Schäfer <uw...@codesmell.de> wrote:
>
>> hi
>>
>> quick question about clustering: am i right to believe that putting
>> session/pagemap data in a memcached-like storage has advantages over the
>> tomcat session clustering in terms of latency and robust failover behaviour?
>> i mean, the latter obviously has the data nearby (when assuming sticky
>> sessions) whereas the first needs to grab it from (and push it to) external
>> storage every time even though it is far more selective about what it needs.
>>
>> i was wondering if tomcat session clustering can effectivly update only
>> the dirty parts of the session data?
>>
>> i'd love any kind of feedback on that topic INCLUDING 'depends'-answers :)
>>
>> cu uwe
>>
>> ------------------------------**------------------------------**---------
>> To unsubscribe, e-mail: users-unsubscribe@wicket.**apache.org<us...@wicket.apache.org>
>> For additional commands, e-mail: users-help@wicket.apache.org
>>
>>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: clustering and failover

Posted by Martin Grigorov <mg...@apache.org>.
Hi,

I think you should ask this question in Tomcat mailing list.
Also check https://code.google.com/p/memcached-session-manager/


On Fri, Jun 28, 2013 at 8:46 AM, Uwe Schäfer <uw...@codesmell.de> wrote:

> hi
>
> quick question about clustering: am i right to believe that putting
> session/pagemap data in a memcached-like storage has advantages over the
> tomcat session clustering in terms of latency and robust failover behaviour?
> i mean, the latter obviously has the data nearby (when assuming sticky
> sessions) whereas the first needs to grab it from (and push it to) external
> storage every time even though it is far more selective about what it needs.
>
> i was wondering if tomcat session clustering can effectivly update only
> the dirty parts of the session data?
>
> i'd love any kind of feedback on that topic INCLUDING 'depends'-answers :)
>
> cu uwe
>
> ------------------------------**------------------------------**---------
> To unsubscribe, e-mail: users-unsubscribe@wicket.**apache.org<us...@wicket.apache.org>
> For additional commands, e-mail: users-help@wicket.apache.org
>
>