It's basically a free single-player demo with extra steps. Not being able to play on legitimate servers is realistically a huge drawback, honestly. And also, Microsoft knows it's a huge opening for "piracy" which is why they've created Bedrock edition which is where all their monetization efforts and future content updates will be increasingly directed.
Neither you nor I are supposed to ever care about Bedrock, or are ever expected to pay a cent for Minecraft. We are a tapped resource financially with nothing left to give and trying to get more money out of us and our community would be like trying to get blood from a stone. But that doesn't mean we're not important. Our role, even as free-to-play pirates in the Minecraft ecosystem, is to create content and create brand awareness, to keep it trending and on people's radar, so that when children and whales are drawn to it, Microsoft makes sure the first thing they see is some Bedrock edition thing and they can start shelling out cash immediately.
The whales, children, and naive parents are where the free money is. We're just part of the advertising pipeline aimed at those demographics. We create buzz, they buy.
fail2ban mainly, but also things like scaling login delays (some sort of option often built into the software you're running, but just as often not configured by default), or if you're feeling particularly paranoid account locking after too many failures, and in general just not using default, predictable, common usernames or weak passwords, and honestly it's even helped a bit by having slow hardware and throttled network bandwidth.
The goal is to make it so that someone can't run a script that sends 100 million login attempts per second for common or stolen usernames and passwords and your server just helpfully tries them all and obediently tells them none of those worked... until one of them does.
Not only does this encourage them to TRY sending 100 million login attempts per second because your server isn't refusing it, which is a huge waste of bandwidth and resources, it also makes it really likely that they're eventually going to guess one right.