AWS Redshift¶
Prerequisites¶
Ensure that you have the following credentials available for AWSRedshift Depot:
- The hostname for the AWS Redshift cluster
- The username/password for the AWS Redshift cluster
- The name of the database to use within the AWS Redshift cluster
Docker Compose Manifest file¶
The highlighted attributes are all the required attributes.
version: "2.2"
x-lens2-environment: &lens2-environment
# DataOS
DATAOS_FQDN: liberal-donkey.dataos.app
# Overview
LENS2_NAME: ${redshiftlens}
LENS2_DESCRIPTION: "Ecommerce use case on Adventureworks sales data"
LENS2_TAGS: "lens2, ecom, sales and customer insights"
LENS2_AUTHORS: "iamgroot"
LENS2_SCHEDULED_REFRESH_TIMEZONES: "UTC,America/Vancouver,America/Toronto"
# Data Source
LENS2_SOURCE_TYPE: ${depot}
LENS2_SOURCE_NAME: ${redshiftdepot}
LENS2_SOURCE_CATALOG_NAME: ${redshiftdepot}
# Log
LENS2_LOG_LEVEL: error
CACHE_LOG_LEVEL: "trace"
# Operation
#LENS_DB_QUERY_TIMEOUT: 15m
LENS2_DEV_MODE: true
LENS2_DEV_MODE_PLAYGROUND: false
LENS2_REFRESH_WORKER: true
LENS2_SCHEMA_PATH: model
LENS2_PG_SQL_PORT: 5432
CACHE_DATA_DIR: "/var/work/.store"
NODE_ENV: production
LENS2_ALLOW_UNGROUPED_WITHOUT_PRIMARY_KEY: "true"
services:
api:
restart: always
image: rubiklabs/lens2:0.35.41-02
ports:
- 4000:4000
- 25432:5432
- 13306:13306
environment:
<<: *lens2-environment
volumes:
- ./model:/etc/dataos/work/model
docker-compose.yml
:
- Step 1: Create a
docker-compose.yml
manifest file. - Step 2: Copy the template from above and paste it in a code.
- Step 3: Fill the values for the atttributes/fields declared in the manifest file as per the AWS Redshift source.
Required AWS Redshift Depot Source Attributes
LENS2_SOURCE_TYPE: ${depot}
LENS2_SOURCE_NAME: ${redshiftdepot}
LENS2_SOURCE_CATALOG_NAME: ${redshiftdepot}
Note: Ensure the user has AWS console access before proceeding.
Check Query Stats fo AWSRedshift¶
1. Log in to AWS Console and Access Redshift¶
- Login to the AWS Console.
- Search for "Redshift" in the AWS Console search bar.
2. Select Redshift Cluster¶
- Click on "Amazon Redshift" from the search results. You will be directed to the Redshift dashboard.
- Select the appropriate region and choose the desired cluster name from the list.
3. Access Query Monitoring¶
- Select the cluster you want to monitor.
- Navigate to the "Query monitoring" tab to view query statistics
4. View Running and Completed Queries¶
- In the "Query monitoring" tab, you will see a list of running and completed queries.
5. Monitor Specific Query¶
- Click on the query you want to monitor.
- View the query statistics, as shown in the example below.