Uploaded image for project: 'PHP Driver: Library'
  1. PHP Driver: Library
  2. PHPLIB-609

Allow CachingIterator to handle Iterators with non-unique keys

      CachingIterator currently caches items in a PHP array using the original keys from the wrapped Traversable. If the Traversable has any duplicate keys, CachingIterator is prone to overwriting cached elements and returning an incorrect count.

      We should be able to fix this by changing the cache into a list of key/value tuples.

      Note that this is not a problem for MongoDB cursors, since PHPC uses sequential integers for its cursor keys.

            Assignee:
            aleksandr.rudo@mongodb.com Aleksandr Rudo (Inactive)
            Reporter:
            jmikola@mongodb.com Jeremy Mikola
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: