Commit Graph

98 Commits

Author SHA1 Message Date
Shane Harvey
890cd26e1a
PYTHON-3288 Implement client side operation timeout (#954)
Add timeoutMS URI option and MongoClient keyword argument.
Add provisional/beta pymongo.timeout() api to set a deadline for a block of operations.
2022-06-06 15:36:52 -04:00
Steven Silvester
b3604a81d3
PYTHON-3171 Add usage of NoReturn annotation (#901) 2022-03-16 15:26:10 -05:00
Julius Park
52ff8c2e90
PYTHON-3068 Support 'let' option in BulkWriteOptions (#874) 2022-02-18 10:43:56 -08:00
Steven Silvester
a0fe7c03af
PYTHON-3120 Set up flake8 linting (#868) 2022-02-17 06:44:08 -06:00
Julius Park
ddb6614442
PYTHON-2682 Add support for the comment field to all helpers (#847) 2022-02-09 15:12:02 -08:00
Steven Silvester
5578999a90
PYTHON-1834 Use a code formatter (#852) 2022-02-09 06:44:28 -06:00
Steven Silvester
dd6c140d43
PYTHON-3060 Add typings to pymongo package (#831) 2022-02-02 21:12:36 -06:00
Steven Silvester
f074cfb696
PYTHON-2863 Allow hint for unacknowledged writes using OP_MSG when supported by the server (#830) 2022-01-20 08:18:13 -06:00
Shane Harvey
2af521ec03
PYTHON-2984 Fix retry behavior for bulk write writeConcernError (#800) 2021-11-19 12:15:23 -08:00
Shane Harvey
7467aa634d
PYTHON-2915 Fix bug when starting a transaction with a large bulk write (#743) 2021-09-24 15:47:37 -07:00
Shane Harvey
11752ed594
PYTHON-2899 Remove code for MongoDB <= 3.4 (#729)
Remove unneeded memoryview to bytes conversion.
2021-09-16 16:53:50 -07:00
Shane Harvey
69dee51b90
PYTHON-1318 Remove initialize_unordered_bulk_op and initialize_ordered_bulk_op (#692)
PYTHON-2436 Unskip test_large_inserts_ordered on MongoDB 5.0.
2021-08-05 17:58:15 -07:00
Shane Harvey
4152600ae6
PYTHON-2777 Raise client side error for snapshot reads on <5.0 (#659) 2021-06-29 14:40:48 -07:00
Shane Harvey
7c1060cfec
PYTHON-1307 Remove SONManipulator APIs (#557) 2021-01-25 16:22:00 -08:00
Bernie Hackett
e17299ab2e PYTHON-2133 Remove u prefixes from code 2021-01-20 16:10:23 -08:00
Prashant Mital
b65fdf3f51
PYTHON-2142 Add index hinting support to delete operations 2020-03-26 16:01:33 -07:00
Prashant Mital
1323ef15cb
PYTHON-2036 Expand CRUD API support for index hinting (also PYTHON-2015, PYTHON-2104, PYTHON-2134) 2020-02-25 19:22:25 -08:00
Shane Harvey
7d76ee2276 PYTHON-1884 Support auto encryption in bulk write
Close KMS sockets.
Call pymongocrypt's init method.
2019-08-06 14:54:23 -07:00
Shane Harvey
e64945101b PYTHON-1684 Support sharded transactions recovery token (#406)
Transient errors inside transaction unpins the session.
Add brief docs about sharded transactions and add 3.9 changelog.
Tests changes:
Add spec tests for sharded transaction recoveryToken.
Speed up txn tests by reducing SDAM waiting time after a network error.
Remove outdated test workaround for killAllSessions.
2019-02-27 15:59:18 -08:00
Shane Harvey
6bab444bd7 PYTHON-1673 Mongos pinning for sharded transactions
In a sharded transaction, a session is pinned to the mongos server
selected for the initial command. All subsequent commands in the same
transaction are routed to the pinned mongos server.
2019-02-27 15:56:48 -08:00
Shane Harvey
6fe00109c1 PYTHON-1650 Always increment txnNumber before starting a retryable write 2018-10-08 11:42:02 -07:00
Shane Harvey
4f3b6467ab PYTHON-1598 Fix transaction write concern inheritance 2018-06-26 12:07:12 -04:00
Shane Harvey
98e77ba1d2 PYTHON-1483 Prohibit unack'ed writes with explicit sessions 2018-06-25 13:55:50 -05:00
Bernie Hackett
4a9c65eb22 PYTHON-1329 - OP_MSG unacknowledged bulk writes 2018-06-22 22:00:07 -07:00
Bernie Hackett
4d786fd0cd PYTHON-1329 - OP_MSG bulk writes 2018-06-21 16:03:20 -07:00
Shane Harvey
622d33d0cb PYTHON-1545 Support for retryable writeConcernErrors
Return proper BulkWriteResult after a retryable write succeeds.
Reduce retryable writes test suite time from 90 to 30 seconds by
reducing the heartbeat interval.
2018-06-14 09:51:08 -07:00
Bernie Hackett
dbf386c18c PYTHON-1527 - Fix default writeConcern override 2018-06-04 13:56:06 -07:00
Bernie Hackett
335cb97a34 PYTHON-1278, PYTHON-1553 - Support OP_COMPRESSED 2018-05-22 11:44:21 -07:00
Shane Harvey
7aeec7b56b PYTHON-1508 Remove stmtId from transaction commands
The statement identifier is no longer required by the server.
2018-04-25 16:04:13 -07:00
Shane Harvey
a2937aa8eb Revert "Pin transactions to a single server address"
This reverts commit 25bc0858ff566abfabadeca4a3fea177e9c2697c.
2018-04-16 09:57:45 -04:00
Shane Harvey
656aa1e703 Pin transactions to a single server address 2018-04-16 09:57:45 -04:00
Shane Harvey
cd92850b36 Test changing transaction readPreference
Add original readPreference to getMores to simplify code check.
2018-04-16 09:57:45 -04:00
A. Jesse Jiryu Davis
9df87b6401 prototype transaction tests 2018-04-16 09:57:45 -04:00
Bernie Hackett
507f954ed4 Update copyright dates 2017-12-01 17:23:39 -08:00
Shane Harvey
2a05236f61 PYTHON-1332 Only gossip cluster time on >= 3.6.
Do not add readConcern to explain.
Test explain with collation.
2017-11-30 14:53:14 -08:00
Shane Harvey
47302096f9 PYTHON-1339 Retryable multi-statement writes.
MongoClient with retryWrites=true works when the cluster does not support retryable writes.
2017-11-20 12:18:00 -08:00
Shane Harvey
b669cd86dc PYTHON-1332 Session may only be used by the client that started it.
Centralize $clusterTime receiving.
2017-11-17 09:27:21 -08:00
Bernie Hackett
4eda4ffaec PYTHON-1340 - Implement causally consistent reads 2017-11-09 17:16:55 -08:00
Shane Harvey
6a5856a608 PYTHON-1299 Remove unused MongoDB 2.4 bulk result code. 2017-11-08 10:59:36 -08:00
Shane Harvey
280efd2d72 PYTHON-1339 Generate a single message in _do_batched_write_command.
Ordered op_insert should check for errors on the last insert.
Use _Bulk API for Collection.insert.
Avoid sending acknowledged inserts as much as possible.
max_cmd_size already accounts for trailing null bytes.
2017-10-31 16:59:26 -04:00
A. Jesse Jiryu Davis
df018e88e2 PYTHON-1332 - Gossip $clusterTime 2017-10-12 09:08:38 -04:00
A. Jesse Jiryu Davis
dad61a058b PYTHON-1332 - Update session's last_use 2017-10-05 15:03:36 -04:00
A. Jesse Jiryu Davis
41096d5875 PYTHON-1332 - Check current user owns session 2017-10-02 12:05:11 -04:00
Shane Harvey
715cb0d27c PYTHON-1299 Remove acknowledged legacy writes.
Ordered unacknowledged bulk writes still use legacy writes and getLastError.
2017-09-29 12:09:24 -07:00
A. Jesse Jiryu Davis
c1ec855060 PYTHON-1332 - Send lsid with all commands 2017-09-29 14:52:26 -04:00
A. Jesse Jiryu Davis
2487e9b71f PYTHON-1332 - Session param for Collection methods 2017-09-11 17:46:44 -04:00
Shane Harvey
14ce90906c PYTHON-1296 Support array_filters updates.
Sync crud tests.
2017-09-08 12:23:40 -07:00
Shane Harvey
e89ed11113 PYTHON-1317 Deprecate legacy bulk write api.
Use Collection.bulk_write() in documentation examples.
Move deprecated bulk tests to test_legacy_api.
2017-08-04 21:41:29 -07:00
Shane Harvey
8eb1aefeff PYTHON-1336 Add collation support to Collection.bulk_write. 2017-08-03 15:21:04 -07:00
Luke Lovett
0fbdf85f53 PYTHON-1113 - Index collation documentation into API docs. 2016-09-07 15:15:15 -07:00