Live data from Hacker News

The Future Database

principles.planetscale.com

21–30 of 40 posts

Re: The Future Database

#21
post #12

Earlier quoted context omitted.

What does 'serverless' mean exactly? 1) i think server-less, means ops-less, no manager of server even at scale,maybe you need optimization query but not to deploy databases, migration and that. 3)Scale should not come at the cost of performance is easier said than done, is the same idea automatic cache an thinks like this 2) i think the same i will still use monolith like PostgreSQL use a doubt have more intensive w…

> maybe you need optimization query but not to deploy databases, migration and that Well, how do you indicate to it that you want to create a database? Does the database read your mind too? How do you indicate that you want to provision some more because there's a big event coming up? > Scale should not come at the cost of performance is easier said than done That's essentially my exact point, yeah. It's not a novel…

> Well, how do you indicate to it that you want to create a database? Does the database read your mind too?

I'm not sure what you mean. You still instantiate resources with serverless products. With an AWS Lambda function, you go to the Lambda web console, click "Create a function," and type in the code for that function (of course this can also done via the AWS API). There's no mind-reading going on. For AWS Aurora, you still go to the RDS web console, click "Create a database," choose Aurora as the database engine, etc.

Re: The Future Database

#22
post #12

Earlier quoted context omitted.

What does 'serverless' mean exactly? 1) i think server-less, means ops-less, no manager of server even at scale,maybe you need optimization query but not to deploy databases, migration and that. 3)Scale should not come at the cost of performance is easier said than done, is the same idea automatic cache an thinks like this 2) i think the same i will still use monolith like PostgreSQL use a doubt have more intensive w…

> maybe you need optimization query but not to deploy databases, migration and that Well, how do you indicate to it that you want to create a database? Does the database read your mind too? How do you indicate that you want to provision some more because there's a big event coming up? > Scale should not come at the cost of performance is easier said than done That's essentially my exact point, yeah. It's not a novel…

> How do you indicate that you want to provision some more because there's a big event coming up?

You literally do not. As load starts to increase, you scale up automatically. The word elastic has been used to represent this pattern in the last few generations of cloud and/or computing infra.

What's the alternative? Manually ssh into some box and crank up mysql instance by hand? like its 1996?

Re: The Future Database

#23
post #22
post #12

Earlier quoted context omitted.

> maybe you need optimization query but not to deploy databases, migration and that Well, how do you indicate to it that you want to create a database? Does the database read your mind too? How do you indicate that you want to provision some more because there's a big event coming up? > Scale should not come at the cost of performance is easier said than done That's essentially my exact point, yeah. It's not a novel…

> How do you indicate that you want to provision some more because there's a big event coming up? You literally do not. As load starts to increase, you scale up automatically. The word elastic has been used to represent this pattern in the last few generations of cloud and/or computing infra. What's the alternative? Manually ssh into some box and crank up mysql instance by hand? like its 1996?

I think that only applies if the incoming load is gradual. Any sane elastic configuration has some timeouts and a measurement period meant to prevent unwanted scale-up just because of transient load, and during that time you can get hit hard enough to degrade/take down your service before your additional capacity has come online.

It makes sense to get out in front of known massive load events before they hit your service. If I'm launching a new service that I expect to hit the front page of HN, I'm spinning up capacity first and asking questions later. A couple hours of running large instances or extra containers costs much less than potential lost sales from users getting timeouts.

Re: The Future Database

#24
post #22
post #12

Earlier quoted context omitted.

> maybe you need optimization query but not to deploy databases, migration and that Well, how do you indicate to it that you want to create a database? Does the database read your mind too? How do you indicate that you want to provision some more because there's a big event coming up? > Scale should not come at the cost of performance is easier said than done That's essentially my exact point, yeah. It's not a novel…

> How do you indicate that you want to provision some more because there's a big event coming up? You literally do not. As load starts to increase, you scale up automatically. The word elastic has been used to represent this pattern in the last few generations of cloud and/or computing infra. What's the alternative? Manually ssh into some box and crank up mysql instance by hand? like its 1996?

Yeah, I appreciate what 'auto' and 'scaling' signifies. I've implemented an autoscaler on a huge Kubernetes cluster in the past. That's precisely where my doubt comes from.

I was about to write out a huge example, but I figure I'll just express the core logic simply. First, it takes a chunk of time to determine that increased traffic is not just random variance. Then it takes time to allocate and provision machines. And often the traffic spikes for you and for your co-tenants are not statistically independent, so the provider struggles to allocate machines in time when it most matters.

And how much do you scale up? 10x right away? Can't do that: vastly expensive, and anyway it could be a retry storm exacerbating things. 2x and then go from there? Well, if your business is serving ads during the Superbowl break, that's not gonna work. Etc. This all starts to look increasingly absurd against the backdrop of being able to just push a button and do it yourself.

I'm not suggesting never doing autoscaling. I'm just saying that wise men don't speak in absolutes, or make architectural decisions based on toy examples. Nor am I particularly bothered about whether I'm doing things "like it's 1996" - I'm not in the fashion business, so I'm purely interested in finding the optimal solution to my problem, and I couldn't care less whether it's flaming hot or whether it's from the Iron Age.

Re: The Future Database

#25
post #12

Earlier quoted context omitted.

> maybe you need optimization query but not to deploy databases, migration and that Well, how do you indicate to it that you want to create a database? Does the database read your mind too? How do you indicate that you want to provision some more because there's a big event coming up? > Scale should not come at the cost of performance is easier said than done That's essentially my exact point, yeah. It's not a novel…

> Well, how do you indicate to it that you want to create a database? Does the database read your mind too? I'm not sure what you mean. You still instantiate resources with serverless products. With an AWS Lambda function, you go to the Lambda web console, click "Create a function," and type in the code for that function (of course this can also done via the AWS API). There's no mind-reading going on. For AWS Aurora,…

I was joking, with that particular sentence. My point was that there is someone managing the server irrespective, and that there's not a particularly clear metaphysical distinction between 'create my database in this way' and 'instruct someone else to create my database in this way'. Not in the computing world, where everything's already under 17 layers of abstraction.

Re: The Future Database

#26
post #12

Earlier quoted context omitted.

What does 'serverless' mean exactly? 1) i think server-less, means ops-less, no manager of server even at scale,maybe you need optimization query but not to deploy databases, migration and that. 3)Scale should not come at the cost of performance is easier said than done, is the same idea automatic cache an thinks like this 2) i think the same i will still use monolith like PostgreSQL use a doubt have more intensive w…

> maybe you need optimization query but not to deploy databases, migration and that Well, how do you indicate to it that you want to create a database? Does the database read your mind too? How do you indicate that you want to provision some more because there's a big event coming up? > Scale should not come at the cost of performance is easier said than done That's essentially my exact point, yeah. It's not a novel…

It is possible to design scale-out database engines with very fast and elastic load following though it isn't common. In these kinds of systems, you don't provision for load, the system automatically adjusts to the load as it happens. In good designs you can often shed load in milliseconds once the additional server capacity is online, so the latency is often a function of how quickly you can bootstrap more server images.

These kinds of fast-twitch load shedding mechanics were not designed for elasticity -- it would not be worth the engineering investment in most cases. They were typically developed to support scale-out of data models for which uniform sharding is intrinsically impossible, requiring real-time adaptive resharding instead. If you have super-fast load shedding for extremely and unpredictably biased data distributions, you are 90% of the way to a really nice implementation of elastic capacity, just add hardware provisioning.

These setups are nice as a user, because the sharded nature of a table is (necessarily) completely transparent. You can create an empty new table and insert trillions of records without every having to manage sharding or cluster capacity as the table grows. In this sense, the fact that it is running on a cluster of discrete servers does not leak through the database abstraction presented to the user.

Re: The Future Database

#27

If you're truly forward-thinking you'd start planning for multiplanetary databases. Get a leg up on the competition by the time humans reach Mars. The core issues of planetary database systems have mostly been solved already. What about database systems which have to deal with time dilation due to running on spacecraft that travel through space at different velocities? But in all seriousness, one of the core features…

Humor aside, many years ago I had a 1:1 discussion with Vint Cerf (2003?) about interplanetary networks. He was thinking deeply on this topic, and I had some interesting and relevant input.

His focus was primarily on Store and Forward routing, and the implications that come with long latency hops. The overlap with military & battlefield networks where nodes are subject to active interference and "Node no longer exists" was a very overlapping topic.

A quick Google search shows he's still working on this.

Re: The Future Database

#28
post #11

If you're truly forward-thinking you'd start planning for multiplanetary databases. Get a leg up on the competition by the time humans reach Mars. The core issues of planetary database systems have mostly been solved already. What about database systems which have to deal with time dilation due to running on spacecraft that travel through space at different velocities? But in all seriousness, one of the core features…

> What about database systems which have to deal with time dilation due to running on spacecraft that travel through space at different velocities? I think they already handle this case by accident, because distributed clocks are unreliable and inconsistent anyways.

The Big Players put atomic clocks in the datacenter, and provide multiple mechanism's of time synchronization. Google Spanner was the first to do this, back in... 2007?

https://www.theverge.com/2012/11/26/3692392/google-spanner-a... https://cloud.google.com/spanner/docs/true-time-external-con...

Now, I don't think they worry overmuch about general or special relativity at this point, but if we start putting datacenters in orbit that will become an actual issue.

I'll wager we'll start seeing Edge Compute and CDN features on the very large satellite constellations (Starlink, etc) soon. Initially this will preserve bandwidth between satellites and with the ground stations. This will be a big upsell feature. The Quant folks would pay more for those sweet low-latency links...

Re: The Future Database

#29
post #6

I can't make sense of lots of this. - Without self-replicating grey goo, infinite scalability is surely more a property of some kind of networked computer rental business (like AWS) rather than a database. - What does 'serverless' mean exactly? My understanding is that it denotes a stateless application which is executed to serve a request but doesn't run continually as a daemon. Essentially the aforementioned comput…

I suspect the intention is something more like IPFS (https://ipfs.io), built on some distributed data structure like a DHT. With that in mind:

- "Infinitely scalable" in the sense of the internet, I suppose? If we had a way of paying for storage and indexing in a decentralized way, then you could switch from one 'provider' to another, or host your own data. Data would not be siloed in the way it is by AWS.

- I assume "serverless" means you don't have some specific upstream server you must hit with requests. You could submit queries to a local job, which could pass them to any node in the network.

- "Fundamentally reliable" because data is replicated, and jobs can be executed by any member of the network.

- "Distributed globally" because you could store data from any internet-connected device, "available locally" because, again, you don't have some single-point-of-failure server you need to connect to, or VPN you need to join, or whatever: your computer would be a node on the network, as capable of accessing data and running jobs as any other node.

And "intelligence" and "no performance cost" are just aspirations.

Re: The Future Database

#30
post #29
post #6

I can't make sense of lots of this. - Without self-replicating grey goo, infinite scalability is surely more a property of some kind of networked computer rental business (like AWS) rather than a database. - What does 'serverless' mean exactly? My understanding is that it denotes a stateless application which is executed to serve a request but doesn't run continually as a daemon. Essentially the aforementioned comput…

I suspect the intention is something more like IPFS ( https://ipfs.io ), built on some distributed data structure like a DHT. With that in mind: - "Infinitely scalable" in the sense of the internet, I suppose? If we had a way of paying for storage and indexing in a decentralized way, then you could switch from one 'provider' to another, or host your own data. Data would not be siloed in the way it is by AWS. - I assu…

> I suspect the intention is something more like IPFS (https://ipfs.io), built on some distributed data structure like a DHT.

the company's products are all built on top of sharded mysql .. unless they plan to throw away everything they have done so far, i do not think these assumptions are correct!

Post reply on HN