Commit 7037972
authored
Wait for the Dart plugin to start the DevTools server with retries (#8177)
Fixes #8144
This PR:
* Makes sure we only ever have one connected DevTools server
* Tracks the start-up of the DevTools server using the [Progress API](https://plugins.jetbrains.com/docs/intellij/background-processes.html) instead of `executeOnPooledThread` (logic pulled into `DevToolsServerTask.java`). This allows us to display the progress and cancel the server startup on `forceRestart`.
* Retries waiting for the Dart plugin initiated DevTools server until a timeout is reached
* If the Dart plugin DevTools is not ready by the timeout, switching to a new Flutter panel will re-trigger starting the server
### Server start-up status:
<img width="466" alt="Screenshot 2025-05-09 at 12 40 31 PM" src="https://github.com/user-attachments/assets/8f9d7579-426d-4ef9-8f85-bc0789320d52" />
### Message if waiting for the server timed out:
<img width="501" alt="Screenshot 2025-05-09 at 1 26 55 PM" src="https://github.com/user-attachments/assets/25ef03e6-6d5e-44ee-9c29-5276912b3427" />
### Loaded Property Editor:
<img width="904" alt="Screenshot 2025-05-09 at 12 39 37 PM" src="https://github.com/user-attachments/assets/f538f835-2015-4289-ade4-76514088575c" />1 parent d029a3b commit 7037972
File tree
4 files changed
+482
-265
lines changed- flutter-idea/src/io/flutter
- devtools
- run/daemon
- view
4 files changed
+482
-265
lines changedLines changed: 44 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| 9 | + | |
9 | 10 | | |
10 | 11 | | |
| 12 | + | |
| 13 | + | |
11 | 14 | | |
12 | 15 | | |
13 | 16 | | |
| |||
42 | 45 | | |
43 | 46 | | |
44 | 47 | | |
45 | | - | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
46 | 52 | | |
47 | 53 | | |
48 | 54 | | |
| |||
98 | 104 | | |
99 | 105 | | |
100 | 106 | | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
101 | 118 | | |
102 | 119 | | |
103 | 120 | | |
104 | 121 | | |
105 | 122 | | |
| 123 | + | |
106 | 124 | | |
107 | 125 | | |
108 | 126 | | |
| 127 | + | |
| 128 | + | |
109 | 129 | | |
| 130 | + | |
110 | 131 | | |
111 | 132 | | |
112 | 133 | | |
| 134 | + | |
113 | 135 | | |
| 136 | + | |
114 | 137 | | |
115 | 138 | | |
116 | 139 | | |
| |||
122 | 145 | | |
123 | 146 | | |
124 | 147 | | |
| 148 | + | |
125 | 149 | | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
126 | 153 | | |
127 | 154 | | |
128 | 155 | | |
129 | 156 | | |
| 157 | + | |
130 | 158 | | |
131 | | - | |
132 | | - | |
133 | | - | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
134 | 173 | | |
135 | | - | |
| 174 | + | |
0 commit comments