Skip to content

OLS-3402: remove default resource limits on deployments#1781

Open
raptorsun wants to merge 1 commit into
openshift:mainfrom
raptorsun:ols-3402
Open

OLS-3402: remove default resource limits on deployments#1781
raptorsun wants to merge 1 commit into
openshift:mainfrom
raptorsun:ols-3402

Conversation

@raptorsun

@raptorsun raptorsun commented Jul 3, 2026

Copy link
Copy Markdown
Contributor

Description

Type of change

  • Refactor
  • New feature
  • Bug fix
  • CVE fix
  • Optimization
  • Documentation Update
  • Configuration Update
  • Bump-up dependent library

Related Tickets & Documents

Checklist before requesting a review

  • I have performed a self-review of my code.
  • PR has passed all pre-merge test jobs.
  • If it is a core feature, I have added thorough tests.

Testing

  • Please provide detailed steps to perform tests related to this code change.
  • How were the fix/results from this change verified? Please provide relevant screenshots or results.

Summary by CodeRabbit

  • Bug Fixes
    • Default container resource settings now use requests only and no longer apply hardcoded memory limits for several deployed components.
    • Updated related deployment expectations to match the new resource behavior across the app server, console, database, alerts adapter, and console plugins.

Signed-off-by: Haoyu Sun <hasun@redhat.com>
@openshift-ci-robot openshift-ci-robot added the jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. label Jul 3, 2026
@openshift-ci-robot

openshift-ci-robot commented Jul 3, 2026

Copy link
Copy Markdown

@raptorsun: This pull request references OLS-3402 which is a valid jira issue.

Details

In response to this:

Description

Type of change

  • Refactor
  • New feature
  • Bug fix
  • CVE fix
  • Optimization
  • Documentation Update
  • Configuration Update
  • Bump-up dependent library

Related Tickets & Documents

Checklist before requesting a review

  • I have performed a self-review of my code.
  • PR has passed all pre-merge test jobs.
  • If it is a core feature, I have added thorough tests.

Testing

  • Please provide detailed steps to perform tests related to this code change.
  • How were the fix/results from this change verified? Please provide relevant screenshots or results.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@coderabbitai

coderabbitai Bot commented Jul 3, 2026

Copy link
Copy Markdown

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: d6032874-931a-4436-9650-0ce03cb82255

📥 Commits

Reviewing files that changed from the base of the PR and between a1bbf9c and eee107c.

📒 Files selected for processing (8)
  • internal/controller/alertsadapter/deployment.go
  • internal/controller/appserver/assets_test.go
  • internal/controller/appserver/deployment.go
  • internal/controller/console/assets_test.go
  • internal/controller/postgres/assets_test.go
  • internal/controller/postgres/deployment.go
  • internal/controller/utils/console_plugin_test.go
  • internal/controller/utils/utils.go
💤 Files with no reviewable changes (7)
  • internal/controller/console/assets_test.go
  • internal/controller/postgres/deployment.go
  • internal/controller/postgres/assets_test.go
  • internal/controller/utils/utils.go
  • internal/controller/alertsadapter/deployment.go
  • internal/controller/appserver/deployment.go
  • internal/controller/appserver/assets_test.go

📝 Walkthrough

Walkthrough

This PR removes default memory Limits from ResourceRequirements for several containers (alerts adapter, OLS server, data collector, MCP server, Postgres, console plugin), leaving only default Requests. Corresponding test assertions are updated to no longer expect Limits values.

Changes

Removal of default resource limits

Layer / File(s) Summary
Alerts adapter default resources
internal/controller/alertsadapter/deployment.go
Removes default Limits (memory) from alerts adapter container resource defaults, leaving only Requests.
App server default resources and tests
internal/controller/appserver/deployment.go, internal/controller/appserver/assets_test.go
Removes default Limits for OLS server, data collector, and MCP server containers; updates deployment tests to assert only Requests and Claims.
Console plugin default resources and tests
internal/controller/utils/utils.go, internal/controller/console/assets_test.go, internal/controller/utils/console_plugin_test.go
Updates DefaultConsolePluginResourceRequirements to set CPU/memory requests and remove default limits.memory; updates console and utils tests accordingly.
Postgres default resources and tests
internal/controller/postgres/deployment.go, internal/controller/postgres/assets_test.go
Removes default Limits memory setting from Postgres container resource defaults; updates deployment test expectations to no longer assert Limits.

Estimated code review effort: 2 (Simple) | ~10 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main change: removing default resource limits from deployment resource definitions.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ 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.

@openshift-ci openshift-ci Bot requested review from blublinsky and xrajesh July 3, 2026 14:09
@openshift-ci

openshift-ci Bot commented Jul 3, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign raptorsun for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found 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-ci

openshift-ci Bot commented Jul 3, 2026

Copy link
Copy Markdown

@raptorsun: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/bundle-e2e-4-21 eee107c link true /test bundle-e2e-4-21

Full PR test history. Your PR dashboard.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

jira/valid-reference Indicates that this PR references a valid Jira ticket of any type.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants