Skip to content

Commit

Permalink
skip already disabled sources (#476)
Browse files Browse the repository at this point in the history
  • Loading branch information
edeNFed authored Sep 12, 2023
1 parent acf1ec5 commit ab6de38
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions frontend/endpoints/namespaces.go
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,13 @@ func syncObjectsInNamespace(ctx context.Context, ns *corev1.Namespace, objects [

for _, dep := range deps.Items {
labeled := isLabeled(&dep)
if !labeled {
if dep.Labels != nil && dep.Labels[consts.OdigosInstrumentationLabel] == consts.InstrumentationDisabled {
// skip deployments which are explicitly disabled
continue
}
}

userSelection, exists := findObject(objects, dep.Name, ApplicationKindDeployment)
if !exists {
log.Printf("Deployment %s not found in request, skipping\n", dep.Name)
Expand Down

0 comments on commit ab6de38

Please sign in to comment.