tursodatabase / turso-cli

Command line interface to Turso.
https://turso.tech
MIT License
225 stars 37 forks source link

Cannot connect to database #797

Closed vhgn closed 9 months ago

vhgn commented 9 months ago

Issue

Production database does not respond

vhgn commented 9 months ago
Error: failed to connect to database. err: failed to execute SQL: SELECT 1;
Post "https://***db***-**username**.turso.io/v2/pipeline": context deadline exceeded

I get this output in CLI

vhgn commented 9 months ago

This simple trick showed that I don't get a response back

console.log("Got request")
const { rows } = await db.execute(`
    SELECT name
    FROM genres
`);
console.log("Got rows", rows);

It never outputted "Git rows..."

gris commented 9 months ago

@vhgn can you check it now?

vhgn commented 9 months ago

It worked! Thanks for the quick response. Is there anything done wrong on my side? How can I help preventing this happening in the future?

gris commented 9 months ago

no problem on your side, it was a network connectivity issue of our cloud provider, we have run an automation to fix all clusters that had this issue, but apparently the automation haven't catch all of them. Thanks for reporting

vhgn commented 9 months ago

Does having a starter plan versus a scaler plan have an impact?

gris commented 9 months ago

in a sense yes, because scaler plan clusters don't have scale to zero or group sleeping, and this particular issue wouldn't have happened if it wasn't for a problem when scaling from zero. But this is not the quality of service that we wish to serve to our free tier users anyway. So my apologies