note 114871 added to apciterator.construct
| From: | puiumarius at gmail dot com | Date: | Fri, 18 Apr 2014 09:13:24 +0000 |
| Subject: | note 114871 added to apciterator.construct | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-199289@lists.php.net to get a copy of this message | ||
There is a bug in APCIterator: whatever the chunk size, APCIterator gets ALL keys matching the
specified pattern (it seems that $chunk_size parameter is ignored).
Also, the documentation states that the default chunk size is 100, but even that is ignored.
Tested APC version is 3.1.13.
Example (I have 180 keys for this pattern in total):
$objIterator = new APCIterator('user', '/^key_prefix_\.*/', APC_ITER_ALL, 20);
If I itterate $objIterator and then count() the results, I get 180.
Also, for:
$objIterator = new APCIterator('user', '/^key_prefix_\.*/');
Same count(), 180.
Even $objIterator->getTotalCount() returns 180.
----
Server IP: 72.52.91.14
Probable Submitter: 85.9.8.147
----
Manual Page -- http://php.net/manual/en/apciterator.construct.php
Edit -- https://master.php.net/note/edit/114871
Del: integrated -- https://master.php.net/note/delete/114871/integrated
Del: useless -- https://master.php.net/note/delete/114871/useless
Del: bad code -- https://master.php.net/note/delete/114871/bad+code
Del: spam -- https://master.php.net/note/delete/114871/spam
Del: non-english -- https://master.php.net/note/delete/114871/non-english
Del: in docs -- https://master.php.net/note/delete/114871/in+docs
Del: other reasons-- https://master.php.net/note/delete/114871
Reject -- https://master.php.net/note/reject/114871
Search -- https://master.php.net/manage/user-notes.php