-
Notifications
You must be signed in to change notification settings - Fork 667
Reconcile feature flag extensions #3987
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
Reconcile feature flag extensions #3987
Conversation
|
@spadgett Adding SelfSubjectAccessReview feature flag extension would be the next follow-up step, which would allow us to address |
alecmerdler
left a comment
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.
/lgtm
|
/hold |
|
/hold cancel |
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.
.reduce( (gatingFlags, ext) => ext.properties.required || ext.properties.disallowed ?
_.uniq(....)
: gatingFlags)
maybe only use reduce?
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.
Sure, I can put the filter logic inside the reduce handler.
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.
Some plugins might need to support k8sWatch which does not return a promise.
| detect: (dispatch: Dispatch) => Promise<any>; | |
| detect: (dispatch: Dispatch) => Promise<any> | void; |
|
@bipuladh @cloudbehl Regarding Bipul's #3987 (comment) - I've discussed it with @rawagner, using On a vanilla k8s cluster or a cluster without OCS capability, CRD for Detection of various platforms (OpenShift, Baremetal, etc.) typically uses However, in case of OCS "independent" flag, driven by a specific k8sWatch(OCSServiceModel, { ns: 'openshift-storage', name: 'ocs-storagecluster' })I can see two solutions here:
|
b7e566c to
13cd837
Compare
|
Rebased and addressed #3987 (comment) |
13cd837 to
84da6fa
Compare
|
/retest |
|
/lgtm |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: alecmerdler, bipuladh, rawagner, vojtechszocs The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
/retest Please review the full test history for this PR and help us cut down flakes. |
3 similar comments
|
/retest Please review the full test history for this PR and help us cut down flakes. |
|
/retest Please review the full test history for this PR and help us cut down flakes. |
|
/retest Please review the full test history for this PR and help us cut down flakes. |
|
/hold |
|
/hold cancel |
This PR aligns
ModelFeatureFlagandActionFeatureFlagextensions and their usage.By design, every instance of ^^ represents a plugin's intent to add new Console feature flag.
To validate this invariant, the corresponding extension test (
features.spec.ts) is updated to check for duplicate flag declarations.@alecmerdler @jeff-phillips-18 I've made two major changes in the OLM plugin:
Flagsenumexport enum Flags { OPERATOR_LIFECYCLE_MANAGER = 'OPERATOR_LIFECYCLE_MANAGER', - CAN_LIST_PACKAGE_MANIFEST = 'CAN_LIST_PACKAGE_MANIFEST', - CAN_LIST_OPERATOR_GROUP = 'CAN_LIST_OPERATOR_GROUP', }since they are already declared in Console
FLAGSenum.CAN_LIST_PACKAGE_MANIFESTflag extensionsince it basically overrides the base SSAR check in
public/actions/features.ts@bipuladh @rawagner
ExtensionRegistryis modified to support thedisallowedproperty. Dashboard related extensions should now support bothdisallowedandrequired.Unknown flag check in
public/reducers/features.tsis updated to take plugin contributed flags into account.cc @spadgett @christianvogt