fix(ROSAENG-67571): migrate OSL severity labels to HCC-aligned values - #975
openshift-merge-bot[bot] merged 3 commits into
Conversation
Replace deprecated OCM Service Log severity labels with new HCC-aligned values ahead of the Phase 2 enforcement cutoff (28 September 2026): - Warning -> Moderate (cmd/cluster/support/post.go) - Info -> Low (cmd/servicelog/post.go hardcoded templates) Update all test data in servicelog, cluster/support, and hcp/transitiontoeus packages to use the new severity values. After this change, no references to deprecated severity labels (Major, Warning, Info) remain in osdctl service log code paths. Related to ROSAENG-67571
|
Important Review skippedBot user detected. To trigger a single review, invoke the ⚙️ Run configurationConfiguration used: Repository: openshift/coderabbit/.coderabbit.yaml Review profile: CHILL Plan: Advanced Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Comment |
|
Hi @fullsend-ai-coder[bot]. Thanks for your PR. I'm waiting for a openshift member to verify that this patch is reasonable to test. If it is, they should reply with Regular contributors should join the org to skip this step. Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. DetailsInstructions 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. |
|
/fs-fix Use the ocm sdk constants instead of string literals |
|
🤖 Finished Fix · ✅ Success · Started 11:11 AM UTC · Completed 11:29 AM UTC Commit: Runtime: claude · Model: opus → claude-opus-4-6 · Effort: high · Cost: $3.29 |
Replace hardcoded severity string literals ("Moderate", "Low") with
typed constants from the OCM SDK servicelogs/v1 package
(slv1.SeverityModerate, slv1.SeverityLow). The SDK dependency is
already at v0.1.507 which includes these constants.
- cmd/cluster/support/post.go: InternalServiceLogSeverity now uses
slv1.SeverityModerate constant
- cmd/servicelog/post.go: internal-only and pre-canned templates set
severity via slv1.SeverityLow after JSON parsing
- Test files: Go struct severity fields use string(slv1.SeverityLow)
while JSON test fixtures remain as string literals (API responses)
Addresses #975
🔧 Fix agent — iteration 1 (human-triggered)Replaced all hardcoded severity string literals with OCM SDK typed constants (slv1.SeverityModerate, slv1.SeverityLow) across source and test files, per human instruction Fixed (5):
Tests: passed CI inspections (2):
Decision points
Next steps:
|
|
@coderabbitai review |
|
/fs-review |
|
/test all |
|
/retest |
2 similar comments
|
/retest |
|
/retest |
|
/fs-fix There is wrong formatting here failing ci, please fix |
|
🤖 Finished Fix · ✅ Success · Started 1:44 PM UTC · Completed 2:02 PM UTC Commit: Runtime: claude · Model: opus → claude-opus-4-6 · Effort: high · Cost: $1.35 |
Apply gofmt formatting to InternalServiceLogSeverity constant declaration to fix tab alignment with the typed constant annotation. Addresses #975
🔧 Fix agent — iteration 2 (human-triggered)Fixed gofmt alignment issue in cmd/cluster/support/post.go that was causing ci/prow/format CI failure. The InternalServiceLogSeverity typed constant had incorrect tab spacing around the type annotation. Fixed (1):
Tests: failed CI inspections (5):
Decision points
Next steps:
|
|
/ok-to-test |
|
@fullsend-ai-coder[bot]: all tests passed! Full PR test history. Your PR dashboard. DetailsInstructions 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. |
|
/lgtm |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: dustman9000, fullsend-ai-coder[bot] The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Summary
Migrate all deprecated OCM Service Log severity labels in
osdctlto the new HCC-aligned values, ahead of the Phase 2 enforcement cutoff (28 September 2026).Changes
cmd/cluster/support/post.go: UpdatedInternalServiceLogSeverityconstant from"Warning"to"Moderate"— this is used when posting internal service logs for limited support evidencecmd/servicelog/post.go: Updated two hardcoded JSON templates (internal-only and pre-canned override templates) from"severity": "Info"to"severity": "Low"cmd/servicelog/common_test.go,cmd/servicelog/post_test.go, andcmd/hcp/transitiontoeus/transitiontoeus_test.goto use the new severity valuesSeverity label mapping
MajorImportantWarningModerateInfoLowNo references to
Major,Warning, orInforemain in osdctl service log code paths after this change.The OCM SDK dependency is already at v0.1.507 (>= v0.1.505), which includes the typed severity constants (
SeverityImportant,SeverityModerate,SeverityLow).Testing
go testfor all affected packages (cmd/cluster/support,cmd/servicelog,cmd/hcp/transitiontoeus) — all tests passgo veton affected packages — no issuesRelated to https://redhat.atlassian.net/browse/ROSAENG-67571
Post-script verification
agent/ROSAENG-67571-67571-migrate-severity-labels)eee6ca84887165d0604d2d1e9d01ef42eb98c00f..HEAD)