Skip to content

fix: kubectl argument too long when updating release cr #1221

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

arewm
Copy link
Member

@arewm arewm commented Jul 16, 2025

Describe your changes

Most of the development and CI has been done assuming smaller Snapshots. When releasing larger snapshots (i.e. 180 components), we start to encounter issues ranging from higher likelihood to hit timeouts, increased memory consumption, and long strings being processed.

This PR is focused on fixing an issue where update-cr-status could not process large snapshots, namely because we were passing too much information to kubectl.

Partially addresses: KONFLUX-8821 in conjunction with #1218, #1219, #1220

Assisted-by: Cursor
Signed-off-by: arewm [email protected]

Relevant Jira

Checklist before requesting a review

  • I have marked as draft or added do not merge label if there's a dependency PR
    • If you want reviews on your draft PR, you can add reviewers or add the release-service-maintainers handle if you are unsure who to tag
  • My commit message includes Signed-off-by: My name <email>
  • I read CONTRIBUTING.MD and commit formatting
  • I have run the README.md generator script in .github/scripts/readme_generator.sh and verified the results using .github/scripts/check_readme.sh

Copy link
Contributor

@FilipNikolovski FilipNikolovski left a comment

Choose a reason for hiding this comment

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

lgtm apart from the lint errors.

@johnbieren
Copy link
Collaborator

This fails gitlint, yamllint, unit tests, and has a rebase conflict

@arewm
Copy link
Member Author

arewm commented Jul 22, 2025

Converting to draft as I need to check to see whether #1214 resolves this same issue.

@arewm arewm marked this pull request as draft July 22, 2025 02:32
@arewm arewm force-pushed the support-large-snapshots-update-cr-status branch from 9179b08 to 74859cd Compare July 28, 2025 12:36
@arewm
Copy link
Member Author

arewm commented Jul 28, 2025

This PR is ready for review again. #1214 duplicated much of the work for this PR, so now it is distilled down just to the status update issue.

@arewm arewm marked this pull request as ready for review July 28, 2025 12:37
@arewm arewm enabled auto-merge (squash) July 28, 2025 12:38
@arewm arewm changed the title Support large snapshots update cr status fix: kubectl argument too long when updating release cr Jul 28, 2025
@openshift-ci openshift-ci bot added the lgtm label Jul 28, 2025
@johnbieren johnbieren force-pushed the support-large-snapshots-update-cr-status branch from 2cbab8d to a8b35eb Compare July 28, 2025 14:23
@openshift-ci openshift-ci bot removed the lgtm label Jul 28, 2025
Copy link

openshift-ci bot commented Jul 28, 2025

New changes are detected. LGTM label has been removed.

@johnbieren
Copy link
Collaborator

⚠️ Warning: Could not get component PR from annotations: {"pac":{"state":"error","error-id":74,"error-message":"74: Access token is unrecognizable by GitHub"},"message":"done"}
Requesting a new configure-pac...
component.appstudio.redhat.com/rhtap-service-push-b8455b79 annotate
Waiting 10 seconds before retry...
Initialization check attempt 58/60...

I haven't seen that before

@johnbieren johnbieren force-pushed the support-large-snapshots-update-cr-status branch from bfbe1ab to 0652b95 Compare July 28, 2025 23:10
@johnbieren
Copy link
Collaborator

/retest

When patching the Release with a lot of information, we are putting too
much into the command line to be able to be processed. We can use a
patch file instead of passing it all in the command line.

Assisted-by: Cursor
Signed-off-by: arewm <[email protected]>

rh-pre-commit.version: 2.3.2
rh-pre-commit.check-secrets: ENABLED
@scoheb scoheb force-pushed the support-large-snapshots-update-cr-status branch from ce05deb to a43ffdc Compare July 29, 2025 21:32
@arewm arewm merged commit fd40f2b into konflux-ci:development Jul 29, 2025
18 of 19 checks passed
@konflux-ci-qe-bot
Copy link

@arewm: The following test has Failed, say /retest to rerun failed tests.

PipelineRun Name Status Rerun command Build Log Test Log
push-to-external-registry-e2e-test-go-jslpl Failed /retest View Pipeline Log View Test Logs

Inspecting Test Artifacts

To inspect your test artifacts, follow these steps:

  1. Install ORAS (see the ORAS installation guide).
  2. Download artifacts with the following commands:
mkdir -p oras-artifacts
cd oras-artifacts
oras pull quay.io/konflux-test-storage/konflux-team/release-service-catalog:push-to-external-registry-e2e-test-go-jslpl

Test results analysis

🚨 Error occurred while running the E2E tests, list of failed Spec(s):

➡️ [failed] [It] [release-pipelines-suite Push to external registry] Post-release verification verifies that Release PipelineRun should eventually succeed [release-pipelines, push-to-external-registry]

Click to view logs

Error when waiting for a release pipelinerun for release ex-registry-mbfe/snapshot-sample-ndyw-wtdgd to finish
Expected success, but got an error:
    <*errors.errorString | 0xc000efc9e0>: 
    Pipelinerun 'managed-m4f6c' didn't succeed
    Logs from failed container 'managed-m4f6c-verify-conforma/step-show-config': 
    jq: error: Could not open file /tekton/home/report-json.json: No such file or directory
    
    {
        s: "Pipelinerun 'managed-m4f6c' didn't succeed\nLogs from failed container 'managed-m4f6c-verify-conforma/step-show-config': \njq: error: Could not open file /tekton/home/report-json.json: No such file or directory\n",
    }

@arewm arewm deleted the support-large-snapshots-update-cr-status branch July 29, 2025 23:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants