The Apache Airflow Tableau Provider enables seamless integration between Apache Airflow and Tableau Server/Online. It offers operators and hooks to automate various Tableau-related tasks, such as refreshing data sources, publishing workbooks, and managing server content, directly within Airflow DAGs. The provider is actively maintained as part of the Apache Airflow project, with regular releases aligning with Airflow's provider release cycles, currently at version 5.3.4.
pip install apache-airflow-providers-tableauVerified import paths — ran on the pinned version, not inferred.
This example DAG demonstrates how to use the `TableauOperator` to refresh a Tableau workbook. It shows a blocking refresh, meaning the task will wait until the refresh operation on Tableau Server/Online is completed. The `tableau_conn_id` parameter references an Airflow connection configured with Tableau credentials. The `site_id` should be provided if not using the default Tableau site, or an empty string ('') for the default site. Workbook ID can be passed via DAG params or environment variables.
Migrate to JSON Web Token (JWT) authentication for robust and scalable Airflow-Tableau integrations, especially in environments with parallel tasks.
Update imports and usage to the current `TableauOperator` and `TableauJobStatusSensor` patterns, which now handle these functionalities directly.
Ensure your Apache Airflow instance is upgraded to at least version 2.2.0 (or newer for later provider versions) before installing or upgrading to `apache-airflow-providers-tableau` >= 3.0.0.
Always specify the `site_id` parameter in your Tableau connection or operator if you are not using the default Tableau Server site. For the default site, use an empty string (e.g., `site_id=''`).
Ensure the certificate chain is correctly configured and accessible by the Airflow worker. If possible, use publicly recognized certificates. For self-signed certificates, ensure the full chain is provided and consider alternative verification methods if the issue persists.
Install the package using pip: 'pip install apache-airflow-providers-tableau'.
Ensure the correct import statement: 'from airflow.providers.tableau.hooks.tableau import TableauHook'.
Verify that you have the correct version of 'apache-airflow-providers-tableau' installed and that 'TableauHook' is available in that version.
Use one of the available resources listed in the error message when initializing the 'TableauOperator'.
Use one of the available methods listed in the error message for the specified resource.