Skip to content

Commit

Permalink
Merge pull request #313 from shriramsharma/status-check-with-gen-check
Browse files Browse the repository at this point in the history
added status check along with generation check
  • Loading branch information
shriramsharma authored Aug 9, 2024
2 parents 6a100b3 + c059ae1 commit 0e7d8fe
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
5 changes: 4 additions & 1 deletion admiral/pkg/controller/admiral/controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,10 @@ func NewController(name, clusterEndpoint string, stopCh <-chan struct{}, delegat
if err != nil {
ctxLogger.Errorf(ControllerLogFormat, taskAddEventToQueue, controller.queue.Len(), err.Error())
}
if doesGenerationMatch {
if status == common.Processed && doesGenerationMatch {
ctxLogger.Infof(ControllerLogFormat, taskAddEventToQueue, controller.queue.Len(),
fmt.Sprintf("skipped processing event due to status=%s doesGenerationMatch=%v",
status, doesGenerationMatch))
return
}

Expand Down
1 change: 0 additions & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ require (
require (
github.com/aws/aws-sdk-go v1.55.2
github.com/istio-ecosystem/admiral-api v1.1.0
github.com/jamiealquiza/tachymeter v2.0.0+incompatible
github.com/prometheus/common v0.53.0
go.opentelemetry.io/otel v1.27.0
go.opentelemetry.io/otel/exporters/prometheus v0.49.0
Expand Down
2 changes: 0 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -234,8 +234,6 @@ github.com/inconshreveable/mousetrap v1.0.0 h1:Z8tu5sraLXCXIcARxBp/8cbvlwVa7Z1NH
github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8=
github.com/istio-ecosystem/admiral-api v1.1.0 h1:SLRgKRdZP31G0Q2uaYcVb3JxkjAbTxbSsze2N5ncapE=
github.com/istio-ecosystem/admiral-api v1.1.0/go.mod h1:xB+G1v2H/cOxuR6koi/3kLHgF+oc3y905Lt12NCyMCI=
github.com/jamiealquiza/tachymeter v2.0.0+incompatible h1:mGiF1DGo8l6vnGT8FXNNcIXht/YmjzfraiUprXYwJ6g=
github.com/jamiealquiza/tachymeter v2.0.0+incompatible/go.mod h1:Ayf6zPZKEnLsc3winWEXJRkTBhdHo58HODAu1oFJkYU=
github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg=
github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo=
github.com/jmespath/go-jmespath/internal/testify v1.5.1 h1:shLQSRRSCCPj3f2gpwzGwWFoC7ycTf1rcQZHOlsJ6N8=
Expand Down

0 comments on commit 0e7d8fe

Please sign in to comment.