SameerMesiah97 opened a new pull request, #64393:
URL: https://github.com/apache/airflow/pull/64393

   **Description**
   
   This refactors `DbtCloudRunJobOperator.execute()` by extracting job ID 
resolution, job run triggering/reuse, and terminal status handling into 
dedicated helper methods. The overall execution flow remains unchanged, but the 
logic is now split into smaller, focused units: `_resolve_job_id`, 
`_get_or_trigger_run`, and `_handle_terminal_status`.
   
   **Rationale**
   
   The `execute()` method previously contained multiple responsibilities, 
including job resolution, run triggering, reuse logic, and terminal state 
handling, making it harder to follow and reason about. By separating these 
concerns into helper methods, the control flow of `execute()` becomes clearer 
and easier to maintain, core logic paths can be reasoned about in isolation, 
and future changes to specific behaviors (e.g. run reuse or terminal handling) 
can be made with lower risk.
   
   **Backwards Compatibility**
   
   This change does not modify any public interfaces or operator behavior. All 
parameters, return values, and execution semantics remain unchanged. The 
refactor is internal to the operator implementation and fully backwards 
compatible.
   


-- 
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]

Reply via email to