3 ms·
> Under no circumstance would I allow my projects to be configured by a full-blown programming language. Well, the choice is Java, or Java and yaml. > The amo
by mrkeen 7y ago
> Under no circumstance would I allow my projects to be configured by a full-blown programming language.
Well, the choice is Java, or Java and yaml.
> The amount of complexity introduced just for configuration is insane.
Again, it's Java, vs. Java + Spring + env + application.yaml + application-$profile.yaml (in my case usually).
Once config constants enter your language, they're type-checked. Tree-structures suddenly need to be well-formed. No more trying to remember if you force https-only with 'enforceHttps', 'enforceHTTPS', 'enforceTLS', 'enforceSSL'. (= True,= true, :true, :1, :on, = "on")
> no regressions under different configurations.
It's great for that! Instantiate three copies of your service from Main - say, one backed by a hashmap, one connecting to a live db, one connecting to your docker-compose db, etc. Run the the same set of commands (in the same language your tests are already written in) and assert the outputs.
- jevgeni 7y agoThe choice is: no Java at all. :p
- ric2b 7y agoSo to change a configuration option I need to recompile the project?
- mrkeen 7y agoMy flow is: 1) I think about changing it 2) I change it 3) I figure out some way to verify it 4) I deploy it to prod I don't want to do step 2 unless I can do step 3. It just so happens that type-checking happens during recompilation, and testing happens after.