3 ms·
I think you are conflating several distinct concerns. 1. Using a file format that depends on a particular engineer 2. Static vs dynamic configuration 3. Volu
by throwaway894345 6y ago
I think you are conflating several distinct concerns.
1. Using a file format that depends on a particular engineer
2. Static vs dynamic configuration
3. Volume of configuration
For example, you can reduce your configuration to a minimal set of files which use a standard dynamic configuration format (e.g., starlark).
Note that The principle of lesser power should guide your decision between static and dynamic config format; however, if you find yourself building dynamism atop YAML (e.g., CloudFormation) or doing text templating of YAML (e.g., Helm), you’re misunderstanding the principle and suffering unnecessarily.
- 4WIW 6y agoStarlark is not configuration, it's a Turing complete "feature-challenged" programming language. If this is what you mean by dynamic configuration, this looks like an unfortunate outcome of someone's urge to try on humans what they learned in the PL class (or in SW methodology class :-) ). After suffering few thousand lines of a bloody mess created in this language, I can certainly say that Python, or Java would have been much better in this context. Pants (Twitter's version of Bazel) looks much better architected system in this respect. The problem with what you call the principle of lesser power is that people fail to accurately predict "suitability" of their solution and choose wrong tool for the job. They start with "I just want to set a couple of variables" and end up with full-scale development system with IDE, debugger and profiler, badly designed and partially implemented.
- throwaway894345 6y agoThis is pretty smug, but it seems like you don't understand the principle of least privilege at all. Notably, it exists to prevent exactly the scenario you describe: 'They start with "I just want to set a couple of variables" and end up with full-scale development system with IDE, debugger and profiler, badly designed and partially implemented.' > Starlark is not configuration, it's a Turing complete "feature-challenged" programming language. It's both. Programs are configuration. Not all configuration can be expressed statically except by expressing the program that derives it. That's what we mean by "dynamic configuration". Further, for the purposes of configuring most common applications, we want the language to be free of side effects ("feature-challenged" as you call it) because we want the execution to be reproducible--note that this is also an application of the principle of least privilege. There are also lots of practical reasons not to use Python or the JVM, notably the dependencies on big bulky runtimes. > After suffering few thousand lines of a bloody mess created in this language, I can certainly say that Python, or Java would have been much better in this context. Pants (Twitter's version of Bazel) looks much better architected system in this respect. I've used Pants in vain and I wasn't able to discern much 'architecture' in the original version. The rewrite seems to be better thought-through, benefiting from the experience of the initial version, but time will tell how it fares. That said, Bazel also left a lot to be desired in the way of extensibility, usability, quality, documentation, etc the last time I looked into it. In whichever case, the configuration language isn't the problem with either system. That said, as I respond to this comment, I'm building my own build system that is dramatically simpler and friendlier than existing systems, and it also uses Starlark as its configuration language (only because it's familiar and the most straight-forward to integrate).