opendatahub-io / opendatahub-operator

Open Data Hub operator to manage ODH component integrations
https://opendatahub.io
Apache License 2.0
59 stars 127 forks source link

refactor: simplifies Feature Manifests #1114

Closed bartoszmajsak closed 1 month ago

bartoszmajsak commented 1 month ago

Description

The raw and template manifest structs differed only in their content processing methods, making it an unnecessary abstraction. This work consolidates the two implementations, reducing duplication and resulting in cleaner code.

The implementation still adheres to the convention of using a .tmpl. in the file name to indicate a template and only then process it as such.

The feature builder has been reworked from chaining ManifestLocation().Manifest in favor of composition. This not only makes the code easier to follow but also allows to potentially mix different kinds of Manifest providers.

Additionally, Applier wrapper has been introduced to handle different strategies of applying manifests to the cluster based on their types.

How Has This Been Tested?

Screenshot or short clip

Merge criteria

openshift-ci[bot] commented 1 month ago

[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: - ~~[OWNERS](https://github.com/opendatahub-io/opendatahub-operator/blob/incubation/OWNERS)~~ [zdtsw] Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment
openshift-ci[bot] commented 1 month ago

New changes are detected. LGTM label has been removed.

bartoszmajsak commented 1 month ago

Thanks for taking care of it @zdtsw

zdtsw commented 1 month ago

not sure why, seems prow did not act on the latest rebase :vomiting_face: