Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:11966 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 27798 invoked by uid 1010); 6 Aug 2004 15:06:15 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 27714 invoked from network); 6 Aug 2004 15:06:14 -0000 Received: from unknown (HELO colo.lerdorf.com) (66.198.51.121) by pb1.pair.com with SMTP; 6 Aug 2004 15:06:14 -0000 Received: from DELL (c-24-6-1-90.client.comcast.net [24.6.1.90]) by colo.lerdorf.com (8.12.11/8.12.11/Debian-5) with ESMTP id i76F6DPO000373; Fri, 6 Aug 2004 08:06:14 -0700 Date: Fri, 6 Aug 2004 08:06:23 -0700 (Pacific Standard Time) To: Andi Gutmans cc: internals@lists.php.net In-Reply-To: <5.1.0.14.2.20040725104701.02789d40@127.0.0.1> Message-ID: References: <5.1.0.14.2.20040724003444.034ea690@127.0.0.1> <5.1.0.14.2.20040724003444.034ea690@127.0.0.1> <5.1.0.14.2.20040725104701.02789d40@127.0.0.1> X-X-Sender: rasmus@lerdorf.com MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Subject: Re: [PHP-DEV] Everyone on the road? From: rasmus@php.net (Rasmus Lerdorf) On Sun, 25 Jul 2004, Andi Gutmans wrote: > The time() call is part of the patch to check if we should refresh the > realpath cache for this specific path. If it becomes a problem then we > might need to think of a less deterministic approach where we call time() > only every few requests. Another idea I had was to call time() once at the > beginning of the request and always use the same one for reference. I don't > see any major problem with this as far as realpath is concerned. It might > even be useful in other places where not the exact time is needed but the > execution start time is good enough. I meant to mention this a while ago, but it slipped my mind. Most web servers do that time() call for us at the beginning of the request because they need it for logging purposes. I think the right approach here is to add a SAPI call to expose this. For Apache-1.3 it is right in the request_rec in the request_time field. Obviously the SAPI call would simply do the time() call itself if it can't fetch it from somewhere internally. -Rasmus