-
Notifications
You must be signed in to change notification settings - Fork 187
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
gitrepo: Use summarize helper for success events
When source fetch failure takes happens, a warning event is emitted but when resolved, there's no resolved event emitted. This change introduces a new ResultProcessor, NotifySuccess, for SummarizeAndPatch helper which consolidates all the messages to be emitted as a single event. It checks for any recovery from failure condition and adds that to the success event message. The gitrepo reconciler is modified to use the use NotifySuccess ResultProcessor. A change in artifact is checked in reconcile() and a Notification object is returned, populated with the success information. When the Notification is empty/zero, and no failure recovery, no event is emitted. Failure recovery without any Notification also results in an event with only the recovery information. Signed-off-by: Sunny <darkowlzz@protonmail.com>
- Loading branch information
Showing
4 changed files
with
236 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters