A Python client for the Thrift interface to Hive Metastore
Project description
pymetastore 🐝 🐍
pymetastore
is a Python client for Hive Metastore.
Features
- Python-friendly interface for Hive Metastore
- Comprehensive support for metadata operations
- Fully compatible with the Hive metastore service over Thrift protocol
Installation
Install pymetastore with pip:
pip install pymetastore
Quick Start
Here's a taste of using pymetastore
to connect to Hive Metastore and interact with metadata:
from pymetastore.metastore import HMS
with HMS.create(host="localhost", port=9083) as hms:
databases = hms.list_databases()
database = hms.get_database(name="test_db")
tables = hms.list_tables(database_name=database.name)
table = hms.get_table(
database_name=database.name,
table_name=tables[0],
)
partitions = hms.list_partitions(
database_name=database.name,
table_name=table.name,
)
partition = hms.get_partition(
database_name=database.name,
table_name=table.name,
partition_name="partition=1",
)
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pymetastore-0.3.0.tar.gz
(130.9 kB
view hashes)
Built Distribution
pymetastore-0.3.0-py3-none-any.whl
(131.6 kB
view hashes)
Close
Hashes for pymetastore-0.3.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | bc1ee87a094d494a289bc069a882441f081a7bf4dc1fcfa2d84456339a3191cb |
|
MD5 | 896708a5d30ccb7a646108322b40cddc |
|
BLAKE2b-256 | c2861e64f5a72e6ed1d98747f6b5d96124c513045122e756cabd654316ce7d15 |