Remove fired event when a certificate request is re-scheduled when
failed but < 1 hour Signed-off-by: JoshVanL <vleeuwenjoshua@gmail.com>
This commit is contained in:
parent
eed1e4ba21
commit
f1e4e2b16c
@ -554,9 +554,8 @@ func (c *certificateRequestManager) processCertificate(ctx context.Context, crt
|
||||
return nil
|
||||
}
|
||||
|
||||
// We don't fire an event here as this could be called multiple times in quick succession
|
||||
c.scheduledWorkQueue.Add(key, time.Hour)
|
||||
|
||||
c.recorder.Eventf(crt, corev1.EventTypeNormal, "CertificateRequestReschedule", "The CertificateRequest %q has failed and is scheduled for a retry in 1 hour", existingReq.Name)
|
||||
return nil
|
||||
}
|
||||
|
||||
|
||||
@ -1128,7 +1128,8 @@ func TestProcessCertificate(t *testing.T) {
|
||||
})),
|
||||
},
|
||||
ExpectedActions: []testpkg.Action{},
|
||||
ExpectedEvents: []string{`Normal CertificateRequestReschedule The CertificateRequest "test-850937773" has failed and is scheduled for a retry in 1 hour`},
|
||||
// We don't fire an event here as this could be called multiple times in quick succession
|
||||
ExpectedEvents: []string{},
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user