Skip to content

Conversation

@eric-maynard
Copy link
Contributor

Description

This PR introduces a new operation, CREATE_TABLE_DIRECT_WITH_WRITE_DELEGATION, and requires it for createTableDirectWithWriteDelegation.

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

Added a new test in test_spark_sql_s3_with_privileges.py

Checklist:

Please delete options that are not relevant.

  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes.

Copy link
Contributor

@dennishuo dennishuo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for fixing this! Approach generally LGTM.

A couple test items that might be helpful to add:

  1. Looks like we lacked coverage of createTableDirectWithWriteDelegation in PolarisCatalogHandlerWrapperAuthzTest originally, which ideally can serve as "tests-as-documentation" for the authz model; you could add two test cases that mimic testCreateTableStagedWithWriteDelegationAllSufficientPrivileges and testCreateTableStagedWithWriteDelegationInsufficientPermissions to solidify that having having TABLE_CREATE by itself is insufficient. (Follow testCreateTableStagedAllSufficientPrivileges for the cleanup hook)
  2. Update test_spark_credentials_s3_direct_without_read as well

kevinjqliu pushed a commit to kevinjqliu/polaris-catalog that referenced this pull request Jul 31, 2024
* Add issue templates

* Add color to PR template
Copy link
Contributor

@dennishuo dennishuo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

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.

3 participants