mirror of
https://github.com/prometheus/prometheus.git
synced 2024-12-27 14:39:40 -08:00
Use fingerprint for target identity comparison
So far we were using the InstanceIdentifier to compare equality of targets. This is not always accurate, for example for the blackbox exporter where the actual target is in the parameter.
This commit is contained in:
parent
c24c5e6fb3
commit
825831e98f
|
@ -265,7 +265,7 @@ func (tm *TargetManager) updateTargetGroup(tgroup *config.TargetGroup, cfg *conf
|
|||
if told == nil {
|
||||
continue
|
||||
}
|
||||
if tnew.InstanceIdentifier() == told.InstanceIdentifier() {
|
||||
if tnew.fingerprint() == told.fingerprint() {
|
||||
match = told
|
||||
oldTargets[j] = nil
|
||||
break
|
||||
|
|
Loading…
Reference in a new issue