Skip to content

Commit e76ea21

Browse files
authored
Remove overly verbose ShouldNotCreatePolicy when linkerd is enabled but enforcement is disabled (#582)
1 parent ee91ac2 commit e76ea21

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/operator/controllers/linkerd/linkerd_manager.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,6 @@ const (
3535
ReasonCreatedLinkerdServer = "CreatedLinkerdServer"
3636
ReasonCreatedLinkerdAuthPolicy = "CreatedLinkerdAuthorizationPolicy"
3737
ReasonNamespaceNotAllowed = "NamespaceNotAllowed"
38-
ReasonShouldNotCreatePolicy = "ShouldNotCreatePolicy"
3938
ReasonNotPartOfLinkerdMesh = "NotPartOfLinkerdMesh"
4039
FullServiceAccountName = "%s.%s.serviceaccount.identity.linkerd.cluster.local"
4140
NetworkAuthenticationNameTemplate = "network-auth-for-probe-routes"
@@ -187,8 +186,7 @@ func (ldm *LinkerdManager) CreateResources(ctx context.Context, ep effectivepoli
187186
}
188187

189188
if !shouldCreateLinkerdResources {
190-
ep.ClientIntentsEventRecorder.RecordWarningEvent(ReasonShouldNotCreatePolicy, fmt.Sprintf("Enforcement is disabled globally and server is not explicitly protected, skipping linkerd policy creation for server %s in namespace %s", target.GetTargetServerName(), target.GetTargetServerNamespace(clientNamespace)))
191-
logrus.Warningf("Enforcement is disabled globally and server is not explicitly protected, skipping linkerd policy creation for server %s in namespace %s", target.GetTargetServerName(), target.GetTargetServerNamespace(clientNamespace))
189+
logrus.Debugf("Enforcement is disabled globally and server is not explicitly protected, skipping linkerd policy creation for server %s in namespace %s", target.GetTargetServerName(), target.GetTargetServerNamespace(clientNamespace))
192190
continue
193191
}
194192

0 commit comments

Comments
 (0)