Re: fix inode/device usage for win32, take #1

From: Date: Sun, 18 Oct 2009 18:57:57 +0000
Subject: Re: fix inode/device usage for win32, take #1
References: 1  Groups: php.apc.dev 
Request: Send a blank email to php-apc-dev+get-240@lists.php.net to get a copy of this message
hi, The patch seems to be incomplete. The test case from the bug report fails with apc.stat=0, on the 2nd request, with: Warning: require_once(G:\apps\Apache2\Zend\Application.php) [function.require-once]: failed to open stream: No such file or directory in G:\apps\Apache2\htdocs\16860\index.php on line 5 Fatal error: require_once() [function.require]: Failed opening required 'G:\apps\Apache2\Zend\Application.php' (include_path='G:/apps/Apache2/htdocs/16860;.') in G:\apps\Apache2\htdocs\16860\index.php on line 5 Every 1st request works, it only fails for every request after the very 1st one (entries added). It does not even try to do a apc_cache_find_slot for this file in the 2nd+ request. I do not know enough about APC at this stage to provide a quick diagnostic. I can work again on that after 5.3.1RC2 (tomorrow evening). Any advices welcome :) Cheers, On Sat, Oct 17, 2009 at 8:15 PM, Pierre Joye <pierre.php@gmail.com> wrote: > hi, > > This is a first attempt (draft) to fix the pecl bug #16860 > (http://pecl.php.net/bugs/bug.php?id=16860). > > Here are the changes I made so far: > > - add apc_ino_t and apc_dev_t >  - native ino_t/dev_t on non windows platform >  - unsigned int64 on windows > > - use string for the inode and device key (cache info and iterator) > - device uses now the volume serial number (part of the file information) > - inode uses now the file id (part of the file information) > - add zend_file_handle support to apc_cache_make_file_key to avoid (no > need to open/stat a file already opened) >  - to do: have to add fstat on unix >  - getfileinfofromhandle (stat-like) is used on windows > > I have tested it using fcgi and apache 2.2 on windows and everything > seems to work as it should. However I like to test it further and fix > any side effects before to apply it. Thomas Peterson also tested it > using apache and CLI with the test cases provided in the report. > > Comments and suggestions welcome :) > > Cheers, > -- > Pierre > > http://blog.thepimp.net | > http://www.libgd.org > -- Pierre http://blog.thepimp.net | http://www.libgd.org

« previous php.apc.dev (#240) next »