Skip to content

Commit

Permalink
comment
Browse files Browse the repository at this point in the history
Signed-off-by: Julie Vogelman <[email protected]>
  • Loading branch information
juliev0 committed Feb 2, 2022
1 parent 408f62d commit d12c52b
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions eventbus/driver/nats.go
Original file line number Diff line number Diff line change
Expand Up @@ -418,6 +418,7 @@ func (mh *eventSourceMessageHolder) setLastResetTime(t int64) {
mh.lastResetTime = t
}

// failsafe condition: determine if we for some reason we haven't acknowledged all dependencies within 60 seconds of the lastResetTime
func (mh *eventSourceMessageHolder) fullResetTimeout() bool {
return mh.getLastResetTime() != 0 && time.Now().Unix()-mh.getLastResetTime() > 60 && mh.fullResetOccurrenceTime < mh.lastResetTime
}
Expand Down

0 comments on commit d12c52b

Please sign in to comment.