[SERVER-66260] Modify executor::RemoteCommand object to accept an option argument Created: 05/May/22  Updated: 29/Oct/23  Resolved: 31/May/22

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 6.1.0-rc0

Type: Bug Priority: Minor - P4
Reporter: Daniel Morilha (Inactive) Assignee: Daniel Morilha (Inactive)
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Issue split
split from SERVER-43155 Queries which exceed maxTimeMS may re... Closed
Backwards Compatibility: Fully Compatible
Operating System: ALL
Sprint: Service Arch 2022-05-16, Service Arch 2022-05-30, Service Arch 2022-06-13
Participants:
Story Points: 1

 Description   

Currently executor::RemoteCommand has an HedgeOptions argument, which is an instantiation of boost::optional and represents both a count and a max acceptable duration for hedge reads.

This ticket proposes to expand the current HedgeOptions into just generic options, and include the current HedgeOptions within.



 Comments   
Comment by Githook User [ 27/May/22 ]

Author:

{'name': 'Daniel Morilha', 'email': 'daniel.morilha@mongodb.com', 'username': 'daniel-mdb'}

Message: SERVER-66260 Modify executor::RemoteCommandRequest to accept an Options argument

Transitioning from `RemoteCommandRequestBase::HedgeOptions` into
a generic Options `struct`ure in order to accommodate new options into
requests for remote commands.

```
struct RemoteCommandRequestBase {
struct Options

{ size_t hedgeCount = 0; int maxTimeMSForHedgedReads = 0; bool isHedgeEnabled = false; bool fireAndForget = false; }

;
```

The `boost::optional` which wrapped the previous structure was deprecated in
favor of a new `isHedgeEnabled` boolean field which should be logically
equivalent. `fireAndForget` was also moved from the outer class inside.
Code and tests were appropriately adjusted.
Branch: master
https://github.com/mongodb/mongo/commit/a474d4efa5a999526e696423af5d30f4f5187613

Comment by Githook User [ 27/May/22 ]

Author:

{'name': 'Daniel Morilha', 'email': 'daniel.morilha@mongodb.com', 'username': 'daniel-mdb'}

Message: SERVER-66260 Modify executor::RemoteCommandRequest to accept an Options argument

Transitioning `RemoteCommandRequest` `fireAndForget` as another boolean
option.

Base commit message:

Transitioning from `RemoteCommandRequestBase::HedgeOptions` into
a generic Options `struct`ure in order to accommodate new options into
requests for remote commands.

```
struct RemoteCommandRequestBase {
struct Options

{ size_t hedgeCount = 0; int maxTimeMSForHedgedReads = 0; bool isHedgeEnabled = false; bool fireAndForget = false; }

;
```

The `boost::optional` which wrapped the previous structure was deprecated in
favor of a new `isHedgeEnabled` boolean field which should be logically
equivalent. `fireAndForget` was also moved from the outer class inside.
Code and tests were appropriately adjusted.
Branch: master
https://github.com/10gen/mongo-enterprise-modules/commit/f6f8746c0bb2d5f295c74de81169301b1cfd5b51

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