Lance Unity Namespace¶
Lance Unity Namespace is an implementation using Unity Catalog. For more details about Unity Catalog, please read the Unity Catalog Documentation.
Configuration¶
The Lance Unity namespace accepts the following configuration properties:
| Property | Required | Description | Default | Example |
|---|---|---|---|---|
endpoint |
Yes | Unity Catalog REST API endpoint | http://localhost:8080 |
|
api_path |
No | API path prefix | /api/2.1/unity-catalog |
/api/2.1/unity-catalog |
auth_token |
No | Bearer token for authentication | dapi123456789abcdef |
|
catalog |
Yes | Unity Catalog name to use | main |
|
connect_timeout |
No | HTTP connection timeout in seconds | 10 | 30 |
read_timeout |
No | HTTP read timeout in seconds | 60 | 120 |
max_retries |
No | Maximum number of retries for failed requests | 3 | 5 |
root |
No | Storage root location of the lakehouse on Unity catalog | Current working directory | /my/dir, s3://bucket/prefix |
storage.* |
No | Additional storage configurations to access table | storage.region=us-west-2 |
Authentication¶
The Unity namespace supports the following authentication methods:
- Bearer Token: Set
auth_tokenwith a valid Unity Catalog access token - No Authentication: For local or unsecured Unity Catalog deployments
Namespace Mapping¶
A Unity Catalog server provides a 3-level namespace hierarchy.
- A catalog in Unity Catalog maps to the first level Lance namespace
- A schema (database) in Unity Catalog maps to the second level Lance namespace
- Together they form a 3-level Lance namespace matching Unity's structure
Table Definition¶
A Lance table appears as a Table object in Unity Catalog with the following requirements:
- the
table_typemust be set toEXTERNALto indicate this is not a Unity managed table - the
data_source_formatshould beTEXT(Unity Catalog doesn't recognizeLANCEformat, so we useTEXTas a generic format for external tables) - the
storage_locationmust point to the root location of the Lance table - the
columnsmust be provided with the table schema converted from Lance's Arrow schema to Unity's column format - the
propertiesmust follow:- there is a key
table_typeset tolance(case insensitive) - there is a key
managed_byset to eitherstorageorimpl(case insensitive). If not set, default tostorage - there is a key
versionset to the latest numeric version number of the table. This field will only be respected ifmanaged_by=impl
- there is a key
Requirement for Implementation Managed Table¶
Updates to implementation-managed Lance tables must use Unity Catalog's table versioning mechanism
for conditional updates through the UpdateTable API. The version property must be updated atomically
to prevent concurrent modification conflicts.