@@ -286,14 +286,14 @@ impl RustwideBuilder {
286286 // This fixes an edge-case on a fresh build server.
287287 //
288288 // It seems like on the fresh server, there _is_ a recent nightly toolchain
289- // installed, which we then updated with necessary components in this
290- // method .
289+ // installed. In this case, this method will just install necessary components and
290+ // doc-targets/platforms .
291291 //
292- // But: *for this toolchain, we never ran `add_essential_files`*, because it
292+ // But: *for this local old toolchain, we never ran `add_essential_files`*, because it
293293 // was not installed by us.
294294 //
295295 // Now the culprit: even through we "fix" the previously installed nightly toolchain
296- // with the needed components & targets, we return "updated = false", since the actual
296+ // with the needed components & targets, we return "updated = false", since the
297297 // version number didn't change.
298298 //
299299 // As a result, `BuildQueue::update_toolchain` will not call `add_essential_files`,
@@ -302,21 +302,29 @@ impl RustwideBuilder {
302302 // The workaround specifically for `add_essential_files` is the following:
303303 //
304304 // After `add_essential_files` is finished, it sets `ConfigName::RustcVersion` in the
305- // database to the version it uploaded the essential files for.
305+ // config database to the rustc version it uploaded the essential files for.
306306 //
307307 // This means, if `ConfigName::RustcVersion` is empty, or different from the current new
308308 // version, we can set `updated = true` too.
309309 //
310310 // I feel like there are more edge-cases, but for now this is OK.
311311 //
312312 // Alternative would have been to run `build update-toolchain --only-first-time`
313- // in a newly created `ENTRYPOINT` script for the build-server. I leaned to towards
314- // a more self-contained solution which doesn't need docker at all, and also would work
315- // if you run the build-server directly on your machine.
313+ // in a newly created `ENTRYPOINT` script for the build-server. This is how it was
314+ // done in the previous (one-dockerfile-and-process-for-everything) approach.
315+ // The `entrypoint.sh` script did call `add-essential-files --only-first-time`.
316+ //
317+ // Problem with that approach: this approach postpones the boot process of the
318+ // build-server, where docker and later the infra will try to check with a HTTP
319+ // endpoint to see if the build server is ready.
320+ //
321+ // So I leaned to towards a more self-contained solution which doesn't need docker
322+ // at all, and also would work if you run the build-server directly on your machine.
323+ //
316324 // Fixing it here also means the startup of the actual build-server including its
317- // metrics collection endpoints don't be delayed. Generally shoudl doesn't be
318- // a differene how much time is neede on a fresh build-server, between picking the
319- // up from the queue, and actually starting to build the release. In the old
325+ // metrics collection endpoints don't be delayed. Generally should doesn't be
326+ // a differene how much time is needed on a fresh build-server, between picking the
327+ // release up from the queue, and actually starting to build the release. In the old
320328 // solution, the entrypoint would do the toolchain-update & add-essential files
321329 // before even starting the build-server, now we're roughly doing the same thing
322330 // inside the main builder loop.
0 commit comments