Commit 9fdd99b
authored
fix: rendering glitches when a Workspace is stopped (#102)
… while an SSH connection is alive.
Toolbox raises a class cast exception when Workspaces are stopped while
the SSH connection is running. After the workspace was stopped Toolbox
refused to show widget with some weird glitches on the screen.
The fix in this case is to safely disconnect the SSH before sending the
stop command to the workspace. The code will wait at most 10 seconds for
the disconnect to happen, and only after that send the stop.
- resolves #981 parent 970f4c5 commit 9fdd99b
File tree
4 files changed
+48
-12
lines changed- src/main/kotlin/com/coder/toolbox
- util
4 files changed
+48
-12
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
9 | 13 | | |
10 | 14 | | |
11 | 15 | | |
| |||
Lines changed: 22 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| 10 | + | |
10 | 11 | | |
11 | 12 | | |
12 | 13 | | |
| |||
43 | 44 | | |
44 | 45 | | |
45 | 46 | | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
46 | 51 | | |
47 | 52 | | |
48 | 53 | | |
| |||
106 | 111 | | |
107 | 112 | | |
108 | 113 | | |
| 114 | + | |
| 115 | + | |
109 | 116 | | |
110 | 117 | | |
111 | 118 | | |
| |||
115 | 122 | | |
116 | 123 | | |
117 | 124 | | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
118 | 137 | | |
119 | 138 | | |
120 | 139 | | |
121 | 140 | | |
122 | 141 | | |
123 | 142 | | |
124 | | - | |
| 143 | + | |
125 | 144 | | |
126 | 145 | | |
127 | 146 | | |
128 | 147 | | |
129 | | - | |
| 148 | + | |
130 | 149 | | |
131 | 150 | | |
132 | 151 | | |
| |||
161 | 180 | | |
162 | 181 | | |
163 | 182 | | |
164 | | - | |
165 | | - | |
166 | | - | |
167 | 183 | | |
168 | 184 | | |
169 | 185 | | |
170 | 186 | | |
171 | 187 | | |
172 | 188 | | |
173 | 189 | | |
174 | | - | |
| 190 | + | |
175 | 191 | | |
176 | 192 | | |
177 | 193 | | |
| |||
Lines changed: 0 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
16 | | - | |
17 | 16 | | |
18 | 17 | | |
19 | 18 | | |
| |||
331 | 330 | | |
332 | 331 | | |
333 | 332 | | |
334 | | - | |
335 | | - | |
336 | | - | |
337 | | - | |
338 | | - | |
339 | 333 | | |
Lines changed: 22 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
0 commit comments