-
Notifications
You must be signed in to change notification settings - Fork 1
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
feat: enhances FeatureTracker with spec #17
Changes from 9 commits
b68188a
d527e05
a75c127
aa7dd82
b9e0f99
4ae4406
622d556
c2f7b71
1e87b53
103593f
387b013
0571826
b10d36f
b6c18cc
f632227
3207250
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,6 +17,7 @@ import ( | |
"sigs.k8s.io/controller-runtime/pkg/client" | ||
|
||
dsciv1 "github.com/opendatahub-io/opendatahub-operator/v2/apis/dscinitialization/v1" | ||
featurev1 "github.com/opendatahub-io/opendatahub-operator/v2/apis/features/v1" | ||
"github.com/opendatahub-io/opendatahub-operator/v2/components" | ||
"github.com/opendatahub-io/opendatahub-operator/v2/pkg/cluster" | ||
"github.com/opendatahub-io/opendatahub-operator/v2/pkg/common" | ||
|
@@ -217,7 +218,10 @@ func (d *Dashboard) Cleanup(cli client.Client, dscispec *dsciv1.DSCInitializatio | |
} | ||
|
||
if shouldConfigureServiceMesh { | ||
serviceMeshInitializer := feature.NewFeaturesInitializer(dscispec, d.defineServiceMeshFeatures(dscispec)) | ||
serviceMeshInitializer := feature.NewFeaturesInitializer(dscispec, d.defineServiceMeshFeatures(dscispec), featurev1.Origin{ | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I would extract it to it's own There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. done here: learned about go's |
||
Type: featurev1.ComponentType, | ||
Name: d.GetComponentName(), | ||
}) | ||
|
||
if err := serviceMeshInitializer.Prepare(); err != nil { | ||
return err | ||
|
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.
How about improving this slightly and make sub-type for string?
and use this type instead? That would make it a bit more focused and type-safe. We already use something similar across the codebase -
ManagementState
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.
On that note - maybe a follow-up PR to our "feature" branch could similarly make the condition phase its own type. Somehow we missed that opportunity in the original PR.
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.
done this here 103593f