Skip to main content

OpenDataDiscovery ODDRN

Requirements

Python >= 3.7

Installation

    pip install oddrn

Usage and configuration

from oddrn import Generator
oddrn_gen = Generator(data_source="postgresql", cloud={"type":"aws", "region":"reg_id", "account": "acc_id"})
oddrn_gen.get_column("db_name","schema_name","table_name", "column_name")

Generator parameters:

  • "data_source" - required. Can be one of:
["postgresql", "mysql", "kafka", "glue", "snowflake", "airflow", "tableau", "hive", "dynamodb", "kuberflow", "odbc", "mssql", "oracle", "redshift"]
  • cloud: dict - optional. At now support only AWS. Mutually exclusive with "prefix" or "prefixes" params)
  • host: str or hosts: list[str] - optional.
  • prefix: str or prefixes: list[str] - optional. Mutually exclusive with "cloud" param

Methods list:

  • postgresql:
    • get_database(database_name)
    • get_schema(database_name, schema_name)
    • get_table(database_name, schema_name, table_name)
    • get_column(database_name, schema_name, table_name, column_name)
  • mysql
    • get_database(database_name)
    • get_table(database_name, table_name)
    • get_column(database_name, table_name, column_name)
  • kafka
    • Work in progress
  • glue
    • get_owner(owner_name)
    • get_database(database_name)
    • get_table(database_name, table_name)
    • get_column(database_name, table_name, column_name)
    • get_job(job_name)
  • snowflake
    • get_owner(owner_name)
    • get_warehouse(warehouse_name)
    • get_database(warehouse_name, database_name)
    • get_schema(warehouse_name, database_name, schema_name)
    • get_table(warehouse_name, database_name, schema_name, table_name)
    • get_view(warehouse_name, database_name, schema_name, view_name)
    • get_column(warehouse_name, database_name, schema_name, table_name, column_name)
  • airflow
    • Work in progress
  • tableau
    • get_database(database_name)
    • get_schema(database_name, schema_name)
    • get_table(database_name, schema_name, table_name)
    • get_column(database_name, schema_name, table_name, column_name)
    • get_workbook(workbook_name)
    • get_worksheet(workbook_name, worksheet_name)
  • hive
    • get_owner(owner_name)
    • get_database(database_name)
    • get_table(database_name, table_name)
    • get_column(database_name, table_name, column_name)
  • dynamodb
    • get_database(database_name)
    • get_schema(database_name, schema_name)
    • get_table(database_name, schema_name, table_name)
    • get_column(database_name, schema_name, table_name, column_name)
  • kuberflow
    • get_pipeline(pipeline_id)
    • get_experiment(experiment_id)
    • get_experiment_run(experiment_id, run_id)
  • odbc
    • get_database(database_name)
    • get_schema(database_name, schema_name)
    • get_table(database_name, schema_name, table_name)
    • get_column(database_name, schema_name, table_name, column_name)
  • mssql
    • get_database(database_name)
    • get_schema(database_name, schema_name)
    • get_table(database_name, schema_name, table_name)
    • get_column(database_name, schema_name, table_name, column_name)
  • oracle
    • get_database(database_name)
    • get_schema(database_name, schema_name)
    • get_table(database_name, schema_name, table_name)
    • get_column(database_name, schema_name, table_name, column_name)
  • redshift
    • get_database(database_name)
    • get_schema(database_name, schema_name)
    • get_table(database_name, schema_name, table_name)
    • get_column(database_name, schema_name, table_name, column_name)

If you need to generate full custom oddrn, use method create_full_oddrn(data: OrderedDict) Example:

from oddrn import Generator
from collections import OrderedDict
data = OrderedDict({
    "sources": "CustomSource",
    "hosts": "localhost:3333",
    "databases": "test_db",
    "tables": "test_table"
})
Generator.create_full_oddrn(data)
'//sources/CustomSource/hosts/localhost:3333/databases/test_db/tables/test_table'

Cloud support:

To add new cloud, you need to add new dataclass with method get_oddrn to clouds.py and add it to cloud_map variable

Adapter support:

To add new adapter, simply add new class to oddrn.py. Parameter "source" is required.

Metadata

Release files for oddrn 0.0.8

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for oddrn 0.0.8
File Size Uploaded Provenance Actions
oddrn-0.0.8.tar.gz 5.1 kB Without provenance Details for oddrn-0.0.8.tar.gz

Release files / oddrn-0.0.8.tar.gz

Download URL oddrn-0.0.8.tar.gz
Size 5.1 kB
Tags Source
SHA-256 checksum
How to use checksums
a55a4beccf53e1548700a8427caa8f9b5b0a934986becc5973c9cba2ef4325eb
BLAKE2b-256 checksum
How to use checksums
78bbaf4e921e188be954adbdab322ad7db94bdac7da5ad0957b57bfbd04cf510
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.1 importlib_metadata/3.6.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.8.5

Security for oddrn 0.0.8

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page