-
Type: Improvement
-
Resolution: Fixed
-
Priority: Unknown
-
Affects Version/s: None
-
Component/s: None
-
None
The MongoDB\BSON\Iterator class implements PHP's Iterator interface, however this adds a lot of overhead when iterating through elements. PHP's zend_class_entry struct supports providing a get_iterator function which seems to allow for a faster iteration of objects.
If this speeds up iteration, we should consider adding the same logic to The MongoDB\Cursor class, which may suffer from the same performance overhead.
- related to
-
PHPC-2278 Add internal iterator logic for Cursor class
- Backlog