|
|
|
|
|
by ghoward
1538 days ago
|
|
Hey, I'm hoping you can answer some questions for me. I'm building a build system and a VCS (separately). I want to do it right. Could you explain to me what Brazil is? Is it the build system? [1] Or is it the VCS that Amazon uses? If it is the build system, then it appears that versionsets are literally just a list of dependencies with their versions to use for a build. Is that correct? If not, or if you can give me more detail, what are versionsets, exactly? Also, what are workspaces? Does this quote from one of the comments on the link match? > A workspace consisted of a version set to track and any packages that were checked out. [1]: https://gist.github.com/terabyte/15a2d3d407285b8b5a0a7964dd6... |
|
* normal deps
* compile/test deps (i.e. non-transitive)
* runtime deps
* tool deps (non-transitive, but also non impacting on the closure resolution algorithm)
version sets allow for multiple versions of the same package to exist in them (ex foobar-1.0 and foobar-1.1), which has some benefit but in practice is just painful.
dependencies are defined in a capital-c Config file. when you run brazil, it does a few things
* it resolves all of the tools and makes them available on your path
* it sets up some environment variables
* it invokes your a build command defined in the Config file
Config files can also declare outputs (there's also some canonical outputs), so you can use a query tool to ex.
* get all jars in the runtime closure
* generate a symlink farm of all client sdk configuration files
the results of your build go into a build directory, and when you want to generate the runtime for a particular package, it will symlink together the outputs of all packages in the deps + runtime closure, which you can do on demand.
version sets are updated by building new packages versions into them, which will rebuild the version set to make sure all builds pass. if they do, a new "commit" will be put onto the version set. you can also merge from one version set into another, where you can get packages and their associated dependencies merged in along with a full rebuild.