Re: [PATCH] default session serialization

From: Date: Thu, 26 Nov 2009 00:43:13 +0000
Subject: Re: [PATCH] default session serialization
References: 1  Groups: php.internals 
Request: Send a blank email to internals+get-46193@lists.php.net to get a copy of this message
Hi!
Attached is a patch (against HEAD) which adapts the default ("php") session serializer to serialize the whole array using php_var_serialize instead of calling it once per element. This simplifies the serialization code, and allows unicode session keys, or even ascii keys containing the pipe character.
I think it makes sense. One note: your code allows numeric session keys, previously not allowed. Not sure if it's important.
However it would be a significant BC break, as old serialized session records would be unreadable after upgrading. We could mitigate this by providing a script to convert old session files.
If it would be a problem, we could always keep an old one as "php_old" for a while for those who need it, just not make it the default. -- Stanislav Malyshev, Zend Software Architect stas@zend.com http://www.zend.com/ (408)253-8829 MSN: stas@zend.com

« previous php.internals (#46193) next »