Skip to content

Compojure rest app and cookies  #7

Open
@practicalli-johnny

Description

@practicalli-johnny

https://github.com/bakku/clj-rest-web-app

A session stores the currently logged in user ID, configured the ring-session middleware to use a cookie store. After restarting the server the session is refreshed as if it is not using any cookie store.

By default Ring uses an in-memory session store. you can change it to store data in a cookie or something persistent like Redis
https://github.com/ring-clojure/ring/wiki/Sessions#session-stores (edited)
Its configured it to store the data in a cookie
using the site-defaults from ring which already wrapped my routes using the session middleware but the site-defaults are using the in-memory session. I had to update the session configuration of the site-defaults according to my needs to get it to work

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions