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

feat: add support for modelmeshserving as component #1338

Merged

Conversation

zdtsw
Copy link
Member

@zdtsw zdtsw commented Nov 4, 2024

Description

  1. add modelmeshserving into component
  2. remove/update odh-model-controller related part from kserve including test
  3. temp disable watch on CRDs coming from kserve and modelmesh, due to a finding that both ship the same CRDs and causing Operator reconcile. following PR will address a fix
  4. introduce a non-DSC spec visible modelcontroller component.
  • should not show in the DSC .status.installedComponent map
  • should show in the DSC .status.condition.modelcontrollerReady:true/false
    should have kserve and/or modelmeshserving as ownerrefence if they are enabled but keep DSC as controller for now
  • should have .spec.kserve {} and .spec.modelmeshserving {} to include managmenetstate and devflags
  • should have .status.uri to show which uri is being used from devflag if both kserve and modelmeshserving set it

https://issues.redhat.com/browse/RHOAIENG-15481
https://issues.redhat.com/browse/RHOAIENG-13177

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

@zdtsw
Copy link
Member Author

zdtsw commented Nov 4, 2024

/test opendatahub-operator-e2e

@@ -21,6 +21,10 @@ import (
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
)

const (
ModelMeshCtrlerComponentName = "odh-model-controller" // shared by kserve and mm
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
ModelMeshCtrlerComponentName = "odh-model-controller" // shared by kserve and mm
ModelControllerComponentName = "odh-model-controller" // shared by kserve and mm

I assume that it shouldn't have ModelMesh in the name if it's not modelmesh specific?

@zdtsw zdtsw force-pushed the jira/13177 branch 2 times, most recently from f2ae263 to 206adab Compare November 19, 2024 15:55
@zdtsw zdtsw force-pushed the jira/13177 branch 2 times, most recently from 2fbf65d to f84aa91 Compare November 19, 2024 17:38
@zdtsw zdtsw changed the title [WIP] feat: add support for modelmeshserving as component feat: add support for modelmeshserving as component Nov 19, 2024
zdtsw added 5 commits December 3, 2024 15:49
- add new modelcontroller component: do not show in DSC.status.installedComponents
- e2e on modelcontroller wont run in parallel but after components are done
- if modelmesh is enabled and/or kserve is enabled, modelcontroller should be created
- devFlag for modelcontroller from kserve (high) or modelmesh (low) priority
- set dynamic watch on kserve and modelmesh because one of them might enabled later
- reuse the same clusterrole from kserve on aggregated rules
- add kserve and/or modelmesh into ownerrefence but not set as controller, keep DSC for now

Signed-off-by: Wen Zhou <wenzhou@redhat.com>
Signed-off-by: Wen Zhou <wenzhou@redhat.com>
…nd modelmesh

- kserve inject itself as owner to modelcontroller
- modelmesh inject iteslef as owner to modelcontroller
- modelcontroller no need to watch kserve nor modelmesh
- removed duplicated check in dsc for "enabled" which is in the GetManagementStatus

Signed-off-by: Wen Zhou <wenzhou@redhat.com>
- fix installedComponent map to not include modelcontroller
- to not add old kserve UID when new kserve CR created(if in any case, kserve CR is deleted but UID remain in modelcontroller)
- ditto to modelmeshserving
- add .status.uri to set exactly which uri is used for devflag if devFlags is set overwrite odh-model-controller
- to explicitly show .spec.kserve.managementstate and .spec.modelmeshserving.managementstate in modelcontroller

Signed-off-by: Wen Zhou <wenzhou@redhat.com>
- till we know more what we want to do, we keep modelcontroller ownereference to only DSC

Signed-off-by: Wen Zhou <wenzhou@redhat.com>
- both kserve and mdoelmesh ship these 2 CRDs

Signed-off-by: Wen Zhou <wenzhou@redhat.com>
- will update with new function on CRD later

Signed-off-by: Wen Zhou <wenzhou@redhat.com>
Signed-off-by: Wen Zhou <wenzhou@redhat.com>
@lburgazzoli
Copy link
Contributor

LGTM, @VaishnaviHire ?

Copy link
Member

@VaishnaviHire VaishnaviHire left a comment

Choose a reason for hiding this comment

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

Tested this yesterday.

/lgtm

Copy link

openshift-ci bot commented Dec 4, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: VaishnaviHire

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

@openshift-ci openshift-ci bot added the approved label Dec 4, 2024
@zdtsw zdtsw enabled auto-merge (squash) December 4, 2024 13:22
@openshift-ci openshift-ci bot removed the lgtm label Dec 4, 2024
Copy link

openshift-ci bot commented Dec 4, 2024

New changes are detected. LGTM label has been removed.

@zdtsw zdtsw merged commit 2aff8dc into opendatahub-io:feature-operator-refactor Dec 4, 2024
6 of 8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

5 participants