Create bigquery schema from an avro schema.
Project description
Avro to Bigquery
About The Project
Avro to bigquery is a simple project to create a bigquery schema from an avro schema.
Getting Started
Installation`
pip install avro-to-bigquery
Usage
With avro_schema.avsc:
{
"type": "record",
"name": "User",
"namespace": "example.avro",
"fields": [
{"name": "favorite_number", "type": "int", "doc": "Favorite number"}
]
}
>>> import json
>>> from pathlib import Path
>>> from avro_to_bigquery import convert_schema
>>> schema = json.loads(Path("avro_schema.avsc").read_text())
>>> print(convert_schema(schema))
(SchemaField('favorite_number', 'INTEGER', 'NULLABLE', 'Favorite number', (), ()),)
Roadmap
See the open issues for a list of proposed features (and known issues).
Contributing
Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated. For detailed contributing guidelines, please see https://github.com/wayfair-incubator/avro-to-bigquery/blob/main/CONTRIBUTING.md
License
Distributed under the MIT
License. See LICENSE
for more information.
Contact
Project Link: https://github.com/wayfair-incubator/avro-to-bigquery/
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file avro-to-bigquery-0.3.1.tar.gz
.
File metadata
- Download URL: avro-to-bigquery-0.3.1.tar.gz
- Upload date:
- Size: 5.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3d520362d356cce2c277cfe7f0a29ddebab710a8f5d19b6079a4c858d4b23d1d |
|
MD5 | 42cff1f738b8117999c58c87468e43ce |
|
BLAKE2b-256 | f7dfafb0030000433e8634932ef86b300b6ed132e8341eeaaca74b434c5beb2b |
File details
Details for the file avro_to_bigquery-0.3.1-py3-none-any.whl
.
File metadata
- Download URL: avro_to_bigquery-0.3.1-py3-none-any.whl
- Upload date:
- Size: 6.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4852033dac92d25accbd0de4d01f2a3bef8f8b8edb9a51d17126f9e62800e347 |
|
MD5 | c41d9226159bfe8945765767f75e78e5 |
|
BLAKE2b-256 | 50888568d4c55b1ad25192911eb99d80cf6363938cb13bd43cb1b8c28fe29f64 |