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

Feature/9 check dogu health #10

Merged
merged 10 commits into from
Jan 5, 2024
Merged

Conversation

jelemux
Copy link
Contributor

@jelemux jelemux commented Jan 3, 2024

Resolves #9

also:
- refactor events
- test dogu health checks
- fix failing tests
- move unhealthy logic to dogu installation
* Conflicts:
*	go.sum
*	pkg/domain/stateDiff.go
Copy link
Contributor

@alexander-dammeier alexander-dammeier left a comment

Choose a reason for hiding this comment

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

It is a little bit unclear, what to do if dogus are unhealthy for now, but we can simply change that when we have more experience with the upcoming later stages of the blueprint process.

Besides that there are only small things.
Nice work!

Comment on lines +76 to 77
case domain.StatusPhaseDogusUnhealthy:
return nil
Copy link
Contributor

Choose a reason for hiding this comment

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

Do we want that the blueprint retry if dogus are unhealthy? The problem could be that the previously determined state diff could be outdated then.
I think we should have a look at this again when the operator can install dogus, so that we have more experience, which states are really helpful and which states we could combine to a single one. This way we can refactor that in its completeness if necessary.

Comment on lines +458 to +465
func mustParseVersion(raw string) core.Version {
version, err := core.ParseVersion(raw)
if err != nil {
panic(err)
}

return version
}
Copy link
Contributor

Choose a reason for hiding this comment

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

Previously i simply created vars with parsed version numbers outside of the tests. The version-structs have a field for the raw string, so you can use the version struct even if you need to provide a string-typed version.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Should I change it or is it ok like this?

jelemux and others added 2 commits January 5, 2024 13:06
Co-authored-by: Alexander Dammeier <alexander.dammeier@cloudogu.com>
@alexander-dammeier
Copy link
Contributor

Some tests fail after the refactoring. When they are fixed, we can merge :)

Co-authored-by: Alexander Dammeier <alexander.dammeier@cloudogu.com>
@alexander-dammeier alexander-dammeier merged commit 57a472e into develop Jan 5, 2024
@alexander-dammeier alexander-dammeier deleted the feature/9_check_dogu_health branch January 5, 2024 12:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Check dogu health
2 participants