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
k8s:watch port forward websocket error #653
Comments
This is really weird. Services depending on this method work (debug, watch, etc.) |
@PengtaoNing :
Could you please provide more details on how to reproduce it? |
I think you're right. I just ran a quick simple port forward using client and looks like argument should be |
👍 Then we need to create an issue there. |
Umm, why issue there? Isn't the issue in our code that arguments are inverted? I'm not sure how it's working. Maybe we tested it for cases when both remotePort and localPort are same? |
Well, you just tested in our repo and seems that things work fine. The easiest case to test is for debug where we use the standard Java remote debug port (5005) and point it to the exposed container port. What's clear is that the variable names are not OK, either here or in the client. |
After recently checking the SpringBootWatch implementation which is not working ATM, it seems that the order of the parameters/arguments might be wrong at some places. For SpringBootWatcher, changing this line: portForwardService.forwardPortAsync(selector, port, containerPort); seems to fix the current issue and the SpringBootWatcher works again. We need to properly name the variables, check which classes are consuming the PortForwardService, and make sure that the method invocations contain the parameters in the proper order. |
@ningpengtao-coder : Thanks a lot for reporting this! You're right about the arguments being inversed. I made a mistake while testing it earlier and now when Marc and I tested the complete flow of the watch, we realized it's broken. LiveReload doesn't happen during For
I'll update the arguments in order to address these issues. |
…o wrong arguments in PortForwardService Make order of port forward arguments consistent across Service classes. Now all methods have containerPort, remotePort argument format Signed-off-by: Rohan Kumar <rohaan@redhat.com>
…o wrong arguments in PortForwardService Make order of port forward arguments consistent across Service classes. Now all methods have containerPort, remotePort argument format Signed-off-by: Rohan Kumar <rohaan@redhat.com>
…o wrong arguments in PortForwardService Make order of port forward arguments consistent across Service classes. Now all methods have containerPort, remotePort argument format Signed-off-by: Rohan Kumar <rohaan@redhat.com>
…o wrong arguments in PortForwardService Make order of port forward arguments consistent across Service classes. Now all methods have containerPort, remotePort argument format Signed-off-by: Rohan Kumar <rohaan@redhat.com>
The order of the two variables of the forwardPortAsync method of PortForwardService is reversed, resulting in port-forward not working.
code line: PortForwardService.java line 219
Affected version: 1.1.0 1.1.1 1.2.0
The text was updated successfully, but these errors were encountered: