News for hackers. Stuff that matters.
Re:How does database sharding work? by nullandvoid on Monday April 10, 2023 @09:56AM (#35512346)
Does anyone else use planet scale but find it extremely slow? I'm using planetscale trial, simple queries can easily take 3-4s "cold", and then seem to get a little faster once presumably I hit cache.
Re:How does database sharding work? by mscccc on Monday April 10, 2023 @10:10AM (#35512497)
Hey, I work for PlanetScale.

Definitely not normal. It’s hard to know why you’re seeing slow queries without more information.

The most common causes are either: missing indexes or network latency between the app and database (are they in the same region?).

We don’t have cold starts, but it is possible for queries to get faster once data is moved into memory. 3-4s is very slow though, I suspect it’s doing a full table scan and an index will solve it.

If you check Insights you can get more info, would also help to run an explain on the query (https://planetscale.com/courses/mysql-for-developers/queries...) to see what’s happening.

Also, if you email support, they’ll help debug it for you. Hope that helps!