updated cloudnative dependency to 1.27.0#1693
Conversation
WalkthroughBumps Go toolchain and many dependencies; increases expected CNPG CRD count from 9 to 10; updates exported CnpgVersion to 1.27.0; fixes autoscaler to return a Prometheus pointer; removes repeated beta-note text from NooBaa CRD descriptions and updates its embedded checksum; narrows RunReconcile requeue condition. Changes
Sequence Diagram(s)sequenceDiagram
autonumber
participant Autoscaler as Autoscaler
participant K8sAPI as K8s API (client)
note right of Autoscaler #D3E4FF: getPrometheus now returns a pointer
Autoscaler->>K8sAPI: List Prometheus objects
K8sAPI-->>Autoscaler: prometheusList (Items array)
alt found
Autoscaler->>Autoscaler: return &prometheusList.Items[0]
else none
Autoscaler-->>Autoscaler: return error
end
sequenceDiagram
autonumber
participant Controller as Controller.RunReconcile
participant Reconciler as Reconciler
note right of Controller #FFF4D6: requeue condition tightened
Controller->>Reconciler: call Reconcile()
Reconciler-->>Controller: Result{Requeue, RequeueAfter}
alt RequeueAfter != 0
Controller->>Controller: schedule requeue after RequeueAfter
else RequeueOnly (Requeue==true, RequeueAfter==0)
Controller->>Controller: no requeue (changed)
end
Estimated code review effort🎯 4 (Complex) | ⏱️ ~45 minutes Possibly related PRs
Suggested reviewers
✨ Finishing Touches
🧪 Generate 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. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. CodeRabbit Commands (Invoked using PR/Issue comments)Type Other keywords and placeholders
Status, Documentation and Community
|
There was a problem hiding this comment.
Actionable comments posted: 1
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (2)
pkg/system/autoscaler.go (2)
582-593: Fix: undefined ctx and premature polling termination in waitForCertificateReady.
- ctx is not defined; this won’t compile.
- Returning an error when the cert isn’t ready stops polling early.
Apply:
- err := wait.PollUntilContextTimeout(ctx, interval*time.Second, timeout*time.Second, true, func(ctx context.Context) (bool, error) { + err := wait.PollUntilContextTimeout(context.Background(), interval*time.Second, timeout*time.Second, true, func(ctx context.Context) (bool, error) { if err := klient.Get(util.Context(), util.ObjectKey(configMap), configMap); err != nil { log.Printf("⏳ Failed to get service ca certificate: %s", err) return false, nil } - if configMap.Data["service-ca.crt"] == "" { - return false, fmt.Errorf("service ca certificate not created") - } + if strings.TrimSpace(configMap.Data["service-ca.crt"]) == "" { + return false, nil + } return true, nil })
63-69: Guard against empty Metrics slice before indexing.Indexing at [0] can panic if Metrics is empty.
- if r.AdapterHPA.Spec.Metrics[0].Type == autoscalingv2.ResourceMetricSourceType { + if len(r.AdapterHPA.Spec.Metrics) > 0 && r.AdapterHPA.Spec.Metrics[0].Type == autoscalingv2.ResourceMetricSourceType {
🧹 Nitpick comments (6)
pkg/system/autoscaler.go (3)
414-438: Verify service discovery: using ServiceAccountName as Service name looks incorrect.getPrometheusURL constructs a Service with Name = Prometheus.Spec.ServiceAccountName. That field is a service account, not a Service. Please confirm a Service with that name actually exists in your target clusters; otherwise, resolve the Service by known labels/selectors or make the Service name configurable.
I can suggest a label-based lookup (and a fallback to a user-provided service name) if desired.
259-271: Tighten user-facing messages: multiple typos and wording issues.These show up in logs/errors and degrade UX. Suggested fixes:
- log.Errorf("❌ Keda deploymen not ready") + log.Errorf("❌ Keda deployment not ready") - log.Errorf("Falied to delete HPAV1 existing %q autoscaler", autoscalersName) - return fmt.Errorf("falied to delete HPAV1 existing %q autoscaler", autoscalersName) + log.Errorf("Failed to delete HPAV1 existing %q autoscaler", autoscalersName) + return fmt.Errorf("failed to delete HPAV1 existing %q autoscaler", autoscalersName) - log.Errorf("Falied to delete Keda existing %q autoscaler", autoscalersv2.Items[0].Name) - return fmt.Errorf("Falied to delete Keda existing %q autoscaler", autoscalersv2.Items[0].Name) + log.Errorf("Failed to delete Keda existing %q autoscaler", autoscalersv2.Items[0].Name) + return fmt.Errorf("failed to delete Keda existing %q autoscaler", autoscalersv2.Items[0].Name) - log.Errorf("falied to delete HPAV2 Resources : %s", err) + log.Errorf("failed to delete HPAV2 resources: %s", err) - log.Errorf("Falied to delete HPAV2 existing %q autoscaler", item.Name) - return fmt.Errorf("falied to delete HPAV2 existing %q autoscaler", item.Name) + log.Errorf("Failed to delete HPAV2 existing %q autoscaler", item.Name) + return fmt.Errorf("failed to delete HPAV2 existing %q autoscaler", item.Name) - log.Println("❌ Failed to find the promethues port") - return "", fmt.Errorf("Failed to find the promethues port") + log.Println("❌ Failed to find the prometheus port") + return "", fmt.Errorf("failed to find the prometheus port") - return fmt.Errorf("Error while crateiing APIService prometheus-adapter") + return fmt.Errorf("error while creating APIService prometheus-adapter") - return fmt.Errorf("Error while crateiing ClusterRole prometheus-adapter-resource-reader") + return fmt.Errorf("error while creating ClusterRole prometheus-adapter-resource-reader") - return fmt.Errorf("Error while crateiing ClusterRoleBinding prometheus-adapter-system-auth-delegator") + return fmt.Errorf("error while creating ClusterRoleBinding prometheus-adapter-system-auth-delegator") - return fmt.Errorf("Error while crateiing RoleBinding prometheus-adapter-auth-reader") + return fmt.Errorf("error while creating RoleBinding prometheus-adapter-auth-reader") - return fmt.Errorf("Error while crateiing ClusterRoleBinding prometheus-adapter-resource-reader") + return fmt.Errorf("error while creating ClusterRoleBinding prometheus-adapter-resource-reader")Optional: rename promethesNamespace → prometheusNamespace throughout for consistency.
Also applies to: 111-113, 133-135, 165-167, 433-435, 506-507, 542-563
357-365: Optional: narrow Prometheus selection.KubeList without a selector may pick an arbitrary Prometheus if multiple exist in the namespace. Consider filtering by labels or name to avoid ambiguity.
pkg/options/options.go (1)
182-184: Image/version mismatch: deploying 1.25.0 image with 1.27.0 manifests.This can drift behavior and APIs. If keeping 1.25.0 temporarily is intentional, add a TODO and track follow-up to switch to 1.27.0 when the noobaa-flavored image is published.
-var CnpgImage = "quay.io/noobaa/cloudnative-pg-noobaa:v1.25.0" +// TODO(DFBUGS-3830): bump to v1.27.0 once the noobaa-flavored image is built and published +var CnpgImage = "quay.io/noobaa/cloudnative-pg-noobaa:v1.25.0"pkg/cnpg/cnpg.go (2)
548-551: Hard-coding CRD count is brittle; prefer validating required CRD names.Upstream may add/remove CRDs across minors/patches. Instead of exact count, verify presence of the specific CRDs you require and warn on extras.
I can provide a helper that checks a set of required CRD names and reports which are missing/unexpected.
427-438: Nit: variable typo (mofifiedManifestBytes).Rename to modifiedManifestBytes for readability.
- mofifiedManifestBytes := bytes.ReplaceAll(manifestBytes, + modifiedManifestBytes := bytes.ReplaceAll(manifestBytes, []byte(originalGroup), []byte(noobaaGroupDomain)) ... - mofifiedManifestBytes = bytes.ReplaceAll(mofifiedManifestBytes, + modifiedManifestBytes = bytes.ReplaceAll(modifiedManifestBytes, []byte(originalPath), []byte(newPath)) ... - return mofifiedManifestBytes + return modifiedManifestBytes
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
💡 Knowledge Base configuration:
- MCP integration is disabled by default for public repositories
- Jira integration is disabled by default for public repositories
- Linear integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
⛔ Files ignored due to path filters (1)
go.sumis excluded by!**/*.sum
📒 Files selected for processing (4)
go.mod(7 hunks)pkg/cnpg/cnpg.go(1 hunks)pkg/options/options.go(1 hunks)pkg/system/autoscaler.go(1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (13)
- GitHub Check: run-operator-tests
- GitHub Check: run-kms-dev-test
- GitHub Check: run-core-config-map-tests
- GitHub Check: run-kms-key-rotate-test
- GitHub Check: run-cli-tests
- GitHub Check: cnpg-deployment-test
- GitHub Check: run-kms-tls-token-test
- GitHub Check: run-kms-kmip-test
- GitHub Check: run-hac-test
- GitHub Check: run-azure-vault-test
- GitHub Check: golangci-lint
- GitHub Check: run-admission-test
- GitHub Check: run-kms-tls-sa-test
🔇 Additional comments (3)
pkg/system/autoscaler.go (1)
366-366: Pointer return from getPrometheus is correct.Returning a pointer aligns with downstream signatures and avoids unnecessary struct copies. LGTM.
pkg/options/options.go (1)
180-180: Version bump to 1.27.0 looks good.Matches the dependency upgrade in go.mod and CRD count change.
go.mod (1)
39-39: Prometheus operator bump aligns with autoscaler fixes.No action needed; just flagging that dependent API changes likely motivated the pointer return from getPrometheus.
| module github.com/noobaa/noobaa-operator/v5 | ||
|
|
||
| go 1.24 | ||
| go 1.24.1 |
There was a problem hiding this comment.
Fix go directive: patch versions aren’t allowed here.
go.mod’s go line must be major.minor only. Use go 1.24 and optionally add a separate toolchain line for go1.24.1.
-go 1.24.1
+go 1.24
+toolchain go1.24.1📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| go 1.24.1 | |
| go 1.24 | |
| toolchain go1.24.1 |
🤖 Prompt for AI Agents
In go.mod around lines 3 to 3, the go directive currently specifies a patch
version ("go 1.24.1") which is invalid; change it to the major.minor form "go
1.24" and if you need to pin the exact toolchain add a separate "toolchain"
directive (e.g., "toolchain go1.24.1") instead of using a patch in the go line.
There was a problem hiding this comment.
@dannyzaken
The directive of the go version should only point to y stream
The toolchain will point to a specific z
There was a problem hiding this comment.
Seems like the humans are having a chat. I'll hop back into my burrow for now. If you need me again, just tag @coderabbitai in a new comment, and I'll come hopping out!
There was a problem hiding this comment.
I'll check it. I think it was set automatically by go.
There was a problem hiding this comment.
@dannyzaken The directive of the go version should only point to y stream The toolchain will point to a specific z
@liranmauda Are you sure about that? the go version is updated automatically to 1.24.1 by go mod tidy.
3c69ccf to
58b8a26
Compare
There was a problem hiding this comment.
Actionable comments posted: 3
♻️ Duplicate comments (1)
go.mod (1)
3-3: Fix go directive: patch versions aren’t allowed.Use major.minor only and add a separate toolchain pin.
-go 1.24.1 +go 1.24 +toolchain go1.24.1
🧹 Nitpick comments (1)
go.mod (1)
90-90: Prefer a tagged release over a pseudo-version for gorilla/websocket.Use a stable tag (e.g., v1.5.4) for reproducibility unless you specifically need that commit.
- github.com/gorilla/websocket v1.5.4-0.20250319132907-e064f32e3674 // indirect + github.com/gorilla/websocket v1.5.4 // indirect
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
💡 Knowledge Base configuration:
- MCP integration is disabled by default for public repositories
- Jira integration is disabled by default for public repositories
- Linear integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
⛔ Files ignored due to path filters (1)
go.sumis excluded by!**/*.sum
📒 Files selected for processing (5)
deploy/crds/noobaa.io_noobaas.yaml(0 hunks)go.mod(7 hunks)pkg/cnpg/cnpg.go(1 hunks)pkg/options/options.go(1 hunks)pkg/system/autoscaler.go(1 hunks)
💤 Files with no reviewable changes (1)
- deploy/crds/noobaa.io_noobaas.yaml
🚧 Files skipped from review as they are similar to previous changes (3)
- pkg/options/options.go
- pkg/cnpg/cnpg.go
- pkg/system/autoscaler.go
🧰 Additional context used
🧠 Learnings (1)
📚 Learning: 2025-06-25T15:42:04.436Z
Learnt from: Neon-White
PR: noobaa/noobaa-operator#1637
File: Makefile:193-203
Timestamp: 2025-06-25T15:42:04.436Z
Learning: golangci-lint v2.x versions output the version with a leading "v" prefix (e.g., "golangci-lint has version v2.1.6..."), while v1.x versions output without the "v" prefix (e.g., "golangci-lint has version 1.64.8..."). Version detection logic should account for the specific version format being targeted.
Applied to files:
go.mod
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (13)
- GitHub Check: cnpg-deployment-test
- GitHub Check: run-core-config-map-tests
- GitHub Check: run-cli-tests
- GitHub Check: run-azure-vault-test
- GitHub Check: run-kms-tls-token-test
- GitHub Check: run-kms-kmip-test
- GitHub Check: golangci-lint
- GitHub Check: run-operator-tests
- GitHub Check: run-kms-tls-sa-test
- GitHub Check: run-admission-test
- GitHub Check: run-kms-dev-test
- GitHub Check: run-hac-test
- GitHub Check: run-kms-key-rotate-test
🔇 Additional comments (1)
go.mod (1)
210-212: Compatibility check passed; no changes required.gRPC (v1.74.2), protobuf (v1.36.7) and genproto submodules (v0.0.0-20250528174236-200df99c418a) align with their upstream requirements.
| k8s.io/api v0.33.3 | ||
| k8s.io/apiextensions-apiserver v0.33.3 | ||
| k8s.io/apimachinery v0.33.3 | ||
| k8s.io/cli-runtime v0.33.3 | ||
| k8s.io/client-go v0.33.3 | ||
| k8s.io/code-generator v0.33.3 | ||
| k8s.io/gengo v0.0.0-20230829151522-9cce18d56c01 |
There was a problem hiding this comment.
💡 Verification agent
🧩 Analysis chain
Verify k8s library set is version-aligned with controller-runtime.
You’ve bumped core k8s libs to v0.33.3 and controller-runtime to v0.21.0. Ensure this matches the ctrl-runtime/k8s compatibility matrix to avoid subtle API/serializer mismatches.
Also applies to: 59-59, 64-64
🏁 Script executed:
#!/bin/bash
# List k8s.* and controller-runtime versions to spot strays
go list -m -json all | jq -r '
select(.Path|test("^(k8s.io/|sigs.k8s.io/controller-runtime$)"))
| "\(.Path) \(.Version)"
' | sort
# Show any mixed k8s minors (expect all 0.33.x except known exceptions like kube-aggregator/kubectl you intentionally keep older)
go list -m -json all | jq -r '
select(.Path|startswith("k8s.io/") and (.Path|test("^(k8s.io/(gengo|kube-openapi))")==false))
| .Version
' | sed -nE 's/^v0\.([0-9]+)\..*/\1/p' | sort -uLength of output: 2357
Align k8s module minors
- k8s.io/component-helpers (v0.25.4) and k8s.io/metrics (v0.25.4) remain on older minors while core libs are at v0.33.3—bump them to v0.33.3 or explicitly document them as intentional exceptions.
- Verify sigs.k8s.io/controller-runtime v0.21.0 is compatible with k8s v0.33.x per the official compatibility matrix.
🤖 Prompt for AI Agents
In go.mod around lines 49–55, k8s.io/component-helpers and k8s.io/metrics are
left at older minor versions while core k8s libs are at v0.33.3; bump those
modules to v0.33.3 (or add a comment explaining the intentional exception), then
verify sigs.k8s.io/controller-runtime v0.21.0 compatibility with Kubernetes
v0.33.x per the official compatibility matrix and upgrade/downgrade
controller-runtime to a compatible release if needed; after changing versions
run go mod tidy and full build/test to ensure no dependency or API breakages.
a40724d to
f3b3aad
Compare
There was a problem hiding this comment.
Actionable comments posted: 0
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (2)
pkg/system/system.go (2)
895-900: Don’t ignore res.Requeue; current loop may exit prematurely.Reconciler requests with
Requeue==true(and zeroRequeueAfter) will now be treated as “done,” potentially stopping before the system stabilizes.Apply:
- if res.RequeueAfter != 0 { - log.Printf("\nRetrying in %d seconds\n", interval) - return false, nil - } + if res.Requeue || res.RequeueAfter > 0 { + if res.RequeueAfter > 0 { + log.Printf("\nRetrying in %s\n", res.RequeueAfter) + } else { + log.Printf("\nRetrying immediately\n") + } + return false, nil + }
680-683: Wrong field used for desired image.When
sys.Spec.Image != nil, this assignsDBImageinstead ofImage.- } else if sys.Spec.Image != nil { - desiredImage = *sys.Spec.DBImage + } else if sys.Spec.Image != nil { + desiredImage = *sys.Spec.Image
♻️ Duplicate comments (2)
go.mod (2)
3-3: Fix go directive: patch versions aren’t allowed.Use major.minor and add a
toolchainline.-go 1.24.1 +go 1.24 +toolchain go1.24.1
49-59: Verify k8s/controller-runtime minor alignment and older module pins.You’ve got k8s v0.33.x with controller-runtime v0.21.0 alongside older
kube-aggregator v0.27.1andkubectl v0.25.4. Please confirm compatibility or bump/pin intentionally.Run:
#!/bin/bash # Show controller-runtime and k8s minors go list -m -json all | jq -r ' select(.Path=="sigs.k8s.io/controller-runtime" or (.Path|startswith("k8s.io/"))) | "\(.Path) \(.Version)" ' | sortAlso applies to: 64-64
🧹 Nitpick comments (2)
pkg/cnpg/cnpg.go (2)
548-551: Avoid fragile CRD hard-count; tolerate additions while guarding against missing core CRDs.Pinning to an exact count breaks on upstream adding CRDs. Require a minimum and allow extras.
- expectedNumberOfCrds := 10 - if len(cnpgRes.CRDs) != expectedNumberOfCrds { - return nil, fmt.Errorf("expected %d CustomResourceDefinitions, got %d", expectedNumberOfCrds, len(cnpgRes.CRDs)) - } + const minExpectedCRDs = 10 + if len(cnpgRes.CRDs) < minExpectedCRDs { + return nil, fmt.Errorf("expected at least %d CustomResourceDefinitions for CNPG %s, got %d", + minExpectedCRDs, options.CnpgVersion, len(cnpgRes.CRDs)) + }
427-439: Typo: “mofifiedManifestBytes” → “modifiedManifestBytes”.Minor readability fix.
- mofifiedManifestBytes := bytes.ReplaceAll(manifestBytes, + modifiedManifestBytes := bytes.ReplaceAll(manifestBytes, []byte(originalGroup), []byte(noobaaGroupDomain)) ... - mofifiedManifestBytes = bytes.ReplaceAll(mofifiedManifestBytes, + modifiedManifestBytes = bytes.ReplaceAll(modifiedManifestBytes, []byte(originalPath), []byte(newPath)) - return mofifiedManifestBytes + return modifiedManifestBytes
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
💡 Knowledge Base configuration:
- MCP integration is disabled by default for public repositories
- Jira integration is disabled by default for public repositories
- Linear integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
⛔ Files ignored due to path filters (1)
go.sumis excluded by!**/*.sum
📒 Files selected for processing (7)
deploy/crds/noobaa.io_noobaas.yaml(0 hunks)go.mod(7 hunks)pkg/bundle/deploy.go(1 hunks)pkg/cnpg/cnpg.go(1 hunks)pkg/options/options.go(1 hunks)pkg/system/autoscaler.go(1 hunks)pkg/system/system.go(1 hunks)
💤 Files with no reviewable changes (1)
- deploy/crds/noobaa.io_noobaas.yaml
🚧 Files skipped from review as they are similar to previous changes (3)
- pkg/options/options.go
- pkg/system/autoscaler.go
- pkg/bundle/deploy.go
🧰 Additional context used
🧠 Learnings (1)
📚 Learning: 2025-06-25T15:42:04.436Z
Learnt from: Neon-White
PR: noobaa/noobaa-operator#1637
File: Makefile:193-203
Timestamp: 2025-06-25T15:42:04.436Z
Learning: golangci-lint v2.x versions output the version with a leading "v" prefix (e.g., "golangci-lint has version v2.1.6..."), while v1.x versions output without the "v" prefix (e.g., "golangci-lint has version 1.64.8..."). Version detection logic should account for the specific version format being targeted.
Applied to files:
go.mod
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (12)
- GitHub Check: cnpg-deployment-test
- GitHub Check: run-core-config-map-tests
- GitHub Check: run-cli-tests
- GitHub Check: run-kms-tls-sa-test
- GitHub Check: run-kms-tls-token-test
- GitHub Check: run-kms-kmip-test
- GitHub Check: run-operator-tests
- GitHub Check: run-kms-key-rotate-test
- GitHub Check: run-admission-test
- GitHub Check: run-azure-vault-test
- GitHub Check: run-hac-test
- GitHub Check: run-kms-dev-test
Signed-off-by: Danny Zaken <dannyzaken@gmail.com>
f3b3aad to
3bd3be9
Compare
There was a problem hiding this comment.
Actionable comments posted: 0
♻️ Duplicate comments (2)
go.mod (2)
49-55: Verify ctrl-runtime/k8s minor compatibilitycontroller-runtime v0.21.0 with k8s v0.33.3 should match the official matrix; please double-check to avoid subtle API/serializer issues.
Also applies to: 64-64
3-3: Fix go directive: patch versions aren’t allowedUse major.minor and add a separate toolchain pin.
-go 1.24.1 +go 1.24 +toolchain go1.24.1
🧹 Nitpick comments (4)
pkg/noobaaaccount/noobaaaccount.go (1)
668-671: Reconcile loop now ignores res.Requeue; verify no callers rely on itIf any reconciler returns Requeue=true without RequeueAfter, this loop will prematurely stop. Either confirm that never happens or reintroduce the Requeue check.
Also fix the retry log to show actual durations:
- if res.RequeueAfter != 0 { - log.Printf("\nRetrying in %d seconds\n", interval) - return false, nil - } + if res.RequeueAfter != 0 { + log.Printf("\nController requested requeue after %s; CLI poll interval is %s\n", + res.RequeueAfter.Round(time.Second), interval*time.Second) + return false, nil + }pkg/backingstore/backingstore.go (1)
1054-1057: Behavior change: only RequeueAfter triggers retryDropping res.Requeue can exit early if a reconciler sets only Requeue=true. Please verify upstream reconcilers or keep the fallback.
Improve the retry log to reflect real timing:
- if res.RequeueAfter != 0 { - log.Printf("\nRetrying in %d seconds\n", interval) - return false, nil - } + if res.RequeueAfter != 0 { + log.Printf("\nController requested requeue after %s; CLI poll interval is %s\n", + res.RequeueAfter.Round(time.Second), interval*time.Second) + return false, nil + }pkg/bucketclass/bucketclass.go (1)
578-581: Retry condition narrowed; confirm no plain Requeue usages remainExiting when RequeueAfter==0 ignores Requeue=true. Validate callers or restore the Requeue check.
Tweak the log for accurate duration output:
- if res.RequeueAfter != 0 { - log.Printf("\nRetrying in %d seconds\n", interval) - return false, nil - } + if res.RequeueAfter != 0 { + log.Printf("\nController requested requeue after %s; CLI poll interval is %s\n", + res.RequeueAfter.Round(time.Second), interval*time.Second) + return false, nil + }go.mod (1)
21-21: CNPG 1.27.0 bump: align images/CRDs and docsSince module is now v1.27.0, ensure:
- default CNPG image tag is updated (still 1.25.0 per PR notes),
- noobaa-flavor 1.27.0 image is built/pushed,
- CRD count/validation and docs reflect 1.27.0.
Happy to draft a follow-up PR/issue checklist for the image build and doc updates.
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
💡 Knowledge Base configuration:
- MCP integration is disabled by default for public repositories
- Jira integration is disabled by default for public repositories
- Linear integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
⛔ Files ignored due to path filters (1)
go.sumis excluded by!**/*.sum
📒 Files selected for processing (11)
deploy/crds/noobaa.io_noobaas.yaml(0 hunks)go.mod(7 hunks)pkg/backingstore/backingstore.go(1 hunks)pkg/bucketclass/bucketclass.go(1 hunks)pkg/bundle/deploy.go(1 hunks)pkg/cnpg/cnpg.go(1 hunks)pkg/namespacestore/namespacestore.go(1 hunks)pkg/noobaaaccount/noobaaaccount.go(1 hunks)pkg/options/options.go(1 hunks)pkg/system/autoscaler.go(1 hunks)pkg/system/system.go(1 hunks)
💤 Files with no reviewable changes (1)
- deploy/crds/noobaa.io_noobaas.yaml
🚧 Files skipped from review as they are similar to previous changes (5)
- pkg/cnpg/cnpg.go
- pkg/system/autoscaler.go
- pkg/bundle/deploy.go
- pkg/system/system.go
- pkg/options/options.go
🧰 Additional context used
🧠 Learnings (1)
📚 Learning: 2025-06-25T15:42:04.436Z
Learnt from: Neon-White
PR: noobaa/noobaa-operator#1637
File: Makefile:193-203
Timestamp: 2025-06-25T15:42:04.436Z
Learning: golangci-lint v2.x versions output the version with a leading "v" prefix (e.g., "golangci-lint has version v2.1.6..."), while v1.x versions output without the "v" prefix (e.g., "golangci-lint has version 1.64.8..."). Version detection logic should account for the specific version format being targeted.
Applied to files:
go.mod
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (13)
- GitHub Check: run-admission-test
- GitHub Check: run-core-config-map-tests
- GitHub Check: golangci-lint
- GitHub Check: cnpg-deployment-test
- GitHub Check: run-kms-tls-token-test
- GitHub Check: run-hac-test
- GitHub Check: run-kms-key-rotate-test
- GitHub Check: run-kms-kmip-test
- GitHub Check: run-kms-tls-sa-test
- GitHub Check: run-kms-dev-test
- GitHub Check: run-operator-tests
- GitHub Check: run-cli-tests
- GitHub Check: run-azure-vault-test
🔇 Additional comments (1)
pkg/namespacestore/namespacestore.go (1)
889-893: Verify Requeue fallback and improve log output
No occurrences of plain
Requeue: truefound—ensure no reconciler relies solely onRequeueor restore a fallback for{Requeue:true, RequeueAfter:0}.Optional: format durations with
%sfor clarity:if res.RequeueAfter != 0 {log.Printf("\nRetrying in %d seconds\n", interval)
log.Printf("\nController requested requeue after %s; CLI poll interval is %s\n", }res.RequeueAfter.Round(time.Second), interval*time.Second) return false, nil
Explain the changes
Gaps
1.25.0. This is only used for development environments, and it functions as intended.Issues: Fixed #xxx / Gap #xxx
Testing Instructions:
Summary by CodeRabbit