[DOCS-10329] Inaccurate documentation for getMore maxTimeMS option Created: 30/May/17 Updated: 30/Oct/23 Resolved: 18/Jul/23 |
|
| Status: | Closed |
| Project: | Documentation |
| Component/s: | manual, Server |
| Affects Version/s: | None |
| Fix Version/s: | Server_Docs_20231030 |
| Type: | Task | Priority: | Major - P3 |
| Reporter: | Jeremy Mikola | Assignee: | Cory Bullinger |
| Resolution: | Done | Votes: | 0 |
| Labels: | reopened, server-docs-bug-bash, triage | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||
| Participants: | |||||||||||||
| Days since reply: | 1 year, 14 weeks, 1 day ago | ||||||||||||
| Description |
|
Documentation for the getMore command's maxTimeMS option states:
This option corresponds to the maxAwaitTimeMS option in drivers (see: I believe the second sentence is incorrect. If the driver has not specified the awaitData option for a tailable cursor, then a getMore should return immediately. If awaitData has been specified, then the server waits for a predefined amount (3.4 waits for one second according to my testing). Saying "operations will not time out" implies that the getMore may not return at all until there is new data to return, as does "default unbounded behavior" in the last sentence. AFAIK, specifying zero for maxTimeMS is equivalent to not providing the option at all, which would have the server's default timeout kick in. In the C driver, there is logic to avoid setting maxTimeMS on getMore if the user supplied a value of zero. I expect other drivers do the same. |
| Comments |
| Comment by Sarah Olson [ 01/Nov/22 ] |
|
Thanks jmikola@mongodb.com. Appreciate the update. |
| Comment by Jeremy Mikola [ 01/Nov/22 ] |
|
The original text I cited in the OP is still in the current documentation. This still seems relevant. |
| Comment by Education Bot [ 31/Oct/22 ] |
|
Hello! This ticket has been closed due to inactivity. If you believe this ticket is still important, please reopen it and leave a comment to explain why. Thank you! |
| Comment by David Storch [ 31/May/17 ] |
|
jmikola, your comment looks accurate. One other thing I'd like to point out is that maxTimeMS is not allowed on a getMore unless the getMore is issued against an awaitData cursor. |
| Comment by Jeremy Mikola [ 30/May/17 ] |
|
david.storch: Can you fact-check my comments in the OP? |