shreyas-dev opened a new pull request, #60369: URL: https://github.com/apache/airflow/pull/60369
## Description This PR adds an optional `wait_for_termination` parameter to `PowerBIDatasetRefreshOperator` and refactors the execution flow to fix the double-deferral anti-pattern present in the current implementation. ## Motivation and Context **New Feature:** Users need the ability to trigger Power BI dataset refreshes without waiting for completion. This is useful for: - Long-running refreshes (hours/days) that don't need to block the DAG - Scenarios where downstream tasks don't depend on refresh completion - Reducing worker slot usage for fire-and-forget operations **Bug Fix:** The current implementation uses an inefficient double-deferral pattern: 1. `execute()` → defer → triggers refresh and returns `dataset_refresh_id` 2. `get_refresh_status()` → defer again → polls for completion 3. `execute_complete()` → processes final result This is unnecessary because `PowerBITrigger.run()` already handles both triggering the refresh AND polling for completion in a single async operation when `wait_for_termination=True`. ## Was generative AI tooling used to co-author this PR? - No -- 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]
