gitpod
gitpod copied to clipboard
fix(jetbrains): gateway plugin hands on auth issue
Description
This PR aims to improve the user experience when connecting to a workspace using an expired token: The JB Gateway plugin refreshes the token, however while handling the first failed request exepction, the ClientContainer will hang for about 30 seconds while stopping.
After investigating deep into the implementation, we believe that the time is given to any existing client connection to be shutdown gracefully. By setting the stop timeout to zero, we effectively revoke this opportunity, however, in our case, we are confident that there are no more active connections so we can safely remove this period of time, which only slows down the opening of the IDE.
Related Issue(s)
Fixes #12862
How to test
- Install this version of the JB Gateway Plugin
- Start a workspace in this prev env
- Open the workspace with any JetBrains IDE (any version)
- Observe how everything works as expected
- Now open a workspace for gitpod in gitpod.io
- Connect to the prev env database and delete the token
- Close the JB Gateway and therefore any IDE windows
- Delete the token from the database
- Re-open the prev env workspace and observe how it re-opens without any delays. Especially once the JetBrains Gateway opens, there should not be any unexpected delay before the IDE opens.
Release Notes
JetBrains Gateway: Avoid 30 seconds delay when connecting to a workspace using an expired token
Documentation
Werft options:
- [x] /werft with-preview
- [x] /werft with-large-vm
- [ ] /werft with-integration-tests=all
Valid options are
all,workspace,webapp,ide