Huge rewrite of the code: $session->get, ->set etc. do not read from
authorTatsuhiko Miyagawa <miyagawa@bulknews.net>
Sat, 9 Jan 2010 06:09:38 +0000 (22:09 -0800)
committerTatsuhiko Miyagawa <miyagawa@bulknews.net>
Sat, 9 Jan 2010 16:08:45 +0000 (08:08 -0800)
commit4a0cb5a0600289cfa5ffb0dbf005b154dfe681f0
treebc6e49745de6fd8003329db6bdec4c679759b388
parent000c696ed6b3a6441beaa1e9c531aaeff7490ffb
Huge rewrite of the code: $session->get, ->set etc. do not read from
store as it's called anymore. Session is instantiated in the request
initialization, and committed to the data store in the finalization
phase.

This is more "normal" in terms of web application programming to read,
handle and commit session; imagine you have two concurrent requests
updates multiple keys with multiple ->set() call: the previous
implmentation would update one key from a request and another key from
another. That said, we *might* still need some kind of locking if we
want to provide stricter race condition guard for concurrent requests
with the identical session ids.

Deprecated lots of methods like ->persist, ->delete,
->get_session_id_from_request and changed the API params for ->fetch,
->store etc. Store modules need to be updated but the changes are not
so big.
lib/Plack/Middleware/Session.pm
lib/Plack/Session.pm
lib/Plack/Session/State.pm
lib/Plack/Session/State/Cookie.pm
lib/Plack/Session/Store.pm
lib/Plack/Session/Store/Cache.pm
lib/Plack/Session/Store/File.pm
lib/Plack/Session/Store/Null.pm
t/006_basic_w_null_store.t [changed mode: 0644->0755]
t/lib/TestSession.pm