Connections Pane: AWS Redshift Support
Addresses #10432
Release Notes
New Features
- Added support for AWS Redshift for the Connections Pane (#10432).
Bug Fixes
- N/A
QA Notes
Creating a Redshift connection require some configuration, and there are possibly multiple different ways to setup authentication dependning on how the Redshift cluster is set.
The way that worked for me is:
- Set up awscli, (we have some internal instructions ) then run:
aws sso login --profile <profile>
The profile must have access to the Redshift cluster that you plan to use.
- Setting up a Redshift cluster:
The easiest way to setup a Redshift Cluster is creating a Serverless Redshihft cluster. Go to the AWS dashboard -> AWS Redshift -> Serverless Dashboard -> Create Workgroup
Follow the steps. Remember to use only public security groups if you want to be able to access it locally.
After creating the workgroup, you should be able to acess the query editor from the AWS console. Make sure you can make some queries from there.
You'll also be able to find the workgrourp endpoint in the workgroup dashboard. This is what is used for the connection string.
There may be easier or better ways for this, specially if setting CI jobs. See slack discussion.
- Connect from Python
A connection can be created by installing the redshift_connector:
pip install redshift_connector
The create a connection with:
conn: redshift_connector.Connection = redshift_connector.connect(
iam=True,
database='dev',
host='<workgroup endpoint>',
profile='<profile you setup in 1>'
)
@:connections