uranusjr commented on code in PR #38683:
URL: https://github.com/apache/airflow/pull/38683#discussion_r1555446852
##########
airflow/callbacks/callback_requests.py:
##########
@@ -144,3 +144,27 @@ def __init__(
):
super().__init__(full_filepath, processor_subdir=processor_subdir,
msg=msg)
self.dag_id = dag_id
+
+
+class ToggleCallbackRequest(CallbackRequest):
+ """
+ A class with information about the DAG pause/unpause callback to be
executed.
+
+ :param full_filepath: File Path to use to run the callback
+ :param dag_id: DAG ID
+ :param processor_subdir: Directory used by Dag Processor when parsed the
dag.
+ :param is_toggle_off_callback: Flag to determine whether DAG is
paused(off) or unpaused(on) Callback
+ :param msg: Additional Message that can be used for logging
+ """
+
+ def __init__(
+ self,
+ full_filepath: str,
+ dag_id: str,
+ processor_subdir: str | None,
+ is_toggle_off_callback: bool | None = True,
Review Comment:
I would call this something like `next_state` or `new_state` instead.
--
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]