Skip to content
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

Make stdout maxBuffer length to be configurable #4061

Conversation

vrubezhny
Copy link
Contributor

The default value is set to 4Gb.

Fixes: #3925

@vrubezhny vrubezhny force-pushed the fix-stdout-maxBuffer-length-exceeded branch 2 times, most recently from 9c076a9 to 005e31a Compare April 13, 2024 12:13
The default value is set to 4Gb.

Fixes: redhat-developer#3925

Signed-off-by: Victor Rubezhny <vrubezhny@redhat.com>
@vrubezhny vrubezhny force-pushed the fix-stdout-maxBuffer-length-exceeded branch from 005e31a to 7570b24 Compare April 13, 2024 13:49
@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 45.04%. Comparing base (da60441) to head (7570b24).
Report is 170 commits behind head on main.

Additional details and impacted files
@@             Coverage Diff             @@
##             main    #4061       +/-   ##
===========================================
+ Coverage   32.37%   45.04%   +12.66%     
===========================================
  Files          85       85               
  Lines        6505     6720      +215     
  Branches     1349     1404       +55     
===========================================
+ Hits         2106     3027      +921     
+ Misses       4399     3693      -706     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@datho7561
Copy link
Contributor

With this change, I am able to open the "Pods" and "Deployments" sections if I create 100 deployments. I am going to stress test 400 to see what happens.

@vrubezhny
Copy link
Contributor Author

vrubezhny commented Apr 15, 2024

With this change, I am able to open the "Pods" and "Deployments" sections if I create 100 deployments. I am going to stress test 400 to see what happens.

The number of pods really matters: the error (ERR_CHILD_PROCESS_STDIO_MAXBUFFER) happens when executing oc get pods -o=json , and according to the reporter and @lgrossma 's experience it takes place when the number of pods is 200+ (with old default stdout buffer limit equal to 2MiB. If you're using this PR when testing you can set openshiftToolkit.execMaxBufferLength to 2 ( === 2*1024*1024) to make it word exactly as it did before the change) .

Copy link
Contributor

@datho7561 datho7561 left a comment

Choose a reason for hiding this comment

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

4 MB allows for viewing over 400 deployments, this should (hopefully) be plenty

@datho7561
Copy link
Contributor

I used

#!/usr/bin/lua

for i = 1, 400, 1 do
  os.execute(string.format('oc create deployment --image quay.io/davthomp/pet-alpine my-pet-deploy%d', i));
end

To create 400 deployments, each with one pod. I opened both the deployments and the pods sections. No crashes occured, it loaded properly.

@datho7561 datho7561 merged commit 42f4eaa into redhat-developer:main Apr 15, 2024
4 checks passed
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.

stdout maxBuffer length exceeded
3 participants