Linux vmi2545633.contaboserver.net 6.1.0-32-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.129-1 (2025-03-06) x86_64
Apache/2.4.62 (Debian)
Server IP : 127.0.0.1 & Your IP : 127.0.0.1
Domains :
Cant Read [ /etc/named.conf ]
User : www-data
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
usr /
share /
php /
tests /
mongodb /
tests /
cursor /
Delete
Unzip
Name
Size
Permission
Date
Action
bug0671-001.phpt
653
B
-rw-r--r--
2025-04-09 02:56
bug0732-001.phpt
934
B
-rw-r--r--
2025-04-09 02:56
bug0849-001.phpt
1013
B
-rw-r--r--
2025-04-09 02:56
bug0924-001.phpt
1.46
KB
-rw-r--r--
2025-04-09 02:56
bug0924-002.phpt
1.87
KB
-rw-r--r--
2025-04-09 02:56
bug1050-001.phpt
2.66
KB
-rw-r--r--
2025-04-09 02:56
bug1050-002.phpt
3.16
KB
-rw-r--r--
2025-04-09 02:56
bug1151-001.phpt
821
B
-rw-r--r--
2025-04-09 02:56
bug1151-002.phpt
924
B
-rw-r--r--
2025-04-09 02:56
bug1151-003.phpt
763
B
-rw-r--r--
2025-04-09 02:56
bug1151-004.phpt
866
B
-rw-r--r--
2025-04-09 02:56
bug1152-001.phpt
4.69
KB
-rw-r--r--
2025-04-09 02:56
bug1152-002.phpt
4.59
KB
-rw-r--r--
2025-04-09 02:56
bug1162-001.phpt
942
B
-rw-r--r--
2025-04-09 02:56
bug1274-001.phpt
2.16
KB
-rw-r--r--
2025-04-09 02:56
bug1274-002.phpt
3.32
KB
-rw-r--r--
2025-04-09 02:56
bug1274-003.phpt
2.85
KB
-rw-r--r--
2025-04-09 02:56
bug1274-004.phpt
2.24
KB
-rw-r--r--
2025-04-09 02:56
bug1274-005.phpt
3.39
KB
-rw-r--r--
2025-04-09 02:56
bug1274-006.phpt
2.93
KB
-rw-r--r--
2025-04-09 02:56
bug1419-001.phpt
1.18
KB
-rw-r--r--
2025-04-09 02:56
bug1529-001.phpt
3.18
KB
-rw-r--r--
2025-04-09 02:56
bug1713-001.phpt
472
B
-rw-r--r--
2025-04-09 02:56
cursor-001.phpt
355
B
-rw-r--r--
2025-04-09 02:56
cursor-IteratorIterator-001.phpt
827
B
-rw-r--r--
2025-04-09 02:56
cursor-IteratorIterator-002.phpt
1001
B
-rw-r--r--
2025-04-09 02:56
cursor-IteratorIterator-003.phpt
1020
B
-rw-r--r--
2025-04-09 02:56
cursor-NoRewindIterator-001.phpt
1.59
KB
-rw-r--r--
2025-04-09 02:56
cursor-destruct-001.phpt
1.56
KB
-rw-r--r--
2025-04-09 02:56
cursor-getmore-001.phpt
913
B
-rw-r--r--
2025-04-09 02:56
cursor-getmore-002.phpt
903
B
-rw-r--r--
2025-04-09 02:56
cursor-getmore-003.phpt
1.05
KB
-rw-r--r--
2025-04-09 02:56
cursor-getmore-004.phpt
1.04
KB
-rw-r--r--
2025-04-09 02:56
cursor-getmore-005.phpt
1.51
KB
-rw-r--r--
2025-04-09 02:56
cursor-getmore-006.phpt
1.65
KB
-rw-r--r--
2025-04-09 02:56
cursor-isDead-001.phpt
735
B
-rw-r--r--
2025-04-09 02:56
cursor-isDead-002.phpt
827
B
-rw-r--r--
2025-04-09 02:56
cursor-iterator-001.phpt
1.3
KB
-rw-r--r--
2025-04-09 02:56
cursor-iterator-002.phpt
1.25
KB
-rw-r--r--
2025-04-09 02:56
cursor-iterator-003.phpt
859
B
-rw-r--r--
2025-04-09 02:56
cursor-iterator-004.phpt
1.66
KB
-rw-r--r--
2025-04-09 02:56
cursor-iterator_handlers-001.phpt
2
KB
-rw-r--r--
2025-04-09 02:56
cursor-rewind-001.phpt
2.32
KB
-rw-r--r--
2025-04-09 02:56
cursor-session-001.phpt
1.5
KB
-rw-r--r--
2025-04-09 02:56
cursor-session-002.phpt
1.32
KB
-rw-r--r--
2025-04-09 02:56
cursor-session-003.phpt
1.62
KB
-rw-r--r--
2025-04-09 02:56
cursor-session-004.phpt
1.58
KB
-rw-r--r--
2025-04-09 02:56
cursor-setTypeMap_error-001.phpt
3.73
KB
-rw-r--r--
2025-04-09 02:56
cursor-setTypeMap_error-002.phpt
1.2
KB
-rw-r--r--
2025-04-09 02:56
cursor-setTypeMap_error-003.phpt
1.07
KB
-rw-r--r--
2025-04-09 02:56
cursor-setTypeMap_error-004.phpt
1.84
KB
-rw-r--r--
2025-04-09 02:56
cursor-tailable-001.phpt
1.82
KB
-rw-r--r--
2025-04-09 02:56
cursor-tailable-002.phpt
1.88
KB
-rw-r--r--
2025-04-09 02:56
cursor-tailable-003.phpt
1.16
KB
-rw-r--r--
2025-04-09 02:56
cursor-tailable_error-001.phpt
2.08
KB
-rw-r--r--
2025-04-09 02:56
cursor-tailable_error-002.phpt
2.25
KB
-rw-r--r--
2025-04-09 02:56
cursor-toArray-001.phpt
1.26
KB
-rw-r--r--
2025-04-09 02:56
cursor-toArray-002.phpt
957
B
-rw-r--r--
2025-04-09 02:56
cursor_error-001.phpt
245
B
-rw-r--r--
2025-04-09 02:56
cursorid-getId-001.phpt
1.43
KB
-rw-r--r--
2025-04-09 02:56
cursorinterface-001.phpt
680
B
-rw-r--r--
2025-04-09 02:56
cursorinterface-002.phpt
227
B
-rw-r--r--
2025-04-09 02:56
cursorinterface-003.phpt
230
B
-rw-r--r--
2025-04-09 02:56
Save
Rename
--TEST-- PHPC-1050: Command cursor should not invoke getMore at execution (rewind omitted) --SKIPIF-- <?php require __DIR__ . "/../utils/basic-skipif.inc"; ?> <?php skip_if_php_version('>', '7.99'); ?> <?php skip_if_not_replica_set(); ?> <?php skip_if_not_server_storage_engine('wiredTiger'); ?> <?php skip_if_not_clean(); ?> --FILE-- <?php require_once __DIR__ . "/../utils/basic.inc"; /* Note: this test is skipped on PHP 8 because the InternalIterator class * returned by Cursor::getIterator() has logic to ensure rewind() is always * called. That causes and additional getMore to be observed when starting * iteration with next(), since rewind() and next() both trigger a getMore. * We may be able to resume running this test on PHP 8 if Cursor implements * Iterator directly and allow rewind() to be optional (see: PHPC-1691). */ class CommandLogger implements MongoDB\Driver\Monitoring\CommandSubscriber { public function commandStarted(MongoDB\Driver\Monitoring\CommandStartedEvent $event): void { if ($event->getCommandName() !== 'aggregate' && $event->getCommandName() !== 'getMore') { return; } printf("Executing command: %s\n", $event->getCommandName()); } public function commandSucceeded(MongoDB\Driver\Monitoring\CommandSucceededEvent $event): void { if ($event->getCommandName() !== 'aggregate' && $event->getCommandName() !== 'getMore') { return; } printf("Executing command took %0.6f seconds\n", $event->getDurationMicros() / 1000000); } public function commandFailed(MongoDB\Driver\Monitoring\CommandFailedEvent $event): void { } } $manager = create_test_manager(); $cmd = new MongoDB\Driver\Command( [ 'aggregate' => COLLECTION_NAME, 'pipeline' => [ ['$changeStream' => (object) []], ], 'cursor' => (object) [], ], [ 'maxAwaitTimeMS' => 500, ] ); MongoDB\Driver\Monitoring\addSubscriber(new CommandLogger); $cursor = $manager->executeReadCommand(DATABASE_NAME, $cmd); $it = new IteratorIterator($cursor); printf("Current position is valid: %s\n\n", $it->valid() ? 'yes' : 'no'); echo "Advancing cursor\n"; $it->next(); printf("Current position is valid: %s\n\n", $it->valid() ? 'yes' : 'no'); $bulk = new MongoDB\Driver\BulkWrite; $bulk->insert(['x' => 1]); $manager->executeBulkWrite(NS, $bulk); echo "Advancing cursor\n"; $it->next(); printf("Current position is valid: %s\n\n", $it->valid() ? 'yes' : 'no'); $document = $it->current(); if (isset($document)) { printf("Operation type: %s\n", $document->operationType); var_dump($document->fullDocument); } ?> ===DONE=== <?php exit(0); ?> --EXPECTF-- Executing command: aggregate Executing command took 0.%d seconds Current position is valid: no Advancing cursor Executing command: getMore Executing command took 0.%r(4|5)%r%d seconds Current position is valid: no Advancing cursor Executing command: getMore Executing command took 0.%d seconds Current position is valid: yes Operation type: insert object(stdClass)#%d (%d) { ["_id"]=> object(MongoDB\BSON\ObjectId)#%d (%d) { ["oid"]=> string(24) "%x" } ["x"]=> int(1) } ===DONE===