Skip to content

Commit

Permalink
Propagate project and entity information to rule evaluation logs
Browse files Browse the repository at this point in the history
  • Loading branch information
evankanderson committed Oct 24, 2024
1 parent b8434fe commit d7fb20e
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions internal/engine/executor.go
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,8 @@ func (e *executor) EvalEntityEvent(ctx context.Context, inf *entities.EntityInfo
Str("provider_id", inf.ProviderID.String()).
Str("project_id", inf.ProjectID.String())
logger.Msg("entity evaluation - started")
// Propagate info to remaining log messages
ctx = logger.WithContext(ctx)

Check failure on line 88 in internal/engine/executor.go

View workflow job for this annotation

GitHub Actions / Analyze (go)

logger.WithContext undefined (type *zerolog.Event has no field or method WithContext)

Check failure on line 88 in internal/engine/executor.go

View workflow job for this annotation

GitHub Actions / build / Verify build

logger.WithContext undefined (type *zerolog.Event has no field or method WithContext)

Check failure on line 88 in internal/engine/executor.go

View workflow job for this annotation

GitHub Actions / lint / Run golangci-lint

logger.WithContext undefined (type *zerolog.Event has no field or method WithContext) (typecheck)

Check failure on line 88 in internal/engine/executor.go

View workflow job for this annotation

GitHub Actions / lint / Run golangci-lint

logger.WithContext undefined (type *zerolog.Event has no field or method WithContext)) (typecheck)

Check failure on line 88 in internal/engine/executor.go

View workflow job for this annotation

GitHub Actions / lint / Run golangci-lint

logger.WithContext undefined (type *zerolog.Event has no field or method WithContext)) (typecheck)

Check failure on line 88 in internal/engine/executor.go

View workflow job for this annotation

GitHub Actions / test / Unit testing

logger.WithContext undefined (type *zerolog.Event has no field or method WithContext)

Check failure on line 88 in internal/engine/executor.go

View workflow job for this annotation

GitHub Actions / compose-migrate / docker

logger.WithContext undefined (type *zerolog.Event has no field or method WithContext)

Check failure on line 88 in internal/engine/executor.go

View workflow job for this annotation

GitHub Actions / image-build / Image build

logger.WithContext undefined (type *zerolog.Event has no field or method WithContext)

// track the time taken to evaluate each entity
entityStartTime := time.Now()
Expand Down

0 comments on commit d7fb20e

Please sign in to comment.