cloudflared with mysql deno

I followed this example https://github.com/brettscott/cloudflare-worker-tunnel-mysql-example and got it working. I have a question (maybe stupid 😅 ). Is possible that the service cloudflared get overloaded with 50k users daily?
GitHub
GitHub - brettscott/cloudflare-worker-tunnel-mysql-example: Connect...
Connect Cloudflare Worker to a self-hosted database via a secure Cloudflare Tunnel - brettscott/cloudflare-worker-tunnel-mysql-example
1 Reply
Chaika
Chaika•6mo ago
cloudflared get overloaded with 50k users daily?
Users is really vague. How many queries are they making per second average and at peak would be more helpful. To answer your question directly: I don't think cloudflared would have much of an issue, I think the bigger bottleneck would be your database. The issue that this and the original mysql driver tunnel adaption this used is that it makes a mysql connection per worker connection when mysql connections are super expensive. In a perfect world you'd be pooling them Cloudflare is working on Hyperdrive https://developers.cloudflare.com/hyperdrive/, a utility to connect to databases from Workers where they take care of the connection pooling and even query caching for you. They plan on supporting MySQL in the future, as well as an integration with tunnels so you can use that same type of approach. Just have to wait for it.
Want results from more Discord servers?
Add your server