SERVER-127347: Increase defaultFindReplicaSetHostTimeoutMS on mongos for san builds (#54044)
GitOrigin-RevId: e5aee7a23af91cf9a1ac3f47a33168a77e9f3d97
This commit is contained in:
parent
b0bcbc2c5a
commit
1551887ae9
@ -931,5 +931,12 @@ NO_HOOKS = False
|
||||
# Whether ASAN (AddressSanitizer) is enabled, determined by the presence of ASAN_OPTIONS.
|
||||
IS_ASAN = bool(os.environ.get("ASAN_OPTIONS"))
|
||||
|
||||
# Whether any sanitizer build is active (ASAN, TSAN, or UBSAN), which results in slower execution.
|
||||
IS_SAN = bool(
|
||||
os.environ.get("ASAN_OPTIONS")
|
||||
or os.environ.get("TSAN_OPTIONS")
|
||||
or os.environ.get("UBSAN_OPTIONS")
|
||||
)
|
||||
|
||||
# Skips signature verification for extensions loaded into the server. This option has no effect on release builds.
|
||||
SKIP_EXTENSIONS_SIGNATURE_VERIFICATION = False
|
||||
|
||||
@ -130,6 +130,17 @@ class ShardedClusterFixture(interface.Fixture, interface._DockerComposeInterface
|
||||
].get("maxTransactionLockRequestTimeoutMillis", 10 * 1000)
|
||||
)
|
||||
|
||||
self.mongos_options["set_parameters"] = self.fixturelib.make_historic(
|
||||
self.mongos_options.get("set_parameters", {})
|
||||
).copy()
|
||||
if _config.IS_SAN:
|
||||
# On sanitizer builds, mongos may not detect a new primary within the default 15-second
|
||||
# defaultFindReplicaSetHostTimeoutMS window due to sanitizer overhead. Increase the
|
||||
# timeout so that FailedToSatisfyReadPreference errors don't occur spuriously.
|
||||
self.mongos_options["set_parameters"].setdefault(
|
||||
"defaultFindReplicaSetHostTimeoutMS", 2 * 60 * 1000
|
||||
)
|
||||
|
||||
# Misc other options for the fixture.
|
||||
self.config_shard = config_shard
|
||||
self.preserve_dbpath = preserve_dbpath
|
||||
|
||||
Loading…
Reference in New Issue
Block a user