Fabric Operator

Operator for running a Microsoft Fabric item (pipeline, notebook, etc.) as an Airflow task.

Bases: BaseOperatorLink

Link to the Fabric item run details page.

Parameters:

run_id (str) – The item run ID.

Build the Fabric Studio URL for the item run tied to ti_key.

Parameters:
  • operator – The operator instance the link is rendered for.

  • ti_key – The task instance key used to look up the run’s XCom-pushed run ID.

Returns:

The Fabric Studio monitoring URL, or None if job_type has no known URL pattern.

class scamander.providers.fabric.operators.fabric_operator.FabricRunItemOperator(*, workspace_id: str, item_id: str, fabric_conn_id: str, job_type: str, wait_for_termination: bool = True, timeout: int = 604800, check_interval: int = 60, max_retries: int = 5, retry_delay: int = 1, deferrable: bool = False, job_params: dict | None = None, use_notebook_beta_endpoints: bool = False, **kwargs)

Bases: BaseOperator

Operator to run a Fabric item (e.g. a notebook) in a workspace.

execute(context: Context) → dict | None

Submit the Fabric item run and, if configured, wait for it to terminate.

Parameters:

context – The Airflow task execution context.

Returns:

The final item run details payload if wait_for_termination is True and the run completes synchronously (non-deferred); otherwise None.

Raises:

FabricRunItemException – If the item run ends in a failure state.

execute_complete(context: Context, event) → dict | None

Callback for when the trigger fires. Raises on error, returns job details on success.

property hook: FabricHook

Create and return the FabricHook (cached).