[SERVER-36435] Increase maxTimeMS timeout in awaitdata_getmore_cmd.js Created: 03/Aug/18  Updated: 29/Oct/23  Resolved: 11/Sep/18

Status: Closed
Project: Core Server
Component/s: Querying
Affects Version/s: 3.6.6, 4.0.0, 4.1.1
Fix Version/s: 3.4.18, 3.6.9, 4.0.3, 4.1.3

Type: Task Priority: Major - P3
Reporter: Kyle Suarez Assignee: Justin Seyster
Resolution: Fixed Votes: 0
Labels: neweng
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Depends
Problem/Incident
Backwards Compatibility: Fully Compatible
Backport Requested:
v4.0, v3.6, v3.4
Participants:
Linked BF Score: 2

 Description   

This test sets the maxTimeMS for a getMore command to be 1 minute. This is too low and should be bumped higher – if the machine running the test is slow, this assertion that the getMore returns 1 document in its batch will fail, because an empty batch will be returned (but with no error set) if the maxTimeMS is exceeded.

awaitdata_getmore_cmd.js

193
    cmdRes = db.runCommand(
194
        {getMore: cmdRes.cursor.id, collection: collName, maxTimeMS: getMoreMaxTimeMS});
195
    assert.commandWorked(cmdRes);
196
    assert.gt(cmdRes.cursor.id, NumberLong(0));
197
    assert.eq(cmdRes.cursor.ns, coll.getFullName());
198
    assert.eq(cmdRes.cursor.nextBatch.length, 1);
199
    assert.docEq(cmdRes.cursor.nextBatch[0], {_id: "match", x: 1});



 Comments   
Comment by Justin Seyster [ 15/Oct/18 ]

Note: there is a partial backport of this ticket to v3.4, but it actually doesn't include the timeout change itself. There are more details in BACKPORT-3211.

Comment by Githook User [ 15/Oct/18 ]

Author:

{'name': 'Justin Seyster', 'email': 'justin.seyster@mongodb.com', 'username': 'jseyster'}

Message: SERVER-36435 Remove kReplDefaultTimeoutMS.

Tests should, generally, not be accessing global const values like
kReplDefaultTimeoutMS. This change removes that const.
Branch: v3.4
https://github.com/mongodb/mongo/commit/ff390f3b6fad40301d13ebb001d2f0a3caeca696

Comment by Githook User [ 18/Sep/18 ]

Author:

{'name': 'Justin Seyster', 'email': 'justin.seyster@mongodb.com', 'username': 'jseyster'}

Message: SERVER-36435 Make ReplSetTest.kDefaultTimeoutMS accessible everywhere.

Tests should, generally, not be accessing global const values like
kReplDefaultTimeoutMS. This change removes that const and fixes the
detect_spawning_own_mongod.js override so that it no longer overwrites
ReplSetTest.kDefaultTimeoutMS, making it accessible to jstests that do
not operate on replica sets.

(cherry picked from commit eebc418c225b949e60927551451a8277115e8da6)
Branch: v3.6
https://github.com/mongodb/mongo/commit/59df41ca616c2d701af16fc38796a98599ba3ddb

Comment by Githook User [ 18/Sep/18 ]

Author:

{'name': 'Justin Seyster', 'email': 'justin.seyster@mongodb.com', 'username': 'jseyster'}

Message: SERVER-36435 Increase maxTimeMS timeout in awaitdata_getmore_cmd.js.

(cherry picked from commit 614477159b98497d6372f31ea8d918ca39259ccf)
Branch: v3.6
https://github.com/mongodb/mongo/commit/1fc1f6c87b82b69a49de52daf218762ebc80a1b6

Comment by Githook User [ 11/Sep/18 ]

Author:

{'name': 'Justin Seyster', 'email': 'justin.seyster@mongodb.com', 'username': 'jseyster'}

Message: SERVER-36435 Make ReplSetTest.kDefaultTimeoutMS accessible everywhere.

Tests should, generally, not be accessing global const values like
kReplDefaultTimeoutMS. This change removes that const and fixes the
detect_spawning_own_mongod.js override so that it no longer overwrites
ReplSetTest.kDefaultTimeoutMS, making it accessible to jstests that do
not operate on replica sets.

(cherry picked from commit eebc418c225b949e60927551451a8277115e8da6)
Branch: v4.0
https://github.com/mongodb/mongo/commit/0f1ddc60647a7eacefde5c80ff73a4d41f8c7b11

Comment by Githook User [ 11/Sep/18 ]

Author:

{'name': 'Justin Seyster', 'email': 'justin.seyster@mongodb.com', 'username': 'jseyster'}

Message: SERVER-36435 Make ReplSetTest.kDefaultTimeoutMS accessible everywhere.

Tests should, generally, not be accessing global const values like
kReplDefaultTimeoutMS. This change removes that const and fixes the
detect_spawning_own_mongod.js override so that it no longer overwrites
ReplSetTest.kDefaultTimeoutMS, making it accessible to jstests that do
not operate on replica sets.
Branch: master
https://github.com/mongodb/mongo/commit/eebc418c225b949e60927551451a8277115e8da6

Comment by Githook User [ 07/Sep/18 ]

Author:

{'name': 'Justin Seyster', 'email': 'justin.seyster@mongodb.com', 'username': 'jseyster'}

Message: SERVER-36435 Increase maxTimeMS timeout in awaitdata_getmore_cmd.js.

(cherry picked from commit 614477159b98497d6372f31ea8d918ca39259ccf)
Branch: v4.0
https://github.com/mongodb/mongo/commit/1c72efff0b1e6107943e4f0b4550be189c69e681

Comment by Githook User [ 07/Sep/18 ]

Author:

{'name': 'Justin Seyster', 'email': 'justin.seyster@mongodb.com', 'username': 'jseyster'}

Message: SERVER-36435 Increase maxTimeMS timeout in awaitdata_getmore_cmd.js.
Branch: master
https://github.com/mongodb/mongo/commit/614477159b98497d6372f31ea8d918ca39259ccf

Generated at Thu Feb 08 04:43:05 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.