X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=catagits%2FCatalyst-Plugin-Session.git;a=blobdiff_plain;f=lib%2FCatalyst%2FPlugin%2FSession%2FStore.pm;fp=lib%2FCatalyst%2FPlugin%2FSession%2FStore.pm;h=8b8e9083bbfafe65a7d40ac06c2ce7a493ef6861;hp=e3b8a1cdf03c85f33d6b5de84f4987269a9d6ebf;hb=fda03636c8dd39db2d3b855030255c1363eba2d9;hpb=3ebdf42503cf65a10a13ac60082c5aa41cad4f4f diff --git a/lib/Catalyst/Plugin/Session/Store.pm b/lib/Catalyst/Plugin/Session/Store.pm index e3b8a1c..8b8e908 100644 --- a/lib/Catalyst/Plugin/Session/Store.pm +++ b/lib/Catalyst/Plugin/Session/Store.pm @@ -115,6 +115,18 @@ since nothing will actively delete an expired session. The C method is there so that regularly scheduled maintenance scripts can give your backend the opportunity to clean up. +=head2 Early Finalization + +By default the main session plugin will finalize during body finalization +which ensures that all controller code related to the session has completed. +However some storage plugins may wish to finalize earlier, during header +finalization. For example a storage that saved state in a client cookie +would wish this. If a storage plugin wants to finalize early it should set +$c->_needs_early_session_finalization to true. Please note that if you +do this in a storage plugin, you should warn users not to attempt to change +or add session keys if you use a streaming or socket interface such as +$c->res->write, $c->res->write_fh or $c->req->io_fh. + =cut