News for hackers. Stuff that matters.
Re:Ask HN: Why do message queue-based architectures seem les... by steve1977 on Wednesday June 19, 2024 @01:44AM (#40725203)
> because people realized "You're not Google. Your company will never be Google."

Is that also why almost no one is using microservices and Kubernetes?

Re:Ask HN: Why do message queue-based architectures seem les... by devjab on Wednesday June 19, 2024 @03:02AM (#40725613)
> Is that also why almost no one is using microservices and Kubernetes?

I don’t know of a single 100+ sized organisation in my area which doesn’t use micro services in some form. A lot of places also use kubernetes indirectly through major cloud provider layers line Azure Container Apps.

Our frontend (and indeed quite a bit of our backend) lives in a NX mono-repo. As for how it actually works, however, it’s basically a lot of micro-services which are very independently maintainable. Meaning you can easily have different teams work on different parts of your ecosystem and not break things. It doesn’t necessarily deploy as what some people might consider micro services of course. But then micro services were always this abstract thing that is honestly more of a framework for management and change management than anything tech.

Re:Ask HN: Why do message queue-based architectures seem les... by benterix on Wednesday June 19, 2024 @03:44AM (#40725874)
Define "no one". If you mean small shops, maybe. If you mean large organizations, I haven't seen even one in the last 5 years that wouldn't use them in one way or another.
Re:Ask HN: Why do message queue-based architectures seem les... by steve1977 on Wednesday June 19, 2024 @04:41AM (#40726182)
It was meant to be ironic
Re:Ask HN: Why do message queue-based architectures seem les... by benterix on Wednesday June 19, 2024 @06:44AM (#40726942)
Ah sorry, it is more and more difficult for me to detect irony these days.
Re:Ask HN: Why do message queue-based architectures seem les... by steve1977 on Wednesday June 19, 2024 @07:32AM (#40727248)
Yeah sorry as well, I actually wanted to add a “… oh wait” to my original comment but forgot to do it… (too busy fixing a podman issue… )
Re:Ask HN: Why do message queue-based architectures seem les... by k8sToGo on Wednesday June 19, 2024 @01:49AM (#40725227)
Kubernetes brings more than just being Google. In a way it’s also an ecosystem.
Re:Ask HN: Why do message queue-based architectures seem les... by steve1977 on Wednesday June 19, 2024 @01:54AM (#40725258)
That‘s nice, but the question is if you (i.e. your company) needs this ecosystem.
Re:Ask HN: Why do message queue-based architectures seem les... by k8sToGo on Wednesday June 19, 2024 @02:18AM (#40725372)
Need no. But it’s nice especially since I have the know how.

Creating a new deployment is just super fast. Developers can deploy their own apps etc.

And then there is Helm.

If we only decide by “need” then most of the time we also wouldn’t need object oriented programming.

Re:Ask HN: Why do message queue-based architectures seem les... by sofixa on Wednesday June 19, 2024 @02:41AM (#40725503)
> And then there is Helm

Right, who doesn't want to template hundreds of lines of code in a language that uses whitespace for logic and was never made neither for templating nor complex long documents(YAML)? What could possibly go wrong ("error missing xxx at line 728, but it might be a problem elsewhere").

Re:Ask HN: Why do message queue-based architectures seem les... by fredrb on Wednesday June 19, 2024 @03:07AM (#40725642)
It’s not that bad if you need to deploy at least 3 things and for most cases it beats the alternatives. You can get away with a bootstrapped deployment yaml and a couple of services for most scenarios. What should you use instead? Vendor locked app platforms? Roll out your own deploy bash scripts?

Sure the full extend of Kubernetes is complicated and managing it might be a pain, but if you don’t go bonkers is not that hard to use it as a developer.

Re:Ask HN: Why do message queue-based architectures seem les... by ithkuil on Wednesday June 19, 2024 @03:13AM (#40725684)
I wonder why people don't use fromYaml + toJson to avoid stupid errors with indent.

Yaml is for all intents and purposes a superset of JSON so if you render your subtree as JSON you can stick it in a Yaml file and you don't need to care with indentation.

Re:Ask HN: Why do message queue-based architectures seem les... by spoiler on Wednesday June 19, 2024 @03:06AM (#40725636)
Honestly, Helm kinda sucks (for all the reasons you mentioned).

But Kustomize is very nice. Although, their docs could be a bit better.

Re:Ask HN: Why do message queue-based architectures seem les... by xnickb on Wednesday June 19, 2024 @02:50AM (#40725549)
But my infrastructure is code! Can't you see how it's all in git?
Re:Ask HN: Why do message queue-based architectures seem les... by benterix on Wednesday June 19, 2024 @03:52AM (#40725916)
What's wrong with having your infrastructure as code and storing it in Git?
Re:Ask HN: Why do message queue-based architectures seem les... by xnickb on Wednesday June 19, 2024 @04:57AM (#40726301)
YAML isn't code. Same as your reply, YAML has very little awareness of context.
Re:Ask HN: Why do message queue-based architectures seem les... by benterix on Wednesday June 19, 2024 @06:41AM (#40726926)
In computer science, the word "code" has a very specific meaning, and markup languages definitely fit this definition.
Re:Ask HN: Why do message queue-based architectures seem les... by sofixa on Wednesday June 19, 2024 @04:58AM (#40726308)
Nothing. Even if it's objectively terrible (thousands of lines of templated YAML, or thousands of lines of spaghetti bash), being in Git as code is still better. At least you know what it is, how it evolved, and can start adding linting/tests.
Re:Ask HN: Why do message queue-based architectures seem les... by benterix on Wednesday June 19, 2024 @06:43AM (#40726934)
I manage large IaC repos and it's mostly HCL, well-structured and easy to work with. Where we have Kubernetes manifests, they're usually split into smaller files and don't cause any trouble as normally we usually don't deploy manifests directly.
Re:Ask HN: Why do message queue-based architectures seem les... by ndthrowaway on Wednesday June 19, 2024 @04:59AM (#40726314)
"in a language that uses whitespace for logic"

This argument kind of died when python became one of the most popular programming languages used.

Re:Ask HN: Why do message queue-based architectures seem les... by cassianoleal on Wednesday June 19, 2024 @06:16AM (#40726795)
Python uses whitespace for scoping - not for logic. That said, the same is true for YAML.
Re:Ask HN: Why do message queue-based architectures seem les... by oblio on Wednesday June 19, 2024 @05:31AM (#40726523)
Yeah, but Python has actual for loops.
Re:Ask HN: Why do message queue-based architectures seem les... by everforward on Thursday June 20, 2024 @12:06PM (#40740276)
It’s not completely that white space is bad, but in particular that white space is very difficult to template relative to something character-delimited like JSON or s expressions.

In JSON or s expressions, the various levels of objects can be built independently because they don’t rely on each other. In YAML, each block depends on its parent to know how far it should be indented, which is a huge pain in the ass when templating.

Re:Ask HN: Why do message queue-based architectures seem les... by k8sToGo on Wednesday June 19, 2024 @05:22AM (#40726460)
I don’t like helm itself. But I was referring to the deployment part. I like Kustomize more.
Re:Ask HN: Why do message queue-based architectures seem les... by sgarland on Wednesday June 19, 2024 @09:18AM (#40728021)
I’ve only ever seen a single dev team managing their own K8s cluster. If by deploy you mean “they merge a branch which triggers a lot of automation that causes their code to deploy,” you don’t need K8s for that.

Don’t get me wrong, I like K8s and run it at home, and I’d take it any day over ECS or the like at work, but it’s not like you can’t achieve a very similar outcome without it.

Re:Ask HN: Why do message queue-based architectures seem les... by k8sToGo on Wednesday June 19, 2024 @12:19PM (#40729694)
Of course. And I can achieve a Webserver in C. Doesn’t mean it’s the best way given the circumstances.

There are many ways in tech to achieve the same result. I don’t understand why people constantly need to point that out.

I also don’t understand why k8s ruffles so many feathers.

Reminds me a bit of Linux vs windows vs Mac debates.

Re:Ask HN: Why do message queue-based architectures seem les... by sgarland on Wednesday June 19, 2024 @06:56PM (#40733281)
K8s ruffles my feathers because it’s entirely too easy to build on it (without proper IaC, natch) without having any clue how it works, let alone the underlying OS that’s mostly abstracted away. /r/kubernetes is more or less “how do I do <basic thing I could have read docs for>.”

I’m a fan of graduated difficulty. Having complex, powerful systems should require that you understand them, else when they break – and they will, because they’re computers – you’ll be utterly lost.

Re:Ask HN: Why do message queue-based architectures seem les... by koliber on Thursday June 20, 2024 @05:25AM (#40736656)
Lot's of things are nice to have but are expensive.

I'd love to have a private pool in my backyard. I don't, even though it's nice to have, because it is too expensive.

We intuitively make cost-benefit choices in our private lives. When it comes to deciding the same things at work, our reasoning often goes haywire.

Sometimes we need an expensive thing to solve a real problem.

Your point about object-oriented programming makes sense. Sometimes, a bash script suffices, and the person who decides to implement that same functionality in Java is just wasting resources.

All of these solutions have a place where they make sense. When they are blindly applied because they're a fad they generate a lot of costs.

Re:Ask HN: Why do message queue-based architectures seem les... by k8sToGo on Thursday June 20, 2024 @06:16AM (#40736957)
That’s true. Using k8s to host a static website would be silly.

Generally I only use it when I see a compelling case for it and the introduced complexity takes away complexity from somewhere else.

Re:Ask HN: Why do message queue-based architectures seem les... by Kirth on Wednesday June 19, 2024 @03:33AM (#40725808)
Genuine question: say you have 3-4 services and a bunch of databases that make up your product, what's the alternative to plemping them all into K8s according to you?
Re:Ask HN: Why do message queue-based architectures seem les... by Myoklov on Wednesday June 19, 2024 @04:13AM (#40726028)
Using cloud platform as a service options. For example, on Azure you can deploy such system with Azure App Service (with container deployment), or Azure Container Apps (very suitable for microservices). For database, you can use Azure Database for PostgreSQL (flexible), or Azure Cosmos DB for PostgreSQL.

This way, Azure does most of the heavy lifting you would otherwise have to do yourself, even with managed kubernetes.

Re:Ask HN: Why do message queue-based architectures seem les... by benterix on Wednesday June 19, 2024 @03:46AM (#40725881)
If you use AWS, it's probably easier to use ECS that takes away some of the complexity from you.
Re:Ask HN: Why do message queue-based architectures seem les... by sgarland on Wednesday June 19, 2024 @09:20AM (#40728040)
Maybe at first, but once you start building all of the IaC and tooling to make it useful and safe at scale, you might as well have just run EKS. Plus, then you can get Argo, which is IMO the single best piece of software from an SRE perspective.
Re:Ask HN: Why do message queue-based architectures seem les... by kaba0 on Wednesday June 19, 2024 @04:02AM (#40725969)
For personal stuff I simply run systemd services and that does scale quite a lot (as in, you can rely on it for more production services) I believe.
Re:Ask HN: Why do message queue-based architectures seem les... by sgarland on Wednesday June 19, 2024 @09:18AM (#40728024)
My hero.
Re:Ask HN: Why do message queue-based architectures seem les... by pcl on Wednesday June 19, 2024 @04:49AM (#40726238)
3-4 services and a bunch of databases?

Assuming there aren’t any particular scaling or performance requirements, if I were managing something like that, I would almost certainly not use k8s. Maybe systemd on a big box for the services?

Re:Ask HN: Why do message queue-based architectures seem les... by badcppdev on Wednesday June 19, 2024 @05:57AM (#40726684)
I agree with you and I'm always confused when people talk about process isolation as a primary requirement for a collection of small internal services with negligible load.

In addition the overhead and reporting drawbacks of running multiple isolated databases is vastly higher than any advantaged gained from small isolated deployments.

Re:Ask HN: Why do message queue-based architectures seem les... by k8sToGo on Wednesday June 19, 2024 @05:26AM (#40726483)
In my home environment I run a VM with docker for that.

In a commercial environment I’d still use kubernetes. But maybe something like k3s or if we are in a cloud environment something like EKS.

Usually with time other services get added to the stack (elastic, grafana, argocd, …)

Re:Ask HN: Why do message queue-based architectures seem les... by brazzy on Wednesday June 19, 2024 @05:38AM (#40726566)
Docker compose is another option.
Re:Ask HN: Why do message queue-based architectures seem les... by strken on Wednesday June 19, 2024 @09:29AM (#40728103)
If I had 3-4 services and a bunch of databases, I would look at them and ask "why do we need to introduce network calls into our architecture?" and "how come we're using MySQL and Postgres and MongoDB and a Cassandra cluster for a system that gets 200 requests a minute and is maintained by 9 engineers?"

Don't get me wrong, maybe they're good choices, but absent any other facts I'd start asking questions about what makes each service necessary.

Re:Ask HN: Why do message queue-based architectures seem les... by 62951413 on Wednesday June 19, 2024 @12:40PM (#40729904)
AWS Fargate is popular among large companies in my experience.

Some of them try to migrate from it to a unified k8s "platform" (i.e. frequently not pure k8s/EKS/helm but some kind of in-house layer built on top of it). It takes so long that your tenure with the company could end before you see it through.

Re:Ask HN: Why do message queue-based architectures seem les... by fikama on Wednesday June 19, 2024 @05:47AM (#40726626)
Maybe add /s ;). It may decline number of hot headed responses
Re:Ask HN: Why do message queue-based architectures seem les... by red-iron-pine on Wednesday June 19, 2024 @08:57AM (#40727853)
lol they gon get flamed
Re:Ask HN: Why do message queue-based architectures seem les... by portpecos on Wednesday June 19, 2024 @09:24AM (#40728071)
Yeah but you can’t deny the rofls without the /s. At least I certainly can’t deny the humor from reading DevJab’s comment.
Re:Ask HN: Why do message queue-based architectures seem les... by hn_throwaway_99 on Wednesday June 19, 2024 @10:56AM (#40728906)
I realize you're being sarcastic (I think), but I actually would put microservices in the same boat. There was a huge push to microservices in the mid teens, and a lot of companies came to hugely regret it. There is a reason this video, https://youtu.be/y8OnoxKotPQ, is so popular.

And it's not that "no one is using microservices", it's just that tons of companies realized they added almost as many complications as they alleviated, and that for many teams they were just way too premature. And a lot of the companies that I've seen have the most success with microservices are also the most pragmatic about them: they use them in some specific, targeted areas (e.g. authn and authz), but otherwise they're content using a well-componentized monolith where they can break off independent services later if there is an explicit reason to do so.