You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by 杨华杰 <yh...@gmail.com> on 2013/05/24 13:28:10 UTC

How to store session in database

Hi

Basically I want to configure a tomcat cluster.

I am using tomcat 6 and tomcat 7 and I want to store the session in
database.

I am looking to this document
http://tomcat.apache.org/tomcat-6.0-doc/cluster-howto.html . But
unfortunately I didn't find any document to store session in database. Is
there any? Just let me know which document I can refer.




Regards,
Hua Jie

Re: How to store session in database

Posted by Serge Fonville <se...@gmail.com>.
Hi,

Does
http://www.intelligrape.com/blog/2010/07/21/tomcat-6-session-persistence-through-jdbcstore/
help
answer your question?

HTH

Kind regards/met vriendelijke groet,

Serge Fonville

http://www.sergefonville.nl

Convince Microsoft!
They need to add TRUNCATE PARTITION in SQL Server
https://connect.microsoft.com/SQLServer/feedback/details/417926/truncate-partition-of-partitioned-table


2013/5/24 杨华杰 <yh...@gmail.com>

> Hi
>
> Basically I want to configure a tomcat cluster.
>
> I am using tomcat 6 and tomcat 7 and I want to store the session in
> database.
>
> I am looking to this document
> http://tomcat.apache.org/tomcat-6.0-doc/cluster-howto.html . But
> unfortunately I didn't find any document to store session in database. Is
> there any? Just let me know which document I can refer.
>
>
>
>
> Regards,
> Hua Jie
>

Re: How to store session in database

Posted by 杨华杰 <yh...@gmail.com>.
Hi Serge, Daniel & Albert

Thanks, it does help. Seems like there are many options.

Regards,
Hua Jie


On Fri, May 24, 2013 at 7:51 PM, Albert Kam <mo...@gmail.com>wrote:

> Hopefully these open source nosql-tomcat-session-managers could be helpful
> in your jorney :
> https://github.com/jcoleman/tomcat-redis-session-manager
> https://github.com/dawsonsystems/Mongo-Tomcat-Sessions
>
>
> On Fri, May 24, 2013 at 6:47 PM, Daniel Mikusa <dmikusa@gopivotal.com
> >wrote:
>
> > On May 24, 2013, at 7:28 AM, 杨华杰 wrote:
> >
> > > Hi
> > >
> > > Basically I want to configure a tomcat cluster.
> > >
> > > I am using tomcat 6 and tomcat 7 and I want to store the session in
> > > database.
> > >
> > > I am looking to this document
> > > http://tomcat.apache.org/tomcat-6.0-doc/cluster-howto.html . But
> > > unfortunately I didn't find any document to store session in database.
> Is
> > > there any? Just let me know which document I can refer.
> > >
> > >
> > >
> > >
> > > Regards,
> > > Hua Jie
> >
> > If you look at the "Overview" section of the documentation that you
> linked
> > to, you'll see that there are three options for session replication.
> >
> > "       • Using session persistence, and saving the session to a shared
> > file system (PersistenceManager + FileStore)
> >         • Using session persistence, and saving the session to a shared
> > database (PersistenceManager + JDBCStore)
> >         • Using in-memory-replication, using the SimpleTcpCluster that
> > ships with Tomcat 6 (lib/catalina-tribes.jar + lib/catalina-ha.jar)"
> >
> >   https://tomcat.apache.org/tomcat-6.0-doc/cluster-howto.html#Overview
> >
> > Documentation for the first two can be found here.
> >
> >
> >
> https://tomcat.apache.org/tomcat-6.0-doc/config/manager.html#Nested_Components
> >
> > Dan
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> > For additional commands, e-mail: users-help@tomcat.apache.org
> >
> >
>
>
> --
> Do not pursue the past. Do not lose yourself in the future.
> The past no longer is. The future has not yet come.
> Looking deeply at life as it is in the very here and now,
> the practitioner dwells in stability and freedom.
> (Thich Nhat Hanh)
>

Re: How to store session in database

Posted by Albert Kam <mo...@gmail.com>.
Hopefully these open source nosql-tomcat-session-managers could be helpful
in your jorney :
https://github.com/jcoleman/tomcat-redis-session-manager
https://github.com/dawsonsystems/Mongo-Tomcat-Sessions


On Fri, May 24, 2013 at 6:47 PM, Daniel Mikusa <dm...@gopivotal.com>wrote:

> On May 24, 2013, at 7:28 AM, 杨华杰 wrote:
>
> > Hi
> >
> > Basically I want to configure a tomcat cluster.
> >
> > I am using tomcat 6 and tomcat 7 and I want to store the session in
> > database.
> >
> > I am looking to this document
> > http://tomcat.apache.org/tomcat-6.0-doc/cluster-howto.html . But
> > unfortunately I didn't find any document to store session in database. Is
> > there any? Just let me know which document I can refer.
> >
> >
> >
> >
> > Regards,
> > Hua Jie
>
> If you look at the "Overview" section of the documentation that you linked
> to, you'll see that there are three options for session replication.
>
> "       • Using session persistence, and saving the session to a shared
> file system (PersistenceManager + FileStore)
>         • Using session persistence, and saving the session to a shared
> database (PersistenceManager + JDBCStore)
>         • Using in-memory-replication, using the SimpleTcpCluster that
> ships with Tomcat 6 (lib/catalina-tribes.jar + lib/catalina-ha.jar)"
>
>   https://tomcat.apache.org/tomcat-6.0-doc/cluster-howto.html#Overview
>
> Documentation for the first two can be found here.
>
>
> https://tomcat.apache.org/tomcat-6.0-doc/config/manager.html#Nested_Components
>
> Dan
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>


-- 
Do not pursue the past. Do not lose yourself in the future.
The past no longer is. The future has not yet come.
Looking deeply at life as it is in the very here and now,
the practitioner dwells in stability and freedom.
(Thich Nhat Hanh)

Re: How to store session in database

Posted by Daniel Mikusa <dm...@gopivotal.com>.
On May 24, 2013, at 7:28 AM, 杨华杰 wrote:

> Hi
> 
> Basically I want to configure a tomcat cluster.
> 
> I am using tomcat 6 and tomcat 7 and I want to store the session in
> database.
> 
> I am looking to this document
> http://tomcat.apache.org/tomcat-6.0-doc/cluster-howto.html . But
> unfortunately I didn't find any document to store session in database. Is
> there any? Just let me know which document I can refer.
> 
> 
> 
> 
> Regards,
> Hua Jie

If you look at the "Overview" section of the documentation that you linked to, you'll see that there are three options for session replication.

"	• Using session persistence, and saving the session to a shared file system (PersistenceManager + FileStore)
	• Using session persistence, and saving the session to a shared database (PersistenceManager + JDBCStore)
	• Using in-memory-replication, using the SimpleTcpCluster that ships with Tomcat 6 (lib/catalina-tribes.jar + lib/catalina-ha.jar)"

  https://tomcat.apache.org/tomcat-6.0-doc/cluster-howto.html#Overview

Documentation for the first two can be found here.

  https://tomcat.apache.org/tomcat-6.0-doc/config/manager.html#Nested_Components

Dan


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