Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:73467 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 57095 invoked from network); 28 Mar 2014 09:46:42 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 28 Mar 2014 09:46:42 -0000 Authentication-Results: pb1.pair.com header.from=narf@devilix.net; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=narf@devilix.net; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain devilix.net designates 209.85.160.176 as permitted sender) X-PHP-List-Original-Sender: narf@devilix.net X-Host-Fingerprint: 209.85.160.176 mail-yk0-f176.google.com Received: from [209.85.160.176] ([209.85.160.176:65188] helo=mail-yk0-f176.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id DA/64-31219-00545335 for ; Fri, 28 Mar 2014 04:46:42 -0500 Received: by mail-yk0-f176.google.com with SMTP id 19so3396345ykq.7 for ; Fri, 28 Mar 2014 02:46:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=devilix.net; s=google; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=PS6tvsfqpH+xOOL/OlnccIj5v8YufJMV90AZH+ED8HQ=; b=LMZ8laUAweP4D713kSlV5dd6JpKzGOdqjzLsoh3Rn2cFEJ0CMlVyM7lYDaFpqSXzki JUNK1lBIaAMWVudrtX8EGUQEyDnzfquVILo41HdDSTxIeyXPT9PSx+uxR9sOqI4S/WMn K+A4/Kf/b6zLrBGG4VNE3BVwa6mUIqztE26YE= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=PS6tvsfqpH+xOOL/OlnccIj5v8YufJMV90AZH+ED8HQ=; b=NsQBVw9ndrptRIeD1gSHiZgYDH+ZYtAljq8221wX8VKwhcMZRG5SJjiwgFCuFcnlni JiWQmZL56kpEN0fp68lloGC5szR8ys0DePk6XZowdVB0s4MjMN3N3ft6y4ee+LxVyDWs HQ2kmDU/AA8z1ZbRvJOLhYNPseR+vtzM9KHfAblMSPeAxjiHwf2Cyn5Wa/Lu1MGxxxgG liyjOZ6eA12N+/e/V3QZ46GdPWNTtEHMdLpAuGhtYtPdP52BbQ8EorQz5vmFmmWlVoEe okk5pjOkquJ4S1xgrUODu9gKCYJ7HSJnUjRCdv/s1vzc4bdzRcOPcyuBWSFJ1poie8lv bO2Q== X-Gm-Message-State: ALoCoQkJfni51etDJNOGHvExv+MSvuXckjPQeKwGiAxlM8Z6zkBGXqwXKFOAuWCtItZFZ86QsU9l MIME-Version: 1.0 X-Received: by 10.236.66.143 with SMTP id h15mr9840071yhd.36.1395999998044; Fri, 28 Mar 2014 02:46:38 -0700 (PDT) Received: by 10.170.188.139 with HTTP; Fri, 28 Mar 2014 02:46:37 -0700 (PDT) In-Reply-To: References: <010e01cf4788$05f3c5a0$11db50e0$@devtemple.com> <01c801cf47c0$59acbf20$0d063d60$@devtemple.com> Date: Fri, 28 Mar 2014 11:46:37 +0200 Message-ID: To: Yasuo Ohgaki Cc: Julien Pauli , Bill Salak , "internals@lists.php.net" Content-Type: text/plain; charset=UTF-8 Subject: Re: [PHP-DEV] [RFC] session_start(), read_only, lazy_write; Take 2 From: narf@devilix.net (Andrey Andreev) Hi, >> >> Btw, another argument in merging updateTimestamp() into write() is >> >> that userland implementations of it up until now have only been >> >> possible by altering write(), so at least some users should be more >> >> familiar with that approach. >> > >> > >> > Component only does its jobs with good implementation. >> > Session module consists of session manager, session save handler and >> > session >> > serializer. >> > >> > Session manager should manage how it works. >> > Session save handler should save/retrieve session data only. >> > Session serializer should serialize/unserialize data only. >> > >> > It breaks this design with your suggestion. >> > So letting save handler do the manager's job is not good. IMO. >> >> I don't understand how that's breaking any kind of design. Could you >> elaborate? > > > Manager should manage how session behaves, not save handlers. > It's basic principle of modular design. I still don't get it ... the session manager has to call either write() or updateTimestamp() and both of these are part of the session handler. Merging them into one solves the API design and BC issues, I don't see how it breaks any principle. They can still be split to two methods in PHP6, but for the time being, using write() for both purposes IMO solves way more problems than sticking to this design principle you're talking about. Cheers, Andrey.