Install the BARRY Python package.
This page walks through getting the BARRY PySpark connector wheel and using it in a notebook to read on-prem data into a Spark DataFrame. For the architecture and the serving contract, see the PySpark Connector page.
On the Transports page, click ↓ Barry Wheel vX.Y.Z (top right). It always serves the latest published wheel — there is no version to pick and no promotion step. The file is a universal Python wheel:
barry_io_pyspark-<version>-py3-none-any.whl
If the button is not shown, no wheel has been published yet (or the server's wheel storage is not configured) — ask an administrator.
Upload the wheel to a location your workspace can read (a Databricks Volume or workspace files), then install it and restart Python:
%pip install /Volumes/<catalog>/<schema>/<volume>/barry_io_pyspark-<version>-py3-none-any.whl
dbutils.library.restartPython()
Requirements: Databricks Runtime 15.4 LTS+ (or serverless environment v2), or Apache Spark 4.0+ — the Python Data Source API is required. pyarrow and requests are already on the Databricks runtime.
from barry_io_pyspark import BarrySparkDataSource
spark.dataSource.register(BarrySparkDataSource)
df = (spark.read.format("barry")
.option("base_url", "https://barry.example.com")
.option("token", dbutils.secrets.get("barry", "serve-token"))
.option("table", "Customers")
.load())
df.show()
| Option | Required | Meaning |
|---|---|---|
base_url | yes | the BARRY server origin |
token | yes | a per-group access token (issue it in Transports → Manage groups → Serving access) |
table | yes | the served table name |
verify_ssl | no (default true) | set "false" only for dev servers with self-signed certs |
Store the token in a Databricks secret scope (as shown) — don't inline it. A table is available only when a transport uses the Spark Direct Barry destination, belongs to a group, and that group has a token.
.filter(...) / .select(...) runs in Spark after the snapshot arrives — there is no pushdown to the source in this version..load() calls to parallelize across them.base_url is wrong. Re-issue the token from Manage groups → Serving access. (An authentication failure is reported as HTTP 404.)format("barry") not found — the runtime is older than DBR 15.4 LTS / Spark 4.0, or spark.dataSource.register(BarrySparkDataSource) was not run in this session (re-run after restartPython()).You are currently viewing a placeholder content from Vimeo. To access the actual content, click the button below. Please note that doing so will share data with third-party providers.
More InformationYou are currently viewing a placeholder content from YouTube. To access the actual content, click the button below. Please note that doing so will share data with third-party providers.
More InformationYou need to load content from reCAPTCHA to submit the form. Please note that doing so will share data with third-party providers.
More InformationYou are currently viewing a placeholder content from Vimeo. To access the actual content, click the button below. Please note that doing so will share data with third-party providers.
More InformationYou are currently viewing a placeholder content from YouTube. To access the actual content, click the button below. Please note that doing so will share data with third-party providers.
More InformationYou are currently viewing a placeholder content from Bunny Stream. To access the actual content, click the button below. Please note that doing so will share data with third-party providers.
More InformationYou are currently viewing a placeholder content from Wistia. To access the actual content, click the button below. Please note that doing so will share data with third-party providers.
More Information