MONGODB-CONTEXT-OPTIONS(3) 1 MONGODB-CONTEXT-OPTIONS(3)MongoDB context options - MongoDB context option listing
Context options for mongodb:// transports.
o $log_cmd_insert
callable - A callback function called when inserting a document, see log_cmd_insert(3).
o $log_cmd_delete
callable - A callback function called when deleting a document, see log_cmd_delete(3).
o $log_cmd_update
callable - A callback function called when updating a document, see log_cmd_update(3).
o $log_write_batch
callable - A callback function called when executing a Write Batch, see log_write_batch(3).
o $log_reply
callable - A callback function called when reading a reply from MongoDB, see log_reply(3).
o $log_getmore
callable - A callback function called when retrieving more results from a MongoDB cursor, see log_getmore(3).
o $log_killcursor
callable - A callback function called executing a killcursor opcode, see log_killcursor(3).
+-----------------+----------------------------------+
| Version | |
| | |
| | Description |
| | |
+-----------------+----------------------------------+
|pecl/mongo 1.5.0 | |
| | |
| | Added Write API Context options |
| | |
+-----------------+----------------------------------+
"Socket context options", "SSL context options".
PHP Documentation Group MONGODB-CONTEXT-OPTIONS(3)
Check Out this Related Man Page
LOG_WRITE_BATCH(3) 1 LOG_WRITE_BATCH(3)log_write_batch - Callback When Writing BatchesSYNOPSIS
log_write_batch (array $server, array $writeOptions, array $batch, array $protocolOptions)
DESCRIPTION
A callable function, used by the log_write_batch context option, when executing a batch operation.
Note
This is not a real function, only a prototype of how the function should be.
PARAMETERS
o $server
- An array containing the basic information about the server that was picked.
+-----------------+---------------------------------------------------+
| key | |
| | |
| | value |
| | |
+-----------------+---------------------------------------------------+
| hash | |
| | |
| | server hash, example: localhost:27017;-;X;56052 |
| | |
| type | |
| | |
| | Node type (primary/secondary/mongos/arbiter): 2 |
| | |
| max_bson_size | |
| | |
| | The maximum BSON Size over the wire this node |
| | accepts: 16777216 |
| | |
|max_message_size | |
| | |
| | The maximum Message Size over the wire this node |
| | accepts: 48000000 |
| | |
| request_id | |
| | |
| | The request identifier for this message: 42 |
| | |
+-----------------+---------------------------------------------------+
o $writeOptions
-
+-------------+---------------------------------------------------+
| key | |
| | |
| | value |
| | |
+-------------+---------------------------------------------------+
| ordered | |
| | |
| | boolean, if the operation (in case of batch oper- |
| | ation) must be executed sequentually |
| | (ordered=true) |
| | |
|writeConcern | |
| | |
| | An array of writeConcern options (see below) |
| | |
+-------------+---------------------------------------------------+
writeConcern array values
+---------+---------------------------------------------------+
| key | |
| | |
| | value |
| | |
+---------+---------------------------------------------------+
| fsync | |
| | |
| | boolean, force flushing to disk before returning |
| | |
| j | |
| | |
| | boolean, force journal write before returning |
| | |
|wtimeout | |
| | |
| | integer, milliseconds, maximum time the primary |
| | is allowed to wait to verify replication |
| | |
| w | |
| | |
| | integer=server count, or string=replication-tag |
| | |
+---------+---------------------------------------------------+
o $batch
- Array, the actual batch operation.
o $protocolOptions
-
+---------------+---------------------------------------------------+
| key | |
| | |
| | value |
| | |
+---------------+---------------------------------------------------+
|message_length | |
| | |
| | The total size (in bytes) of the encoded message |
| | being sent over the wire |
| | |
| request_id | |
| | |
| | The request identifier for this message: 42 |
| | |
| namespace | |
| | |
| | The MongoDB namespace used for the protocol mes- |
| | sage dbname.collectionname |
| | |
+---------------+---------------------------------------------------+
CHANGELOG
+--------+--------------------------------------------------+
|Version | |
| | |
| | Description |
| | |
+--------+--------------------------------------------------+
| 1.5.0 | |
| | |
| | Only available when connected to MongoDB 2.6.0+ |
| | |
+--------+--------------------------------------------------+
PHP Documentation Group LOG_WRITE_BATCH(3)