Databases
Cloud Spanner
Connect your Cloud Spanner database to Basedash
Connect your Google Cloud Spanner database to Basedash to visualize and analyze your application data.
Prerequisites
- A Google Cloud project with Cloud Spanner enabled
- Service account with Spanner access
- Service account key file (JSON)
- Instance and database information
Connection methods
Direct connection
- From your Basedash dashboard, click “Add Data Source”
- Select “Cloud Spanner” as your database type
- Upload your service account key file
- Enter your connection details:
- Project ID
- Instance ID
- Database name
- Click “Test Connection” to verify
- Save your connection
Required permissions
Your service account needs the following IAM roles:
roles/spanner.databaseReader
- to read dataroles/spanner.viewer
- to view instance and database information
Best practices
- Create a dedicated service account for Basedash
- Grant minimum required permissions
- Regularly rotate service account keys
- Monitor query performance and costs
- Use appropriate instance configurations
Performance optimization
- Design efficient schemas
- Use appropriate indexes
- Monitor query patterns
- Set up proper backup policies
- Configure appropriate resource limits
Troubleshooting
- Verify service account permissions
- Check instance and database status
- Monitor quota usage
- Review Spanner audit logs
- Validate network connectivity
Was this page helpful?