Skip to content
This repository was archived by the owner on Feb 18, 2025. It is now read-only.

Commit 6ecf21c

Browse files
author
Philipp Heckel
committed
Revert "Add WaitForSemiSyncRecoverySeconds config option"
This reverts commit 5382128.
1 parent ec7aab6 commit 6ecf21c

File tree

2 files changed

+2
-7
lines changed

2 files changed

+2
-7
lines changed

go/config/config.go

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -277,8 +277,7 @@ type Configuration struct {
277277
MaxConcurrentReplicaOperations int // Maximum number of concurrent operations on replicas
278278
EnforceExactSemiSyncReplicas bool // If true, semi-sync replicas will be enabled/disabled to match the wait count in the desired priority order; this applies to LockedSemiSyncMaster and MasterWithTooManySemiSyncReplicas
279279
RecoverLockedSemiSyncMaster bool // If true, orchestrator will recover from a LockedSemiSync state by enabling semi-sync on replicas to match the wait count; this behavior can be overridden by EnforceExactSemiSyncReplicas
280-
ReasonableLockedSemiSyncMasterSeconds uint // Time to evaluate the LockedSemiSyncHypothesis before triggering the LockedSemiSyncMaster analysis; defaults to ReasonableReplicationLagSeconds if not set
281-
WaitForSemiSyncRecoverySeconds uint // Time to wait for a successful recovery of LockedSemiSyncMaster or MasterWithTooManySemiSyncReplicas before considering the recovery failed; defaults to InstancePollSeconds * 3 if not set
280+
ReasonableLockedSemiSyncMasterSeconds uint // Time to evaluate the LockedSemiSyncHypothesis before triggering the LockedSemiSync analysis; falls back to ReasonableReplicationLagSeconds if not set
282281
}
283282

284283
// ToJSONString will marshal this configuration as JSON
@@ -453,7 +452,6 @@ func newConfiguration() *Configuration {
453452
EnforceExactSemiSyncReplicas: false,
454453
RecoverLockedSemiSyncMaster: false,
455454
ReasonableLockedSemiSyncMasterSeconds: 0,
456-
WaitForSemiSyncRecoverySeconds: 0,
457455
}
458456
}
459457

@@ -619,9 +617,6 @@ func (this *Configuration) postReadAdjustments() error {
619617
if this.ReasonableLockedSemiSyncMasterSeconds == 0 {
620618
this.ReasonableLockedSemiSyncMasterSeconds = uint(this.ReasonableReplicationLagSeconds)
621619
}
622-
if this.WaitForSemiSyncRecoverySeconds == 0 {
623-
this.WaitForSemiSyncRecoverySeconds = this.InstancePollSeconds * 3
624-
}
625620

626621
return nil
627622
}

go/logic/topology_recovery.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1548,7 +1548,7 @@ func recoverSemiSyncReplicas(topologyRecovery *TopologyRecovery, analysisEntry i
15481548
// Wait for replica count to match desired wait count (this is what triggers the recovery)
15491549
AuditTopologyRecovery(topologyRecovery, "semi-sync: waiting for desired state:")
15501550
success := false
1551-
for i := uint(0); i < config.Config.WaitForSemiSyncRecoverySeconds; i++ {
1551+
for i := 0; i < 10; i++ {
15521552
masterInstance, err = inst.ReadTopologyInstance(&analysisEntry.AnalyzedInstanceKey)
15531553
if err != nil {
15541554
return true, topologyRecovery, fmt.Errorf("error re-reading master instance: %s", err.Error())

0 commit comments

Comments
 (0)