Commit 856156b
committed
[SPARK-3555] Fix UISuite race condition
The test "jetty selects different port under contention" is flaky.
If another process binds to 4040 before the test starts, then the first server we start there will fail, and the subsequent servers we start thereafter may successfully bind to 4040 if it was released between the servers starting. Instead, we should just let Java find a random free port for us and hold onto it for the duration of the test.
Author: Andrew Or <[email protected]>
Closes #2418 from andrewor14/fix-port-contention and squashes the following commits:
0cd4974 [Andrew Or] Stop them servers
a7071fe [Andrew Or] Pick random port instead of 4040
(cherry picked from commit 0a7091e)
Signed-off-by: Andrew Or <[email protected]>1 parent 75158a7 commit 856156b
1 file changed
Lines changed: 5 additions & 9 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
27 | | - | |
28 | 27 | | |
29 | 28 | | |
30 | 29 | | |
| |||
95 | 94 | | |
96 | 95 | | |
97 | 96 | | |
98 | | - | |
99 | | - | |
100 | | - | |
101 | | - | |
102 | | - | |
103 | | - | |
104 | | - | |
105 | | - | |
| 97 | + | |
| 98 | + | |
106 | 99 | | |
107 | 100 | | |
108 | 101 | | |
| |||
113 | 106 | | |
114 | 107 | | |
115 | 108 | | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
116 | 112 | | |
117 | 113 | | |
118 | 114 | | |
| |||
0 commit comments