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

Kubernetes consolidation #368

Closed
wants to merge 21 commits into from
Closed

Conversation

BrendanGalloway
Copy link
Contributor

#341 #309

Adds a contextualise function to generically handle inserting defaults values to checks, and templating environment values into chained checks

@github-actions
Copy link

github-actions bot commented Nov 3, 2021

E2E - minimal --skip-all

1 files  ±0  1 suites  ±0   0s ⏱️ -1s
9 tests ±0  4 ✔️  - 5  0 💤 ±0  5 +5 

For more details on these failures, see this check.

Results for commit f12efac. ± Comparison against base commit ea91049.

♻️ This comment has been updated with latest results.

@github-actions
Copy link

github-actions bot commented Nov 3, 2021

E2E - datasources

  1 files  ±0  1 suites  ±0   0s ⏱️ - 6m 22s
19 tests ±0  7 ✔️  - 12  0 💤 ±0  12 +12 

For more details on these failures, see this check.

Results for commit f12efac. ± Comparison against base commit ea91049.

♻️ This comment has been updated with latest results.

@github-actions
Copy link

github-actions bot commented Nov 3, 2021

E2E - git

1 files  ±0  1 suites  ±0   0s ⏱️ -2s
3 tests ±0  0 ✔️  - 3  0 💤 ±0  3 +3 

For more details on these failures, see this check.

Results for commit f12efac. ± Comparison against base commit ea91049.

♻️ This comment has been updated with latest results.

@github-actions
Copy link

github-actions bot commented Nov 3, 2021

E2E - k8s

1 files  ±0  1 suites  ±0   0s ⏱️ - 1m 58s
5 tests  - 7  0 ✔️  - 12  0 💤 ±0  5 +5 

For more details on these failures, see this check.

Results for commit abdc52d. ± Comparison against base commit ea91049.

This pull request removes 7 tests.
TestRunChecks/docker_fail.yaml
TestRunChecks/docker_pass.yaml
TestRunChecks/docker_push_fail.yaml
TestRunChecks/junit_pass.yaml
TestRunChecks/kubernetes_pass.yaml
TestRunChecks/namespace_pass.yaml
TestRunChecks/pod_fail.yaml

♻️ This comment has been updated with latest results.

@@ -62,3 +65,35 @@ func (ctx *Context) New(environment map[string]interface{}) *Context {
Logger: ctx.Logger,
}
}
func (ctx *Context) GetInnerCanaries(namespace string, canaryRef []k8sv1.LocalObjectReference) ([]v1.Canary, []string, error) {
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
func (ctx *Context) GetInnerCanaries(namespace string, canaryRef []k8sv1.LocalObjectReference) ([]v1.Canary, []string, error) {
func (ctx *Context) GetCanaries(namespace string, canaryRef []k8sv1.LocalObjectReference) ([]v1.Canary, []string, error) {

checks/checker.go Outdated Show resolved Hide resolved
@@ -31,7 +31,11 @@ func (c *CloudWatchChecker) Type() string {
}

func (c *CloudWatchChecker) Check(ctx *context.Context, extConfig external.Check) *pkg.CheckResult {
check := extConfig.(v1.CloudWatchCheck)
updated, err := Contextualise(extConfig, ctx)
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
updated, err := Contextualise(extConfig, ctx)
updated, err := ctx.Contextualise(extConfig)

if err != nil {
return pkg.Fail(extConfig, ctx.Canary)
}
check := updated.(v1.CloudWatchCheck)
Copy link
Member

Choose a reason for hiding this comment

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

does the contextualization not need to happen on check with type information ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Not sure I follow. The need is to generically template any chained canary, so the function is written to take an external.Check rather than a specifically typed v1.xxCheck

@moshloop moshloop marked this pull request as draft March 12, 2024 06:26
@moshloop moshloop closed this May 19, 2024
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.

2 participants