Skip to content
This repository was archived by the owner on Sep 9, 2026. It is now read-only.

Remove HostPool and Host resource from osac-operator - #174

Merged
openshift-merge-bot[bot] merged 1 commit into
osac-project:mainfrom
tzumainn:remove-host-hostpool
Apr 6, 2026
Merged

openshift-merge-bot[bot] merged 1 commit into
osac-project:mainfrom
tzumainn:remove-host-hostpool

Conversation

@tzumainn

@tzumainn tzumainn commented Apr 3, 2026

Copy link
Copy Markdown
Contributor

These resources will be replaced by new resources specified in the updated bare metal fulfillment proposal.

  • Delete HostPool CRD and sample resource
  • Remove HostPool API types from api/v1alpha1/
  • Remove HostPool controllers (6 files)
  • Remove generated proto files for Host, HostPool, and HostClass
  • Clean up RBAC roles and permissions
  • Update kustomization files
  • Remove configuration artifacts and environment variables
  • Update documentation (README, golangci config)
  • Remove unused HostPoolAAPFinalizer constant

Co-Authored-By: Claude Sonnet 4.5 noreply@anthropic.com

Summary by CodeRabbit

  • Removals

    • Removed HostPool custom resource and controller support from the operator.
    • Removed HostPool-related environment variables, RBAC rules, and configuration entries.
  • Documentation

    • Updated README to remove HostPool from supported custom resources and provisioning provider documentation.
  • Chores

    • Updated linter configuration and Buf module version.
    • Removed sample HostPool manifests and configuration examples.

@openshift-ci
openshift-ci Bot requested review from akshaynadkarni and tzvatot April 3, 2026 20:49
@tzumainn
tzumainn requested review from adriengentil and removed request for akshaynadkarni and tzvatot April 3, 2026 20:49
@openshift-ci openshift-ci Bot added the approved label Apr 3, 2026
@tzumainn
tzumainn requested a review from larsks April 3, 2026 20:49
@coderabbitai

coderabbitai Bot commented Apr 3, 2026

Copy link
Copy Markdown

Warning

Rate limit exceeded

@tzumainn has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 4 minutes and 36 seconds before requesting another review.

Your organization is not enrolled in usage-based pricing. Contact your admin to enable usage-based pricing to continue reviews beyond the rate limit, or try again in 4 minutes and 36 seconds.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 869079a0-8417-4383-a5d6-cf7b03021aa8

📥 Commits

Reviewing files that changed from the base of the PR and between 6104b77 and 43a0e6f.

⛔ Files ignored due to path filters (17)
  • internal/api/osac/private/v1/event_type.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/event_type_protoopaque.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/host_pool_type.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/host_pool_type_protoopaque.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/host_pools_service.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/host_pools_service_grpc.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/host_pools_service_protoopaque.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/host_type.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/host_type_protoopaque.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/hosts_service.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/hosts_service_grpc.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/hosts_service_protoopaque.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/organization_type.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/organization_type_protoopaque.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/organizations_service.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/organizations_service_grpc.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/organizations_service_protoopaque.pb.go is excluded by !**/*.pb.go
📒 Files selected for processing (32)
  • .golangci.yml
  • PROJECT
  • README.md
  • api/v1alpha1/hostpool_conditions.go
  • api/v1alpha1/hostpool_hostpoolreference.go
  • api/v1alpha1/hostpool_types.go
  • api/v1alpha1/zz_generated.deepcopy.go
  • buf.gen.yaml
  • cmd/main.go
  • config/crd/bases/osac.openshift.io_hostpools.yaml
  • config/crd/kustomization.yaml
  • config/manager/manager.yaml
  • config/rbac/hostpool_admin_role.yaml
  • config/rbac/hostpool_editor_role.yaml
  • config/rbac/hostpool_viewer_role.yaml
  • config/rbac/kustomization.yaml
  • config/rbac/role.yaml
  • config/samples/kustomization.yaml
  • config/samples/osac-config-secret.yaml
  • config/samples/osac_v1alpha1_hostpool.yaml
  • internal/controller/hostpool_controller.go
  • internal/controller/hostpool_controller_test.go
  • internal/controller/hostpool_feedback_controller.go
  • internal/controller/hostpool_integration_test.go
  • internal/controller/hostpool_names.go
  • internal/controller/hostpool_resources.go
  • internal/provisioning/aap_provider.go
  • internal/provisioning/aap_provider_test.go
  • internal/provisioning/eda_provider.go
  • internal/provisioning/eda_provider_test.go
  • internal/provisioning/provision_lifecycle.go
  • internal/provisioning/provision_lifecycle_test.go
📝 Walkthrough

Walkthrough

This PR removes the HostPool custom resource and all associated code from the OSAC operator, including API type definitions, controllers, RBAC rules, CRD manifests, configuration, tests, and provisioning handlers across multiple packages.

Changes

Cohort / File(s) Summary
Linter & Build Configuration
.golangci.yml, buf.gen.yaml, PROJECT
Removed HostPool linter exclusion, updated Buf API version to v0.0.51, and deleted HostPool API resource entry from PROJECT configuration.
API Type Definitions
api/v1alpha1/hostpool_types.go, api/v1alpha1/hostpool_conditions.go, api/v1alpha1/hostpool_hostpoolreference.go
Removed HostPool type structs, condition-management methods, host pool reference accessor methods, and scheme registration logic for the HostPool resource.
Code Generation
api/v1alpha1/zz_generated.deepcopy.go
Removed auto-generated DeepCopy and DeepCopyObject methods for HostPool-related types (HostPool, HostPoolList, HostPoolSpec, HostPoolStatus, HostPoolReferenceType, HostSet).
Controller Implementation
internal/controller/hostpool_controller.go, internal/controller/hostpool_controller_test.go, internal/controller/hostpool_feedback_controller.go, internal/controller/hostpool_integration_test.go, internal/controller/hostpool_names.go, internal/controller/hostpool_resources.go
Removed HostPool reconciler, feedback controller, all associated tests, helper functions, and namespace resource management logic.
Provisioning Provider Support
internal/provisioning/aap_provider.go, internal/provisioning/aap_provider_test.go, internal/provisioning/eda_provider.go, internal/provisioning/eda_provider_test.go, internal/provisioning/provision_lifecycle.go, internal/provisioning/provision_lifecycle_test.go
Removed HostPool handling from AAP/EDA provisioning providers, finalizer mappings, job retrieval logic, and related test cases.
RBAC Policies
config/rbac/hostpool_admin_role.yaml, config/rbac/hostpool_editor_role.yaml, config/rbac/hostpool_viewer_role.yaml, config/rbac/kustomization.yaml, config/rbac/role.yaml
Removed HostPool-specific ClusterRoles and updated manager-role to remove HostPool resource permissions.
CRD Manifests & Kustomization
config/crd/bases/osac.openshift.io_hostpools.yaml, config/crd/kustomization.yaml
Removed HostPool CRD manifest declaration and its reference from kustomization resources.
Sample Manifests & Configuration
config/samples/osac_v1alpha1_hostpool.yaml, config/samples/kustomization.yaml, config/manager/manager.yaml, config/samples/osac-config-secret.yaml
Removed HostPool sample resource, environment variable configurations, and kustomization references.
Application Entry Point
cmd/main.go
Removed HostPool controller setup, environment variable handling, flag registration, and scheme registration for HostPool types; updated initialization logic to exclude HostPool from default controllers.
Documentation
README.md
Removed HostPool from supported resources, provisioning provider documentation, controller enable flags, and environment variable references.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Possibly related issues

Possibly related PRs

Suggested labels

lgtm

Suggested reviewers

  • mhrivnak
  • akshaynadkarni
  • adriengentil
  • jhernand

Poem

🐰 A HostPool once bustled with code so grand,
But now 'tis removed from this operator's land,
With types and controllers swept clean away,
The codebase is lighter, hooray, hooray! 🎉

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'Remove HostPool and Host resource from osac-operator' clearly and specifically summarizes the main change: removal of HostPool and Host resources from the operator codebase.
Docstring Coverage ✅ Passed Docstring coverage is 80.00% which is sufficient. The required threshold is 80.00%.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@README.md`:
- Line 92: Replace the ambiguous phrase "Cluster controller" in the README with
the consistent term "ClusterOrder controller": locate the text that currently
reads "Cluster controller" (the literal string) and change it to "ClusterOrder
controller", and scan nearby README occurrences and flag descriptions to ensure
all mentions use "ClusterOrder controller" for terminology consistency across
the doc.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 98bad6dc-52be-486c-909a-bb8edf00ac86

📥 Commits

Reviewing files that changed from the base of the PR and between d965fe4 and 6104b77.

⛔ Files ignored due to path filters (17)
  • internal/api/osac/private/v1/event_type.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/event_type_protoopaque.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/host_pool_type.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/host_pool_type_protoopaque.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/host_pools_service.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/host_pools_service_grpc.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/host_pools_service_protoopaque.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/host_type.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/host_type_protoopaque.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/hosts_service.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/hosts_service_grpc.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/hosts_service_protoopaque.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/organization_type.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/organization_type_protoopaque.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/organizations_service.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/organizations_service_grpc.pb.go is excluded by !**/*.pb.go
  • internal/api/osac/private/v1/organizations_service_protoopaque.pb.go is excluded by !**/*.pb.go
📒 Files selected for processing (32)
  • .golangci.yml
  • PROJECT
  • README.md
  • api/v1alpha1/hostpool_conditions.go
  • api/v1alpha1/hostpool_hostpoolreference.go
  • api/v1alpha1/hostpool_types.go
  • api/v1alpha1/zz_generated.deepcopy.go
  • buf.gen.yaml
  • cmd/main.go
  • config/crd/bases/osac.openshift.io_hostpools.yaml
  • config/crd/kustomization.yaml
  • config/manager/manager.yaml
  • config/rbac/hostpool_admin_role.yaml
  • config/rbac/hostpool_editor_role.yaml
  • config/rbac/hostpool_viewer_role.yaml
  • config/rbac/kustomization.yaml
  • config/rbac/role.yaml
  • config/samples/kustomization.yaml
  • config/samples/osac-config-secret.yaml
  • config/samples/osac_v1alpha1_hostpool.yaml
  • internal/controller/hostpool_controller.go
  • internal/controller/hostpool_controller_test.go
  • internal/controller/hostpool_feedback_controller.go
  • internal/controller/hostpool_integration_test.go
  • internal/controller/hostpool_names.go
  • internal/controller/hostpool_resources.go
  • internal/provisioning/aap_provider.go
  • internal/provisioning/aap_provider_test.go
  • internal/provisioning/eda_provider.go
  • internal/provisioning/eda_provider_test.go
  • internal/provisioning/provision_lifecycle.go
  • internal/provisioning/provision_lifecycle_test.go
💤 Files with no reviewable changes (27)
  • .golangci.yml
  • config/crd/kustomization.yaml
  • config/samples/kustomization.yaml
  • config/rbac/kustomization.yaml
  • config/rbac/hostpool_admin_role.yaml
  • internal/provisioning/provision_lifecycle_test.go
  • internal/provisioning/provision_lifecycle.go
  • internal/provisioning/aap_provider.go
  • config/rbac/hostpool_viewer_role.yaml
  • PROJECT
  • internal/provisioning/aap_provider_test.go
  • config/manager/manager.yaml
  • internal/provisioning/eda_provider.go
  • internal/controller/hostpool_names.go
  • api/v1alpha1/hostpool_conditions.go
  • config/samples/osac_v1alpha1_hostpool.yaml
  • config/rbac/hostpool_editor_role.yaml
  • internal/controller/hostpool_controller_test.go
  • internal/controller/hostpool_integration_test.go
  • api/v1alpha1/hostpool_hostpoolreference.go
  • internal/controller/hostpool_resources.go
  • config/rbac/role.yaml
  • config/crd/bases/osac.openshift.io_hostpools.yaml
  • api/v1alpha1/zz_generated.deepcopy.go
  • api/v1alpha1/hostpool_types.go
  • internal/controller/hostpool_feedback_controller.go
  • internal/controller/hostpool_controller.go

Comment thread README.md Outdated
These resources will be replaced by new resources specified in the
updated bare metal fulfillment proposal.

- Delete HostPool CRD and sample resource
- Remove HostPool API types from api/v1alpha1/
- Remove HostPool controllers (6 files)
- Remove generated proto files for Host, HostPool, and HostClass
- Clean up RBAC roles and permissions
- Update kustomization files
- Remove configuration artifacts and environment variables
- Update documentation (README, golangci config)
- Remove unused HostPoolAAPFinalizer constant

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
@tzumainn
tzumainn force-pushed the remove-host-hostpool branch from 6104b77 to 43a0e6f Compare April 3, 2026 20:55
@openshift-ci

openshift-ci Bot commented Apr 6, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: larsks, tzumainn

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details 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-merge-bot
openshift-merge-bot Bot merged commit f4f53a0 into osac-project:main Apr 6, 2026
8 checks passed
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants