You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: test/spec/connection-monitoring-and-pooling/cmap-format/pool-checkout-returned-connection-maxConnecting.json
Copy file name to clipboardExpand all lines: test/spec/connection-monitoring-and-pooling/cmap-format/pool-checkout-returned-connection-maxConnecting.yml
+10-12
Original file line number
Diff line number
Diff line change
@@ -15,6 +15,7 @@ failPoint:
15
15
blockConnection: true
16
16
blockTimeMS: 750
17
17
poolOptions:
18
+
maxConnecting: 2
18
19
maxPoolSize: 10
19
20
waitQueueTimeoutMS: 5000
20
21
operations:
@@ -45,14 +46,13 @@ operations:
45
46
count: 4
46
47
- name: wait
47
48
ms: 100
48
-
# check original connection back in, so the thread that isn't
49
-
# currently establishing will become unblocked. Then wait for
50
-
# all threads to complete.
49
+
# Check original connection back in, so one of the waiting threads can check
50
+
# out the idle connection before the two new connections are ready.
51
51
- name: checkIn
52
52
connection: conn0
53
-
- name: waitForEvent
54
-
event: ConnectionCheckedOut
55
-
count: 4
53
+
# Wait for 100ms to let one of the blocked checkOut operations complete.
54
+
- name: wait
55
+
ms: 100
56
56
events:
57
57
# main thread checking out a Connection and holding it
58
58
- type: ConnectionCreated
@@ -69,15 +69,13 @@ events:
69
69
- type: ConnectionCheckedIn
70
70
connectionId: 1
71
71
address: 42
72
-
# remaining thread checking out the returned Connection
72
+
# Another thread checks out the returned Connection before the two new
73
+
# connections are checked out.
73
74
- type: ConnectionCheckedOut
74
75
connectionId: 1
75
76
address: 42
76
-
# first two threads finishing Connection establishment
77
-
- type: ConnectionCheckedOut
78
-
address: 42
79
-
- type: ConnectionCheckedOut
80
-
address: 42
77
+
# Events after this can come in different orders but still be valid.
0 commit comments