Skip to content
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

ci: improve ems alert logging and event generation #1993

Merged
merged 2 commits into from
Apr 25, 2023
Merged

ci: improve ems alert logging and event generation #1993

merged 2 commits into from
Apr 25, 2023

Conversation

cgrinds
Copy link
Collaborator

@cgrinds cgrinds commented Apr 25, 2023

No description provided.

@cgrinds cgrinds merged commit 898404c into main Apr 25, 2023
@cgrinds cgrinds deleted the cbg-ci-ems branch April 25, 2023 19:11
err := conf.LoadHarvestConfig(installer.HarvestConfigFile)
poller, err2 := conf.PollerNamed(TestClusterName)
dc1, err3 := conf.PollerNamed("dc1")
if err != nil && err2 != nil && err3 != nil {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess any one err != nil then we would be erroring out?

Comment on lines +104 to +105
poller, err2 := conf.PollerNamed(TestClusterName)
dc1, err3 := conf.PollerNamed("dc1")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

only password we fetched from dc1, right ?

Comment on lines +77 to +78
v := newAlertsData[issuingEms] - oldAlertsData[issuingEms]
if v > 1 {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This would not be as per our test case.
If we have issuing ems(ex. volume.offline) count as 3[oldAlertsData] earlier and after we fire resolving ems(volume.online), the issuing ems count would be reduced to 2[newAlertsData]
So, v = 2-3 = -1

Condition would be,

if v >= 0 {
error log
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants