3 ms·
The sibling comments point towards the difference in configuration if you take the "out of the box" product. But there is also a vast difference in how code is
by Matthias247 6y ago
The sibling comments point towards the difference in configuration if you take the "out of the box" product. But there is also a vast difference in how code is organized, in case you ever have to touch it.
From my point of view Nginx feels "old". It's a C codebase without a great amount of abstractions and interfaces, and instead having a bunch of #ifdefs here and there. Unit-tests and comments are not to be found. Build via autotools.
Envoy looks as modern as it gets for a C++ codebase - apart from maybe the lack of using coroutines which could be interesting for that use-case. It uses C++14, seems to be extremely structured and documented, has unit-tests, uses Bazel for builds, etc.
So I think the experience for anyone being interested in working on the code will be very different, and people that prefer the style of project A will have a very hard time with the style of project B and the other way around.
- MrBuddyCasino 6y ago> uses Bazel for builds Is this unanimously good? I've heard both praise and horror, never used it myself.
- st1ck 6y agoIt's good for Dropbox, since they use Bazel.
- SaveTheRbtz 6y agoOne of the senior engineers once said to me that "Bazel is like a sewer: you get back what you put in." Bazel requires a lot of upfront effort but the power of (a programmatically accessible/modifiable) dependency graph and a common build/test system across all the languages is very hard to underestimate.
- MrBuddyCasino 6y ago> very hard to underestimate Are you sure?
- ncmncm 6y agoI looked around at the code in Envoy. "As modern as it gets"? Very, very far from it. Everywhere I looked it was all-over public virtual functions. It looked, more than anything, like Java, which is essentially, more or less, C++92 with some bells on. The code might be OK, but, as with typical Java code, everywhere I looked was boilerplate, hardly any of it doing any actual work. I would hate for somebody to look at Envoy and think that was what good, modern C++ code looks like. Virtual functions are a good answer to certain problems that come up, once in a while--in C, for such a problem, you would use function pointers. Inheritance is a pretty good answer to certain problems that come up a little more often. But neither is a good answer to any organizational need, and a big project that reaches for virtual functions and inheritance as first resort makes me shiver.