simple spring-session demo project
-
download sources of example:
$ git clone https://github.com/daggerok/spring-session-demo.git
-
install and run redis-server:
-
build and run application:
$ gradle clean build bootRun # if you have gradle $ ./gradlew clean build bootRun # if you have no gradle
-
now you can get session uid:
-
do same a few times and you will have same uid
-
to remove existed sessions from redis folow next commands:
$ $REDIS_HOME/src/redis-cli > FLUSHALL
-
now you can refresh opened page to get new session uid
-
if you want to see all sessions, use select-all query in redis-cli:
> keys *
have fun with spring-session :)