mirror of
https://github.com/open-cluster-management-io/ocm.git
synced 2026-05-23 17:43:25 +00:00
Avoid frequent CSR creation (#277)
* Avoid frequent CSR creation Signed-off-by: Jian Qiu <jqiu@redhat.com> * Add todo for threshold value Signed-off-by: Jian Qiu <jqiu@redhat.com> Signed-off-by: Jian Qiu <jqiu@redhat.com>
This commit is contained in:
@@ -186,8 +186,9 @@ func TestSync(t *testing.T) {
|
||||
ObjectMeta: metav1.ObjectMeta{
|
||||
GenerateName: "test-",
|
||||
},
|
||||
Subject: testSubject,
|
||||
SignerName: certificates.KubeAPIServerClientSignerName,
|
||||
Subject: testSubject,
|
||||
SignerName: certificates.KubeAPIServerClientSignerName,
|
||||
HaltCSRCreation: func() bool { return false },
|
||||
}
|
||||
|
||||
updater := &fakeStatusUpdater{}
|
||||
@@ -230,7 +231,7 @@ func TestSync(t *testing.T) {
|
||||
}
|
||||
}
|
||||
|
||||
var _ csrControl = &mockCSRControl{}
|
||||
var _ CSRControl = &mockCSRControl{}
|
||||
|
||||
func conditionEqual(expected, actual *metav1.Condition) bool {
|
||||
if expected == nil && actual == nil {
|
||||
@@ -301,6 +302,6 @@ func (m *mockCSRControl) getIssuedCertificate(name string) ([]byte, error) {
|
||||
return m.issuedCertData, err
|
||||
}
|
||||
|
||||
func (m *mockCSRControl) informer() cache.SharedIndexInformer {
|
||||
func (m *mockCSRControl) Informer() cache.SharedIndexInformer {
|
||||
panic("implement me")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user