3 ms·
Something I’m practicing more often is to keep something dead simple and then later adopt a library or some higher abstraction when necessary. For example, jus
by Waterluvian 5y ago
Something I’m practicing more often is to keep something dead simple and then later adopt a library or some higher abstraction when necessary.
For example, just handling a websocket myself before later using some sort of library for it.
In the past my concern was that I’ll have to make breaking changes to some protocol or message structure. But I’m learning now that it’s actually a good thing: it makes me think about how I’ll evolve and grow without the answer being “just preemptively grow it so you don’t have to think about it.”
And naturally I’m discovering that the basic tools go far further than I expect and sometimes I never need to pay for that abstraction at all.
- klysm 5y agoI find a lot of libraries don’t make the underlying systems easier to use per se, they just map a lot of use cases to configuration instead of code. I would rather just use the code hiding behind that static configuration.
- Waterluvian 5y agoAfter years and years of production experience with thousands of mobile robots that use this weird xml + yaml as configuration, I am 100% in the “just use code as configuration” camp.
- smitty1e 5y agoI put stuff in config.py Then I just `import` at will. The need for a separate configuration format was what, again?
- Waterluvian 5y agoMy probably wrong belief is that it was a misguided but noble idea of abstracting complexity.
- gedy 5y agoCompiled languages had a harder time with this.
- jacobsenscott 5y agoEven with interpreted languages - if your configuration is in code you still need to wait for a code review, wait for CI to pass, and wait for the deploy. It can easily take over an hour to do a simple configuration change.
- Too 5y agoDepends how you deploy it. Python can import a file located anywhere you want, either by changing PYTHONPATH or using importlib. And vice versa an xml-config file might be placed in the repo and going through code review. Code review for config changes is a good practice in either case, see gitops and config as code.
- Waterluvian 5y agoYou say it like any of that is a bad thing. Generally speaking, I think configuration changes should be reviewed.
- mooreds 5y agoReminds me of this: https://adamdrake.com/command-line-tools-can-be-235x-faster-than-your-hadoop-cluster.html https://adamdrake.com/command-line-tools-can-be-235x-faster-...