We've been using Yar for sessions, and storing sessions in Redis. Over time, a very large number of entirely empty sessions have accumulated; these are created on requests with authentication is optional, which in our case is the majority of routes.
This PRs adds an option, storeBlank which simply sets the initial _isModified property, which causes new sessions that are not changed to not be persisted or sent down in the set-cookie. It defaults to true - which is the current behaviour of the library - so no breaking change is introduced.
This thread has been automatically locked due to inactivity. Please open a new issue for related bugs or questions following the new issue template instructions.
We've been using Yar for sessions, and storing sessions in Redis. Over time, a very large number of entirely empty sessions have accumulated; these are created on requests with authentication is optional, which in our case is the majority of routes.
This PRs adds an option,
storeBlank
which simply sets the initial_isModified
property, which causes new sessions that are not changed to not be persisted or sent down in the set-cookie. It defaults totrue
- which is the current behaviour of the library - so no breaking change is introduced.