|Number of watchers on Github||64|
|Number of open issues||1|
|Average time to close an issue||9 months|
|Average time to merge a PR||about 3 hours|
|Open pull requests||0+|
|Closed pull requests||0+|
|Last commit||over 5 years ago|
|Repo Created||over 10 years ago|
|Repo Last Updated||almost 3 years ago|
|Organization / Author||magro|
|Do you use msm-sample-webapp? Leave a review!|
|View msm-sample-webapp activity|
|View on github|
|Book a Mock Interview With Me (Silicon Valley Engineering Leader, 100s of interviews conducted)|
Software engineers: It's time to get promoted. Starting NOW! Subscribe to my mailing list and I will equip you with tools, tips and actionable advice to grow in your career.
A sample (wicket) webapp for playing with memcached-session-manager (msm).
It comes with two tomcats (in
runtime/) that are configured with msm+kryo (msm kryo-serializer) storing sessions in memcached.
This sample comes with two tomcat instances (in
runtime/, tomcat1 and tomcat2) that are configured with msm+kryo (msm kryo-serializer) for non-sticky sessions by default.
To change the stickyness you can switch via
Btw, there are 2 different tomcat versions available in
runtime/ (6.0.32 and 7.0.8), you can switch them via
./switch-tomcat.sh 7.0.8 or
$ mvn package
You can run the webapp using the preconfigured tomcats in
runtime/. Before you start tomcat, make sure that you have started two memcached nodes:
$ memcached -p 11211 -u memcached -m 64 -M -vv &
$ memcached -p 11212 -u memcached -m 64 -M -vv &
This is the cmd line that I'm using on my system with memcached installed using the memcached user. -vv tells memcached to write lots of stuff to stdout, so you'll see when a session is requested or stored in the output of memcached.
To start both tomcats just run $ ./runtime/tomcat1/bin/catalina.sh run & $ ./runtime/tomcat2/bin/catalina.sh run &
Now you can access both tomcats with your browser on http://localhost:8081/ and http://localhost:8082/. To simulate a loadbalancer in front of your tomcats and a session failover just request the same url on the other tomcat (just change to port in the url).