Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable access control for job runs #516

Conversation

srggrs
Copy link
Contributor

@srggrs srggrs commented Nov 26, 2023

Description

Enable specifying access control parameters for the job runs api for python models, as per API docs

Step to test this

  1. Enable access control to job from the admin settings
    image

  2. have two users and a simple dbt model to add to the databricks_demo project

  3. Run the model twice using user1 databricks credential, in the second run with

def model(dbt, session):
    dbt.config(
        materialized="table",
        access_control_list=[
            {
                "user_name": "user2",
                "permission_level": "CAN_VIEW"
            },
        ]
    )
  1. Login in databricks with user2 and check that job logs are visible.

Checklist

  • I have run this code in development and it appears to resolve the stated issue
  • This PR includes tests, or tests are not required/relevant for this PR
  • I have updated the CHANGELOG.md and added information about my change to the "dbt-databricks next" section.

Signed-off-by: Sergio Pintaldi <sergio.pintaldi@gmail.com>
Signed-off-by: Sergio Pintaldi <sergio.pintaldi@gmail.com>
Signed-off-by: Sergio Pintaldi <sergio.pintaldi@gmail.com>
@benc-db
Copy link
Collaborator

benc-db commented Nov 27, 2023

Thanks for the submission, will take a look shortly.

@benc-db
Copy link
Collaborator

benc-db commented Nov 27, 2023

@srggrs Going to open a new version of this PR in our fork so that I can run against our integration resources. Thanks for the submission.

@benc-db
Copy link
Collaborator

benc-db commented Nov 28, 2023

Closing in favor of work in 518.

@benc-db benc-db closed this Nov 28, 2023
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.

2 participants