-
Notifications
You must be signed in to change notification settings - Fork 94
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add workflowId field in alert model #463
Conversation
Signed-off-by: Surya Sashank Nistala <[email protected]>
Codecov Report
@@ Coverage Diff @@
## main #463 +/- ##
============================================
- Coverage 73.83% 73.77% -0.06%
- Complexity 824 825 +1
============================================
Files 127 127
Lines 5354 5366 +12
Branches 675 680 +5
============================================
+ Hits 3953 3959 +6
- Misses 1104 1106 +2
- Partials 297 301 +4
|
@@ -22,6 +22,7 @@ data class Alert( | |||
val version: Long = NO_VERSION, | |||
val schemaVersion: Int = NO_SCHEMA_VERSION, | |||
val monitorId: String, | |||
val workflowId: String, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't this be optional? Normal monitor executions will fail when creating an alert since workflows are not there. Also the vice versa might be an issue since the chained alert won't have a monitor id.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
monitor id would be null or empty for chained alerts
workflow Id would be null or empty for non-workflow alert
in the constructors we handle each case and set "" to handle the empty case for either field
Signed-off-by: Surya Sashank Nistala <[email protected]> (cherry picked from commit 110bf01)
Signed-off-by: Surya Sashank Nistala <[email protected]> (cherry picked from commit 110bf01) Co-authored-by: Surya Sashank Nistala <[email protected]>
The backport to
To backport manually, run these commands in your terminal: # Navigate to the root of your repository
cd $(git rev-parse --show-toplevel)
# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add ../.worktrees/common-utils/backport-2.5 2.5
# Navigate to the new working tree
pushd ../.worktrees/common-utils/backport-2.5
# Create a new branch
git switch --create backport-463-to-2.5
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 110bf0158417c3e06d08fafe6ebdccf900aecd0d
# Push it to GitHub
git push --set-upstream origin backport-463-to-2.5
# Go back to the original working tree
popd
# Delete the working tree
git worktree remove ../.worktrees/common-utils/backport-2.5 Then, create a pull request where the |
The backport to
To backport manually, run these commands in your terminal: # Navigate to the root of your repository
cd $(git rev-parse --show-toplevel)
# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add ../.worktrees/common-utils/backport-2.9 2.9
# Navigate to the new working tree
pushd ../.worktrees/common-utils/backport-2.9
# Create a new branch
git switch --create backport-463-to-2.9
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 110bf0158417c3e06d08fafe6ebdccf900aecd0d
# Push it to GitHub
git push --set-upstream origin backport-463-to-2.9
# Go back to the original working tree
popd
# Delete the working tree
git worktree remove ../.worktrees/common-utils/backport-2.9 Then, create a pull request where the |
The backport to
To backport manually, run these commands in your terminal: # Navigate to the root of your repository
cd $(git rev-parse --show-toplevel)
# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add ../.worktrees/common-utils/backport-2.7 2.7
# Navigate to the new working tree
pushd ../.worktrees/common-utils/backport-2.7
# Create a new branch
git switch --create backport-463-to-2.7
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 110bf0158417c3e06d08fafe6ebdccf900aecd0d
# Push it to GitHub
git push --set-upstream origin backport-463-to-2.7
# Go back to the original working tree
popd
# Delete the working tree
git worktree remove ../.worktrees/common-utils/backport-2.7 Then, create a pull request where the |
The backport to
To backport manually, run these commands in your terminal: # Navigate to the root of your repository
cd $(git rev-parse --show-toplevel)
# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add ../.worktrees/common-utils/backport-2.11 2.11
# Navigate to the new working tree
pushd ../.worktrees/common-utils/backport-2.11
# Create a new branch
git switch --create backport-463-to-2.11
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 110bf0158417c3e06d08fafe6ebdccf900aecd0d
# Push it to GitHub
git push --set-upstream origin backport-463-to-2.11
# Go back to the original working tree
popd
# Delete the working tree
git worktree remove ../.worktrees/common-utils/backport-2.11 Then, create a pull request where the |
…oject#464) Signed-off-by: Surya Sashank Nistala <[email protected]> (cherry picked from commit 110bf01) Co-authored-by: Surya Sashank Nistala <[email protected]> Signed-off-by: AWSHurneyt <[email protected]>
Description
Add workflowId field in alert model.
This field would be populated when alerts are created by monitors executing within a workflow. Else field would be an empty string