-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Exec writingErrorChannel is not an error channel #3793
Comments
No, this is a request to rename writingErrorChannel to writingCloseChannel. In the other java client they refer to it as Exec.getConnectionErrorStream. The python client calls it error-channel https://github.com/kubernetes-client/python/blob/cc9ae10549db26dd1391de55f0da2f4946de4ad7/stream/ws_client.py#L36 - so there's little consistency. This probably could be addressed with better javadocs on getErrorChannel and related methods. |
Adding better javadocs with #4115 |
Is your enhancement related to a problem? Please describe
When executing a command in a container, a
io.fabric8.kubernetes.api.model.Status
is sent (whatever the status, success or failure)Here is an example on the Kubernetes-client from kubernetes team:
https://github.com/kubernetes-client/java/blob/ae3bb03f8f0a5a3915941506eec4c667785b6e0d/util/src/main/java/io/kubernetes/client/Exec.java#L495
If the command execution failed the Status will like:
They then parse the status code: https://github.com/kubernetes-client/java/blob/ae3bb03f8f0a5a3915941506eec4c667785b6e0d/util/src/main/java/io/kubernetes/client/Exec.java#L444
If the command was successfully executed it will be like this:
This status is always sent.
In fabric8 this streamID 3 is considered as en errorChannel (which seems not correct):
https://github.com/fabric8io/kubernetes-client/blob/master/kubernetes-client/src/main/java/io/fabric8/kubernetes/client/dsl/internal/ExecWebSocketListener.java#L247
Here is an example of usage:
Describe the solution you'd like
Just renaming
writingErrorChannel
towritingCloseChannel
Describe alternatives you've considered
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: