Recommend this page to a friend! |
Classes of LAGGOUNE Walid | MongoDB Queue PHP Query Execute | README.md | Download |
|
Downloadmongodb-php-concurrencyConcurrency PHP library for MongoDB Requirements
// select from test1 for 5 seconds with no options array (options is the filter array in : https://docs.mongodb.com/php-library/v1.2/reference/method/MongoDBCollection-findOne/#phpmethod.MongoDB\Collection::findOne) $m->selectFrom("test1", [], 5, function(iterable $results) {
}); // insert in to test2 array textData for 1 second $m->insertTo("test2", $textData, 1, function() {
}); // update from test2 where name = john to name = alex for 6 seconds $m->updateFrom("test2", ["name" => "john"], ["name" => "alex"], 6, function(int $modified) {
}); // delete from test2 where name = john for 5 seconds $m->deleteFrom("test2", ["name" => "john"], 5, function(int $intDataeleted) {
}); $m->run();
|