guan404ming commented on code in PR #73119:
URL: https://github.com/apache/airflow/pull/73119#discussion_r4456139126
##########
airflow-core/src/airflow/api_fastapi/core_api/routes/public/assets.py:
##########
@@ -125,6 +129,103 @@ def _generate_queued_event_where_clause(
return where_clause
+QueuedEventPartitionKeyQuery = Annotated[
+ str | None,
+ Query(
+ description=(
+ "Delete queued events of partitioned assets emitted for this
partition key whose "
+ "Dag run has not been created yet, instead of queued events of
non-partitioned assets."
+ ),
+ ),
+]
+
+
+def _delete_pending_partitioned_queued_events(
Review Comment:
Nice work! We could reuse `_generate_queued_event_where_clause` by passing
the model in, since both tables share these columns.
##########
airflow-core/src/airflow/api_fastapi/core_api/routes/public/assets.py:
##########
@@ -125,6 +129,103 @@ def _generate_queued_event_where_clause(
return where_clause
+QueuedEventPartitionKeyQuery = Annotated[
Review Comment:
Maybe note in the description that `partition_key` is the upstream event's
key, not the Dag run's, since mappers can differ.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]