Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:51622 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 47840 invoked from network); 8 Mar 2011 16:08:39 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 8 Mar 2011 16:08:39 -0000 Authentication-Results: pb1.pair.com header.from=tyra3l@gmail.com; sender-id=pass; domainkeys=bad Authentication-Results: pb1.pair.com smtp.mail=tyra3l@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.212.42 as permitted sender) DomainKey-Status: bad X-DomainKeys: Ecelerity dk_validate implementing draft-delany-domainkeys-base-01 X-PHP-List-Original-Sender: tyra3l@gmail.com X-Host-Fingerprint: 209.85.212.42 mail-vw0-f42.google.com Received: from [209.85.212.42] ([209.85.212.42:46350] helo=mail-vw0-f42.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id E1/F4-19125-484567D4 for ; Tue, 08 Mar 2011 11:08:37 -0500 Received: by vws10 with SMTP id 10so4878996vws.29 for ; Tue, 08 Mar 2011 08:08:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=p4Ara2+K9drYrysNE/HWUFjb4HCc5OHebVjMKG/nQ9I=; b=xZ1mUq5lxeVN4ZRyH29J611b+1oB9T9oiZZe3v1nMzp+nscuyI3d/g8GXRV9QOC+pA bRqj3MczOolwu3rh86GA4qHA1+7XdGqRb42tuZs30EnSJtUiLT2xiqZbng6h2dZ2NFAo PI46YYTsp2xRsxKxp/Vt+yNgR1YqpY90A0fQY= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; b=o6fwauTTuFdjcdVoA2V/W8gknjt+Gg86IaXts1ZSTnAlTFfiQVUNylEKRY7wU3dTIP 8mmnkzzgstelDo5UvQ0nllF2+Tbgcvves2tkT0dILbRGxxTIJzGMVa0vTd2Ndv38TmAu Gk1rkWKf5SyHZ2mY2muNx9nBSG6vwIk0O0rHc= MIME-Version: 1.0 Received: by 10.52.68.168 with SMTP id x8mr5240934vdt.158.1299600513702; Tue, 08 Mar 2011 08:08:33 -0800 (PST) Sender: tyra3l@gmail.com Received: by 10.52.164.165 with HTTP; Tue, 8 Mar 2011 08:08:33 -0800 (PST) In-Reply-To: References: <4D7431C3.10405@sugarcrm.com> <4D74A8FD.3020102@sugarcrm.com> <4D74AB3C.8040702@sugarcrm.com> <4D751AC2.3030800@sugarcrm.com> <4D7535E2.5040007@sugarcrm.com> <4D754997.5080704@sugarcrm.com> <4D754B73.1040800@sugarcrm.com> <4D754EED.5080909@sugarcrm.com> Date: Tue, 8 Mar 2011 17:08:33 +0100 X-Google-Sender-Auth: 6Vo6FX7uG-VuqSMxKOns8TSXptY Message-ID: To: Pierre Joye Cc: Stas Malyshev , "internals@lists.php.net" Content-Type: multipart/alternative; boundary=20cf307f3bb8f81c02049dfad278 Subject: Re: [PHP-DEV] file streams & metadata From: info@tyrael.hu (Ferenc Kovacs) --20cf307f3bb8f81c02049dfad278 Content-Type: text/plain; charset=UTF-8 On Tue, Mar 8, 2011 at 1:55 PM, Pierre Joye wrote: > On Mon, Mar 7, 2011 at 10:49 PM, Ferenc Kovacs wrote: > > > From the sideline: > > it's hard to belive that there are no one else with opinion on this > matter. > > I don't want to take sides because I don't have the necessary knowledge > > about the matter, but maybe it would be a good idea to write an RFC, and > and > > maybe a POC, so we can see how intrusive would be the implementation. > > and if there are more bystanders, then please make your voice heard. > > Tyrael > > It is very easy to implement what Stas is asking. But that's not the > question. The question is should we do it? And my point is that we > should not do it like that, bad design, incomplete and limited > support. > > if you have a better alternative which is viable, then I would support that. otherwise I wouldn't support the all-or-nothing approach. thats like if we couldn't add pecl/phpize until it works on every supported platform/filesystem combination. (cheers for the upcoming 5.3.6 release) and there is a ton of stuff which some point in time (or still ) didn't work on all platform. I think the best thing would be extending streams for every possible method/operation, but require the userland developer to register callbacks for the requested operation, and this way vfsStream devs could mock the chmod calls but the built-in wrappers still would behave correctly (if they didn't explicitly implement/support that operation, they would throw an warning just like now) it's not a generic implementation, but we could allow every single method to be mockable, and we could gradually add support for the new operations for the built-in wrappers. maybe there are other reasons/use-cases for which this solution is not good enough, but it would solve the the initial problem. ps: sorry if I'm missing something, please feel free to point that out. Tyrael --20cf307f3bb8f81c02049dfad278--