Skip to main content

Python client for the Okera Data Access Service

Project description

Python client for RecordService implementations.

Dependencies

Required:

  • Python 3.4+

  • six, bit_array, thriftpy2, urllib3, certifi

pip3 install six bit_array thriftpy2 urllib3 certifi

Optional:

  • pandas for conversion to DataFrame objects

Installation

pip3 install pyokera

To verify:

>>> import okera.odas
>>> okera.odas.version()
'##OKERA_RELEASE_VERSION##'

Usage

from okera import context
ctx = context()
with ctx.connect(host='localhost', port=12050) as conn:
    conn.list_databases()
    pd = conn.scan_as_pandas("okera_sample.sample")
    pd

To enable a connection to a server with token-authentication:

from okera import context
ctx = context()
ctx.enable_token_auth(token_str='my-token')
with ctx.connect(host='localhost', port=12050) as conn:
    conn.list_databases()

To enable a connection to a server with kerberos-authentication:

from okera import context
ctx = context()
# Connecting to server principal 'cerebro/service@REALM'
ctx.enable_kerberos('cerebro', host_override='service')
with ctx.connect(host='localhost', port=12050) as conn:
    conn.list_databases()

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

pyokera-2.9.0.tar.gz (338.7 kB view details)

Uploaded Source

Built Distribution

pyokera-2.9.0-py3.6.egg (740.9 kB view details)

Uploaded Source

File details

Details for the file pyokera-2.9.0.tar.gz.

File metadata

  • Download URL: pyokera-2.9.0.tar.gz
  • Upload date:
  • Size: 338.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/44.0.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.6.9

File hashes

Hashes for pyokera-2.9.0.tar.gz
Algorithm Hash digest
SHA256 b969909e8aed1aebde54d93a66116c6b1fa22529fe1b7708825850776f9c559f
MD5 da0d0da5f1320e7bd148f8cfa52c1ad0
BLAKE2b-256 081ba94adfacee3cdcdf85837634e10efd42675f43ec0be08a34dd066b75d9ec

See more details on using hashes here.

File details

Details for the file pyokera-2.9.0-py3.6.egg.

File metadata

  • Download URL: pyokera-2.9.0-py3.6.egg
  • Upload date:
  • Size: 740.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/44.0.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.6.9

File hashes

Hashes for pyokera-2.9.0-py3.6.egg
Algorithm Hash digest
SHA256 ba3d116527cd5e0f119272453e713c507f803545aa039c3dcc6c94a4d95f113a
MD5 3c1907f827db6a0c65b2f8add5be70d8
BLAKE2b-256 ca3a3fff9f17f277954ec07378a2e3208b25c8188ab093f6cd5c92136adf47c5

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page