News for hackers. Stuff that matters.
Re:Half a million lines of Go by tptacek on Sunday May 16, 2021 @08:34PM (#27178727)
What you're trying to say is that Go's domain is mostly serverside. That's true. But it sounds too useful and ambitious, so you've modified it to "CRUD microservices". Which is silly and false, but works better as a slur on the language.

What's dispiriting here is that there are cogent arguments against Go --- decisions Go could have made differently that probably wouldn't have cost the project much in terms of its other goals of compilation speed and simplicity, but make it more annoying to work in. I switch between Rust and Go every day and miss pattern matching almost every time, for instance.

Instead, though, we get the same dumb innuendo. "It's a language for managers". "It's a language for CRUD apps". "It's a language for junior programmers". Never mind that the kernel of truth in those statements is shared by languages like Python; you can't really get away with trashing Python like that, or you'll be haunted by the ghost of one of Peter Norvig's terrifying shirts. Which is a way you know not much is really being said here, except that there's some weird turf war between Go and whatever language its haters are advocating for.

Re:Half a million lines of Go by unscaled on Sunday May 16, 2021 @10:10PM (#27179390)
Of all the subdomains of serverside apps, I think "CRUD microservices" are one of the worst fits you get for Go. Fine, CRUD monoliths are even worse.

Go can get you good performance on a CRUD app, but that's probably the only advantage you'll get. On the other hand, Go doesn't have the facilities to build the frameworks that make CRUD apps so easy on languages like Java, Ruby or Python.

Go is a much better domain fit for microservices that don't do CRUD, for server and network control plane (k8s, istio, docker), configuration systems,CI/CD tools. So many things that are definitely not CRUD.

As a side note: People love to vilify CRUD apps, but they also require skill to do right. I've seen way too many botched attempts that ended up expensive to maintain and an absolute performance disaster.

Re:Half a million lines of Go by coryrc on Sunday May 16, 2021 @10:57PM (#27179649)
What is Kubernetes control plane but CRUD against etcd?
Re:Half a million lines of Go by tptacek on Monday May 17, 2021 @12:17AM (#27180000)
What is an Ethernet driver but CRUD against a DMA ring?
Re:Half a million lines of Go by coryrc on Monday May 17, 2021 @01:43AM (#27180393)
A heap of sand minus one grain is still a heap, but eventually it's a DMA ring.

To use wikipedia's definition of CRUD, "[CRUD] are the four basic operations of persistent storage." etcd is persistent but a DMA ring is not?

But fundamentally the main way k8s resources are implemented is by observing the current state and desired state and updating the current state to be closer to the desired state, sometimes performing other actions (which are often updates on a different resource's setting)... so whether "other actions" are enough to make it not-CRUD is to the eye of the beholder.

Re:Half a million lines of Go by coryrc on Sunday May 16, 2021 @08:48PM (#27178820)
You wouldn't write a monolith in Go? I think it's fair to narrow it down to microservices (maybe just "services" though?). A lot of programming these days is translating one thing into another thing (there are several packages out there for making protobufs more efficient, f.ex.; which I think is the most I can say on the topic?). It's not a slur if it's actually good at doing something we do a lot of.

I've recently tried using it as a "better shell script for gophers" but it's still too early to say.

We've all heard the nulls, pattern matching, etc arguments already. I just think it's not that big of a pain if you are only doing CRUD and that's why it makes sense in its domain.

EDIT: I've fallen out of love with Python because it's bad at large programs (distributed or not). Didn't think that's controversial.

Re:Half a million lines of Go by tptacek on Sunday May 16, 2021 @08:51PM (#27178836)
"Maybe just services" concedes the whole point. Yes, Go is not a good language to build a web browser in (and that's an important application domain, and we all suffer from not having a popular portable language to do that in; it's why we all run goofy Electron apps on our desktops now). But the space of all possible serverside apps is huge, and encompasses a pretty big chunk of what people actually build professionally.
Re:Half a million lines of Go by coryrc on Sunday May 16, 2021 @09:26PM (#27179114)
There's so much more than untrusted-client<->server apps even if we find ourselves in that local maxima. Or maybe it really is the One True Way, but I think more of appliances with firmware, the Linux kernel, the apps on my phone, mainframes, 3d games, FPGAs, PL research, supercomputing... there's so many exciting applications for software! And I don't feel Go is a good match for most of it and will just cause people frustration to try.
Re:Half a million lines of Go by tptacek on Sunday May 16, 2021 @09:38PM (#27179189)
Take a look at gvisor and come back and tell me how limiting Go is, I guess.
Re:Half a million lines of Go by coryrc on Sunday May 16, 2021 @09:53PM (#27179281)
You're not wrong, you shouldn't be downvoted.

This is too close to my work life that I don't wish to comment on this project. EDIT: but it is a fantastic accomplishment