-
Notifications
You must be signed in to change notification settings - Fork 107
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
Add check for existing Argo Workflows #955
Add check for existing Argo Workflows #955
Conversation
d605260
to
a4ba3e9
Compare
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 nitty gritty but i am fine with the change.
one more thing, what will happen from Dashboard side.
if we keep throwing error of "CRD already there, go remove it" will user still be able to see the feature of enable DSPV2 from dashboard?
/test opendatahub-operator-e2e |
We still will have v1 manifests deployed. @lucferbux Do you know what will be the dashboard behavior in this case? |
a4ba3e9
to
0adabf8
Compare
Can you provide a screenshot of where/when this will be shown? Also, it would be good to provide the user with a link to further documentation about why exactly they need to remove the CRD/operator. |
/onhold |
This is shown under To resolve this error users will need to delete the Workflow crd by running -
|
Thanks for sharing that @VaishnaviHire, I'm worried that's pretty buried though. Will an admin typically check those statuses after starting an upgrade? With the status set as Ready I wouldn't expect to need to dig into it further to find out something failed. I want to prevent users being frustrated and confused as to why Pipelines won't work. Would it make sense to add a Banner for admins to see in the dashboard? |
should we move this discussion into original JIRA to get more eyes on? |
0adabf8
to
847f35f
Compare
847f35f
to
1ca992f
Compare
@@ -281,12 +296,15 @@ func (r *DataScienceClusterReconciler) reconcileSubComponent(ctx context.Context | |||
instance = r.reportError(err, instance, "failed to reconcile "+componentName+" on DataScienceCluster") | |||
instance, _ = status.UpdateWithRetry(ctx, r.Client, instance, func(saved *dsc.DataScienceCluster) { | |||
if enabled { | |||
status.SetComponentCondition(&saved.Status.Conditions, componentName, status.ReconcileFailed, fmt.Sprintf("Component reconciliation failed: %v", err), corev1.ConditionFalse) | |||
if componentName == datasciencepipelines.ComponentName && strings.Contains(err.Error(), datasciencepipelines.ArgoWorkflowCRD) { |
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.
we probably no need check componentname here,
if componentName == datasciencepipelines.ComponentName && strings.Contains(err.Error(), datasciencepipelines.ArgoWorkflowCRD) { | |
if strings.Contains(err.Error(), datasciencepipelines.ArgoWorkflowCRD) { |
3b4a902
to
c866a19
Compare
This condition looks good from my side where we are testing against: condition.type === 'CapabilityDSPv2Argo' && condition.status === 'False', |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: asanzgom, zdtsw The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
New changes are detected. LGTM label has been removed. |
@etirelli Added the error phase |
ff12f53
to
525c610
Compare
New changes are detected. LGTM label has been removed. |
7389fcb
into
opendatahub-io:incubation
* Add check for existing Argo Workflows * Move resource cleanup before DSC creation * Add separate workflow for upgrades and installs * Remove conditions that are not required * Remove check for DSP component * Add more specific error comparison * Fix linter * Add Error phase * Fix linter (cherry picked from commit 7389fcb)
DeleteFunc: func(e event.DeleteEvent) bool { | ||
if e.Object.GetName() == datasciencepipelines.ArgoWorkflowCRD { | ||
labels := e.Object.GetLabels() | ||
if _, ok := labels["app.opendatahub.io/"+datasciencepipelines.ComponentName]; !ok { |
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.
We could use labels.ODH.Component(datasciencepipelines.ComponentName)
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.
Description
Jira Issue: https://issues.redhat.com/browse/RHOAIENG-4570
This PR introduces changes to handle existing Argo workflows for new install and upgrade. Following is the expected workflow
How Has This Been Tested?
New Install
CapabilityDSPv2Argo
is triggered .Upgrade
CapabilityDSPv2Argo
is triggered .Upgradeable
is set toFalse
Merge criteria: