Welcome to intake-hbase’s documentation!¶
Quickstart¶
intake-hbase
provides quick and easy access to tabular data stored in
Apache HBase
This plugin reads hbase query results without random access: there is only ever a single partition.
Installation¶
To use this plugin for intake, install with the following command:
conda install -c intake intake-hbase
Usage¶
Ad-hoc¶
After installation, the function intake.open_hbase
will become available. It can be used to execute queries on the hbase
server, and download the results as a list of dictionaries.
Three parameters are of interest when defining a data source:
Creating Catalog Entries¶
To include in a catalog, the plugin must be listed in the plugins of the catalog:
plugins:
source:
- module: intake_hbase
and entries must specify driver: hbase
.
Using a Catalog¶
API Reference¶
intake_hbase.source.HBaseRSource |
-
class
intake_hbase.source.
HBaseSource
(table, connection, divisions=None, qargs=None, metadata=None)[source]¶ Execute a query on HBASE
The data are returned as tuples of (ID, data) where the data is a dict of field-value pairs.
Parameters: - table: str
HBase table to query. If within a project/namespace, either use the full table name, e.g.,
myproject_mytable
or usetable_prefix='myproject'
in the connection parameters.- connection: str or dict
See happybase connection arguments https://happybase.readthedocs.io/en/latest/api.html#happybase.Connection
- divisions: list or None
Partition key boundaries. If None, will have one partition for the whole table. The number of partitions will be
len(divisions) - 1
.- qargs: dict or None
Further arguments to
table.scan
, see https://happybase.readthedocs.io/en/latest/api.html#happybase.Table.scan
Attributes: - datashape
- description
hvplot
Returns a hvPlot object to provide a high-level plotting API.
plot
Returns a hvPlot object to provide a high-level plotting API.
Methods
close
()Close open resources corresponding to this data source. discover
()Open resource and populate the source attributes. read
()Return all results read_chunked
()Return iterator over container fragments of data source read_partition
(i)Return a (offset_tuple, container) corresponding to i-th partition. to_dask
()Return a dask-bag of results yaml
()Return YAML representation of this data-source
\ Sort by:\ best rated\ newest\ oldest\
\\
Add a comment\ (markup):
\``code``
, \ code blocks:::
and an indented block after blank line