Skip to content

Consumer team asset filtering: add API endpoint support#68034

Merged
vincbeck merged 1 commit into
apache:mainfrom
aws-mwaa:vincbeck/asset_filtering_api
Jun 8, 2026
Merged

Consumer team asset filtering: add API endpoint support#68034
vincbeck merged 1 commit into
apache:mainfrom
aws-mwaa:vincbeck/asset_filtering_api

Conversation

@vincbeck

@vincbeck vincbeck commented Jun 4, 2026

Copy link
Copy Markdown
Contributor

Add access_control attribute in create asset event API to specify consumer team filtering. Of course, this is optional.

Example:

{
  "asset_id": 0,
  "extra": {},
  "access_control": {
    "consumer_teams": ["teamA", "teamB"],
    "allow_global", False
  }
}

Was generative AI tooling used to co-author this PR?
  • Yes (please specify the tool below)

  • Read the Pull Request Guidelines for more information. Note: commit author/co-author name and email in commits become permanently public when merged.
  • For fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
  • When adding dependency, check compliance with the ASF 3rd Party License Policy.
  • For significant user-facing changes create newsfragment: {pr_number}.significant.rst, in airflow-core/newsfragments. You can add this file in a follow-up commit after the PR is created so you know the PR number.

potiuk
potiuk previously requested changes Jun 5, 2026

@potiuk potiuk left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Two things before this lands:

Tests (CI red): the 5 failing core tests are all TypeError: option values must be stringsconf_vars({("core", "multi_team"): multi_team}) passes a bool, but conf_vars needs string values. str(multi_team) (or "True"/"False") fixes all five.

API shape: access_control is typed dict[str, Any] and read via .get("consumer_teams") / .get("allow_global"). On a public endpoint that means the nested structure isn't validated and isn't in the generated OpenAPI schema — a typo'd key is silently dropped, and clients have no documented shape (the example in the description has "allow_global", False, which wouldn't even parse). Could we make it a typed submodel, e.g. consumer_teams: list[str] | None = None / allow_global: bool = True? Validation + schema, and it's much harder to change once it's shipped in v2.


Drafted-by: Claude Code (Opus 4.8); reviewed by @potiuk before posting

@vincbeck vincbeck force-pushed the vincbeck/asset_filtering_api branch from 27985f6 to 84c0f5a Compare June 5, 2026 21:39
@vincbeck vincbeck force-pushed the vincbeck/asset_filtering_api branch from 84c0f5a to 0404a71 Compare June 8, 2026 13:41
@vincbeck vincbeck merged commit 60ff466 into apache:main Jun 8, 2026
146 checks passed
@vincbeck vincbeck deleted the vincbeck/asset_filtering_api branch June 8, 2026 16:27
@github-actions

github-actions Bot commented Jun 8, 2026

Copy link
Copy Markdown
Contributor

Backport failed to create: airflow-ctl/v0-1-test. View the failure log Run details

Note: As of Merging PRs targeted for Airflow 3.X
the committer who merges the PR is responsible for backporting the PRs that are bug fixes (generally speaking) to the maintenance branches.

In matter of doubt please ask in #release-management Slack channel.

Status Branch Result
airflow-ctl/v0-1-test Commit Link

You can attempt to backport this manually by running:

cherry_picker 60ff466 airflow-ctl/v0-1-test

This should apply the commit to the airflow-ctl/v0-1-test branch and leave the commit in conflict state marking
the files that need manual conflict resolution.

After you have resolved the conflicts, you can continue the backport process by running:

cherry_picker --continue

If you don't have cherry-picker installed, see the installation guide.

@vatsrahul1001 vatsrahul1001 added this to the Airflow 3.3.0 milestone Jun 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants