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

Use custom condition type for components and services #1665

Merged

Conversation

lburgazzoli
Copy link
Contributor

@lburgazzoli lburgazzoli commented Feb 13, 2025

Description

Extracted from #1605

How Has This Been Tested?

Screenshot or short clip

Merge criteria

  • You have read the contributors guide.
  • Commit messages are meaningful - have a clear and concise summary and detailed explanation of what was changed and why.
  • Pull Request contains a description of the solution, a link to the JIRA issue, and to any dependent or related Pull Request.
  • Testing instructions have been added in the PR body (for PRs involving changes that are not immediately obvious).
  • The developer has manually tested the changes and verified that the changes work

@openshift-ci openshift-ci bot requested review from lphiri and zdtsw February 13, 2025 16:11
@lburgazzoli lburgazzoli requested review from ykaliuta and removed request for lphiri February 13, 2025 16:13
Copy link

codecov bot commented Feb 13, 2025

Codecov Report

Attention: Patch coverage is 50.48544% with 51 lines in your changes missing coverage. Please review.

Project coverage is 20.65%. Comparing base (a5c75a8) to head (b4d210f).
Report is 7 commits behind head on main.

Files with missing lines Patch % Lines
pkg/controller/conditions/conditions_support.go 64.38% 25 Missing and 1 partial ⚠️
...ers/components/kserve/kserve_controller_actions.go 0.00% 3 Missing ⚠️
...rvices/monitoring/monitoring_controller_actions.go 0.00% 2 Missing ⚠️
controllers/components/codeflare/codeflare.go 0.00% 1 Missing ⚠️
controllers/components/dashboard/dashboard.go 0.00% 1 Missing ⚠️
...nents/datasciencepipelines/datasciencepipelines.go 0.00% 1 Missing ⚠️
...pelines/datasciencepipelines_controller_actions.go 0.00% 1 Missing ⚠️
...trollers/components/feastoperator/feastoperator.go 0.00% 1 Missing ⚠️
controllers/components/kserve/kserve.go 0.00% 1 Missing ⚠️
controllers/components/kueue/kueue.go 0.00% 1 Missing ⚠️
... and 13 more
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1665      +/-   ##
==========================================
+ Coverage   20.36%   20.65%   +0.28%     
==========================================
  Files         164      165       +1     
  Lines       11151    11224      +73     
==========================================
+ Hits         2271     2318      +47     
- Misses       8655     8680      +25     
- Partials      225      226       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@lburgazzoli lburgazzoli marked this pull request as ready for review February 14, 2025 10:18
@lburgazzoli
Copy link
Contributor Author

/test all

type ConditionSeverity string

const (
ConditionSeverityError ConditionSeverity = ""
Copy link
Member

Choose a reason for hiding this comment

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

also seems below 2 const are not in use? excep default "" point to error

Copy link
Contributor Author

Choose a reason for hiding this comment

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

they are going to be in use in a future PR

ConfiguredReason string = "Configured"
RemovedReason string = "Removed"
CapabilityFailed string = "CapabilityFailed"
ArgoWorkflowExist string = "ArgoWorkflowExist"
Copy link
Member

Choose a reason for hiding this comment

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

does not look like still in use

Copy link
Contributor Author

Choose a reason for hiding this comment

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

they are going to be in use in a future PR

Comment on lines +70 to +76
ConditionTypeProvisioningSucceeded = "ProvisioningSucceeded"
ConditionDeploymentsNotAvailableReason = "DeploymentsNotReady"
ConditionDeploymentsAvailable = "DeploymentsAvailable"
ConditionServerlessAvailable = "ServerlessAvailable"
ConditionServiceMeshAvailable = "ServiceMeshAvailable"
ConditionArgoWorkflowAvailable = "ArgoWorkflowAvailable"
ConditionTypeComponentsReady = "ComponentsReady"
Copy link
Member

Choose a reason for hiding this comment

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

are these plan for future use?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

they are going to be in use in a future PR

@lburgazzoli
Copy link
Contributor Author

lburgazzoli commented Feb 18, 2025

@zdtsw there are some leftover constants that are part of a future PR, I can remove them if you think it would be better

@zdtsw
Copy link
Member

zdtsw commented Feb 18, 2025

@zdtsw there are some leftover constants that are part of a future PR, I can remove them if you think it would be better

can keep it now, i do not mind

Copy link

openshift-ci bot commented Feb 18, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: 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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@lburgazzoli
Copy link
Contributor Author

/test all

@openshift-merge-bot openshift-merge-bot bot merged commit 6021d1c into opendatahub-io:main Feb 18, 2025
10 checks passed
@lburgazzoli lburgazzoli deleted the common-conditions branch February 18, 2025 16:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants