Commit Graph

4559 Commits

Author SHA1 Message Date
Shane Harvey
9fa94db01a
BUMP 3.11 (#476) 2020-07-30 13:24:44 -07:00
Shane Harvey
c99254fe97
PYTHON-2334 Add regression test for gevent.Timeout compatibility (#475)
Use with statement in Semaphore.release.
2020-07-29 18:05:18 -07:00
TylerWilley
83578dc35f
PYTHON-2334: Fix gevent.Timeout race condition (#472)
If gevent raises a Timeout during self.lock acquisition, a _socket_semaphore count will be lost.
Using "with" will release the condition even on exception being raised.
2020-07-29 16:17:38 -07:00
Prashant Mital
ff327b3e31
PYTHON-2252 Add examples and documentation for new UUID behavior (#467) 2020-07-29 14:46:48 -07:00
Prashant Mital
de1e29305c
PYTHON-2219 Document hidden index option (#474) 2020-07-29 11:26:50 -07:00
Shane Harvey
c92150d177
PYTHON-1631 Automate release wheels for Windows and manylinux (#473) 2020-07-27 17:20:43 -07:00
Shane Harvey
b04e3343cb
PYTHON-2328 Reset the connection pool in Topology.on_change (#470)
PYTHON-2304 Ensure _RttMonitor closes socket on when the client is closed
2020-07-27 13:27:05 -07:00
Shane Harvey
c16b5b95a1
PYTHON-2331 Fix set_memory_error complier warning (#469)
bson/buffer.c:36:13: warning: function declaration isn’t a prototype [-Wstrict-prototypes]
   36 | static void set_memory_error() {
      |             ^~~~~~~~~~~~~~~~
2020-07-27 11:27:08 -07:00
Shane Harvey
7a539f227a
PYTHON-2294 Resync SDAM spec tests to workaround slow elections Windows and macOS (#468)
PYTHON-2296 Test behavior of connectTimeoutMS=0 with streaming protocol
PYTHON-2311 Workaround inherent race in flaky streaming protocol test
2020-07-22 11:49:57 -07:00
Prashant Mital
98f8470b5b
PYTHON-2306 Test that change streams don't resume from ElectionInProgress (#465) 2020-07-16 18:18:19 -07:00
Prashant Mital
9b69338ef4
BUMP 3.11.0rc1.dev0 2020-07-15 11:07:23 -07:00
Prashant Mital
63574b9360
BUMP 3.11.0rc0 2020-07-15 11:03:59 -07:00
Shane Harvey
b6bf4f0157
PYTHON-2320 Use select instead of poll on Jython (#466) 2020-07-15 08:55:42 -07:00
Prashant Mital
05267fb465
PYTHON-2315 Special case resuming change streams from CursorNotFound errors (#463) 2020-07-13 11:03:29 -07:00
Prashant Mital
f24e165336
PYTHON-2263 Respect UuidRepresentation.UNSPECIFIED when parsing $uuid fields in extended JSON (#464) 2020-07-13 11:03:02 -07:00
Julius Park
f80c82453b
PYTHON-2076: Add example event loggers (#449)
Added example event loggers and documentation for them to make it easier for users to start using listeners in their code.
JIRA ticket: https://jira.mongodb.org/browse/PYTHON-2076
2020-07-09 21:32:25 -04:00
Shane Harvey
64f77068e1
PYTHON-1438 Mark a server unknown when connection handshake fails with a network timeout error (#461) 2020-07-08 17:46:07 -07:00
Shane Harvey
3c1dd61ae9
PYTHON-2256 Document that a ClientSession cannot be used for multiple operations concurrently (#460) 2020-07-08 17:40:02 -07:00
Shane Harvey
e3f40c30ad
PYTHON-2165 Deprecate MongoClient is_locked, fsync, and unlock helpers (#459) 2020-07-08 17:18:02 -07:00
Prashant Mital
426f5fdef7
PYTHON-2292 Fix failing doctest due to UuidRepresentation (#458)
PYTHON-2277 Remove UuidRepresentation DeprecationWarning
2020-07-08 15:45:25 -07:00
Prashant Mital
065001ef2e
PYTHON-2305 Cache postBatchResumeToken when an aggregate command returns an empty firstBatch (#456) 2020-07-08 14:51:17 -07:00
Shane Harvey
1c29c1a65e
PYTHON-2299 Add the "awaited" field to heartbeat events (#457) 2020-07-08 14:02:34 -07:00
Shane Harvey
5d92b2f552
PYTHON-2243 Raise informative error message when attempting a GridFS operation in a transaction (#454) 2020-07-07 18:55:17 -07:00
Shane Harvey
7e2790cc44
PYTHON-2220 Mention Atlas Search in documentation (#455) 2020-07-07 16:16:21 -07:00
Shane Harvey
a1de506b7e
PYTHON-2282 Resync maxStalenessSeconds spec tests (#452) 2020-07-07 15:17:23 -07:00
Shane Harvey
c2d6343110
PYTHON-2163 Suppress ragged EOFs when using pyOpenSSL to match the stdlib (#453)
Wrap pyOpenSSL connection errors with AutoReconnect.
2020-07-02 14:17:20 -07:00
Julius Park
a075eb798f
PYTHON-1787: fix NotMasterError no attribute error (#450) 2020-07-02 13:53:08 -04:00
Shane Harvey
4457714d1b
PYTHON-2082 Unpin session after RetryableWriteErrors from commitTransaction (#451)
PYTHON-2154 PYTHON-2189 Remove 4.5 transaction test workarounds
2020-07-01 18:32:58 -07:00
Prashant Mital
26913ea8e1
PYTHON-2143 Use an allow-list to determine resumable change stream errors (#445) 2020-07-01 18:12:05 -07:00
Prashant Mital
04926c6ccd
fix monitor failure 2020-07-01 17:52:35 -07:00
Prashant Mital
e23d019f9e
remove unnecessary changes 2020-07-01 17:24:41 -07:00
Prashant Mital
d97a43ea9b
cleanup 2020-07-01 16:58:56 -07:00
Prashant Mital
8e3fd0040e
cruft removal 2 2020-07-01 16:49:36 -07:00
Prashant Mital
dd23624100
handle None case 2020-07-01 16:47:36 -07:00
Prashant Mital
14cecab393
cleanup cruft 2020-07-01 16:47:36 -07:00
Prashant Mital
956ce3d4b0
Incorporate review changes 2020-07-01 16:47:33 -07:00
Prashant Mital
9fc7ed1e11
PYTHON-2143 Use an allow-list to determine resumable change stream errors 2020-07-01 16:43:27 -07:00
Shane Harvey
1f4123e4bf PYTHON-2123 Streaming heartbeat protocol
MongoClient now requires 2 connections and 2 threads to each MongoDB 4.4+ server.
With one connection, the server streams (or pushes) updated heartbeat info.
With the other connection, the client periodically pings the server to
establish an accurate round-trip time (RTT). This change optimizes the
discovery of server state changes such as replica set elections.

Additional changes:
- Mark server Unknown before retrying isMaster check.
- Always reset the pool _after_ marking the server unknown.
- Configure fail point before creating the client in test SpecRunner.
- Unfreeze with replSetFreeze:0 to ensure a speedy elections in test suite.
2020-07-01 14:49:46 -07:00
Prashant Mital
0b375a2604
PYTHON-2295 MongoClient with multiple hosts directConnection=True should raise an error (#446) 2020-07-01 10:53:52 -07:00
Shane Harvey
bfd297f1ea PYTHON-2271 Add MongoDB 4.0, 4.2, 4.4 to perf benchmark 2020-07-01 10:48:45 -07:00
Julius Park
67a23429ba
PYTHON-1787: add details to OperationFailure exception and NotMasterError (#448)
PYTHON-1787-add details to OperationFailure and NotMasterError by adding a __repr__ function

https://jira.mongodb.org/browse/PYTHON-1787
2020-06-30 12:30:28 -04:00
Shane Harvey
58aaede0fe PYTHON-2281 Properly reduce keep alive time on Windows 2020-06-25 15:31:33 -07:00
Julius Park
815c924bc3
PYTHON-2136: added more diagnostic information for ServerSelectionTimeoutError (#444)
* PYTHON-2136: added more diagnostic information for ServerSelectionTimeoutError

* made error message more human readable

* fixed tests

* fixed remaining testcase

* fixed formatting

* more formatting fixes
2020-06-25 17:04:04 -04:00
Bernie Hackett
e608ff4166 PYTHON-2192 - Use krb5's canonicalization algorithm 2020-06-25 11:26:14 -07:00
Shane Harvey
a90f80436c PYTHON-2103 Test that GridFS supports indexes created in the shell 2020-06-24 11:34:27 -07:00
Shane Harvey
e07366a4ad PYTHON-2255 Reduce default keepalive time to 120 seconds to align with Azure defaults 2020-06-24 10:59:34 -07:00
Shane Harvey
18de676657
PYTHON-2297 Close connection to avoid resource warning when auth fails (#443) 2020-06-24 09:56:56 -07:00
Shane Harvey
84fd04ec6d
PYTHON-1852 Use TLS option names in test suite ClientContext (#442) 2020-06-18 18:24:08 -07:00
Prashant Mital
74202455aa
PYTHON-2278 Fix Jython SDAM test failures 2020-06-16 15:55:21 -07:00
Shane Harvey
70fb1cce95 PYTHON-2293 Fix OCSP test script for Windows 2020-06-16 15:39:06 -07:00