cloud-sql-connector
Cloud SQL Auth Proxy connector for Rust.
Implements the Cloud SQL connector protocol: generates an RSA keypair, calls the Cloud SQL Admin API for ephemeral certificates, and establishes TLS 1.3 connections directly to Cloud SQL instances.
Usage
Direct TLS connection
use Arc;
use Dialer;
async
Unix socket proxy
use Path;
use Arc;
use ;
async
TODO
- Cache connect settings (IP address, server CA cert) in the
Dialerinstead of fetching them on everydial()call. These are stable per instance and only change on failover or CA rotation. The Go connector refreshes them every ~30 minutes.