21
21
Define an operator extra link
22
22
=============================
23
23
24
- If you want to add further links to operators you can define them via a plugin or provider package.
24
+ If you want to add extra links to operators you can define them via a plugin or provider package.
25
25
Extra links will be displayed in task details page in Grid view.
26
26
27
27
.. image :: ../img/operator_extra_link.png
@@ -60,7 +60,8 @@ The following code shows how to add extra links to an operator via Plugins:
60
60
GoogleLink(),
61
61
]
62
62
63
- .. note :: Operator Extra Links should be registered via Airflow Plugins or custom Airflow Provider to work.
63
+ The extra links defined via custom Airflow Provider or Airflow operators will be pushed as an xcom to the XCom table in
64
+ metadata DB during task execution. During display in the grid view, this xcom is retrieved and displayed.
64
65
65
66
You can also add a global operator extra link that will be available to
66
67
all the operators through an Airflow plugin or through Airflow providers. You can learn more about it in the
@@ -93,7 +94,7 @@ tasks using :class:`~airflow.providers.amazon.aws.transfers.gcs_to_s3.GCSToS3Ope
93
94
class S3LogLink (BaseOperatorLink ):
94
95
name = " S3"
95
96
96
- # Add list of all the operators to which you want to add this OperatorLinks
97
+ # Add list of all the operators to which you want to add this extra link
97
98
# Example: operators = [GCSToS3Operator, GCSToBigQueryOperator]
98
99
operators = [GCSToS3Operator]
99
100
@@ -120,9 +121,9 @@ tasks using :class:`~airflow.providers.amazon.aws.transfers.gcs_to_s3.GCSToS3Ope
120
121
121
122
**Overriding Operator Links of Existing Operators **:
122
123
123
- It is also possible to replace a built in link on an operator via a Plugin. For example
124
+ It is also possible to replace a built- in link on an operator via a Plugin. For example
124
125
:class: `~airflow.providers.google.cloud.operators.bigquery.BigQueryExecuteQueryOperator ` includes a link to the Google Cloud
125
- Console, but if we wanted to change that link we could:
126
+ Console, but if we wanted to change that link we could do :
126
127
127
128
.. code-block :: python
128
129
@@ -173,7 +174,7 @@ specify the list of operators that provide extra link capability. This happens b
173
174
class name in the ``provider-info `` information stored in your Provider's package meta-data:
174
175
175
176
Example meta-data required in your provider-info dictionary (this is part of the meta-data returned
176
- by ``apache-airflow-providers-google `` provider currently:
177
+ by ``apache-airflow-providers-google `` provider currently) :
177
178
178
179
.. code-block :: yaml
179
180
0 commit comments