Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions packages/cubejs-athena-driver/src/AthenaDriver.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,8 @@ interface AthenaDriverOptions extends AthenaClientConfig {
exportBucket?: string
pollTimeout?: number
pollMaxInterval?: number
athenaAwsAssumeRoleArn?: string
athenaAwsAssumeRoleExternalId?: string

/**
* The export bucket CSV file escape symbol.
Expand Down Expand Up @@ -125,8 +127,13 @@ export class AthenaDriver extends BaseDriver implements DriverInterface {
config.secretAccessKey ||
getEnv('athenaAwsSecret', { dataSource });

const assumeRoleArn = getEnv('athenaAwsAssumeRoleArn', { dataSource });
const assumeRoleExternalId = getEnv('athenaAwsAssumeRoleExternalId', { dataSource });
const assumeRoleArn =
config.athenaAwsAssumeRoleArn ||
getEnv('athenaAwsAssumeRoleArn', { dataSource });

const assumeRoleExternalId =
config.athenaAwsAssumeRoleExternalId ||
getEnv('athenaAwsAssumeRoleExternalId', { dataSource });

const { schema, ...restConfig } = config;

Expand Down
Loading