-
Notifications
You must be signed in to change notification settings - Fork 3
Open
Labels
code healthImprove code readability, simplify maintenance and so onImprove code readability, simplify maintenance and so on
Description
In #57 we started allowing an empty rsName to simplify logic in ETCD provider.
Later, we discussed and decided to keep the core code as simple as possible for maintainability reasons.
Therefore, we should remove supporting empty rsName in RemoveInstance and move the code complexity to an external provider for ETCD.
Lines 93 to 105 in 09267a9
if rsName == "" { | |
r.log().Debugf(ctx, "Replicaset name is not provided for instance %s, attempting to find it", | |
instanceName) | |
for _, trs := range nameToReplicasetRef { | |
_, exists := trs.conn.GetInfo()[instanceName] | |
if exists { | |
r.log().Debugf(ctx, "Replicaset found for instance %s, removing it", instanceName) | |
rs = trs | |
} | |
} | |
} else { |
Metadata
Metadata
Assignees
Labels
code healthImprove code readability, simplify maintenance and so onImprove code readability, simplify maintenance and so on