tests.system.databricks.example_databricks
这是一个使用 DatabricksSubmitRunOperator 的 DAG 示例。在此示例中,我们创建了两个按顺序执行的任务。第一个任务是在工作空间路径 “/test” 运行一个 notebook,第二个任务是运行一个上传到 DBFS 的 JAR 包。这两个任务都使用新的集群。
由于我们为 notebook 任务设置了下游依赖,因此 spark jar 任务必须等到 notebook 任务成功完成后才会运行。
一次成功的运行定义为该运行的 result_state 为 “SUCCESS”。有关运行状态的更多信息,请参阅 https://docs.databricks.com/api/latest/jobs.html#runstate
模块内容
-
tests.system.databricks.example_databricks.ENV_ID[source]
-
tests.system.databricks.example_databricks.DAG_ID = 'example_databricks_operator'[source]
-
tests.system.databricks.example_databricks.QUERY_ID[source]
-
tests.system.databricks.example_databricks.WAREHOUSE_ID[source]
-
tests.system.databricks.example_databricks.job[source]
-
tests.system.databricks.example_databricks.test_run[source]