NancyFx/Nancy — pull request #1260 by omeaart (2013-10-10 21:57:17+00:00)
Title: Update session only is value is changed

The session should only be updated if the value really changes.
Because if you are using the CookieBasedSessions, at every session change you get a big Set-Cookie header. In our case, it became so big that our varnish server dropped the header. Therefore (and because awesome) we will switch to Redis based sessions.
The problem with the changed value came to light when I decided to make sure a certain value was always set, so in every request there was a session "change".

You could also argue that you should check de value in the session yourself for changes, but it seems to me this would help a lot and wouldn't kill the performance :)