Skip to content

Pass cube authorization header to trinodb per query#1

Draft
shcarr-r7 wants to merge 1 commit into
masterfrom
shcarr/auth-token-per-query
Draft

Pass cube authorization header to trinodb per query#1
shcarr-r7 wants to merge 1 commit into
masterfrom
shcarr/auth-token-per-query

Conversation

@shcarr-r7
Copy link
Copy Markdown
Owner

Check List

  • Tests have been run in packages where changes have been made if available
  • Linter has been run for changed code
  • Tests for the changes have been added if not covered yet
  • Docs have been added / updated if required

Description of changes
Adds a way to use cube auth token per trinodb query.

To enable in cube.js set perQueryAuth = true:

Warning

An environment variable might be preferred?

const TrinoDriver = require('@cubejs-backend/trino-driver');

module.exports = {
    driverFactory: ({ securityContext }) => {
        const baseDriver = new TrinoDriver({
            engine: 'trino',
            perQueryAuth: true
        });
        return baseDriver;
    }
};

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant