-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
The copyFileToPodAsync method causes the process to fail to close! #3401
Comments
You can manually close it after the upload is completed
|
Hello, I use this method, but it will report an Error every time: "Error on flush, java.io.IOException: Socket is closed!" Is this normal? Where the file is finished uploading. |
|
The same is true when I uploaded a small file (less than 1M). I suspect that pod could not know the end of the uploaded file, so it would hang on forever, which would cause this problem when we proactively closed. |
Describe the bug
Hello. I refer to the link "https://github.com/kubernetes-client/java/blob/master/util/src/main/java/io/kubernetes/client/Copy.java" to write file upload Code, found that the code will get stuck in "proc.waitFor(); "This step. I think it is not the output stream that can not be closed all the time. Is there any good method?
I tried to comment out "proc.waitFor()" and "proc.destroy()" in full, and I was able to complete the file upload, but this should cause problems such as memory leaks.
Kubernetes Version
e.g.
1.15.0
Java Version
e.g. Java 8
To Reproduce
Expected behavior
A clear and concise description of what you expected to happen.
KubeConfig
If applicable, add a KubeConfig file with secrets redacted.
The text was updated successfully, but these errors were encountered: