Skip to content

A protobuf plugin to generate AWS Glue Data Catalog compatible schemas.

License

Notifications You must be signed in to change notification settings

simo7/protoc-gen-hive

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

protoc-gen-hive

A protoc plugin that generates json-formatted Hive schemas from protobuf files. See examples.

Json is a convenient format to intereact with the AWS Glue API and create/update tables in the AWS Glue Data Catalog.

Installation

go get github.com/simo7/protoc-gen-hive

Alternatively clone the repo and build the plugin:

go build -o bin/protoc-gen-hive .

export PATH=$PWD/bin:$PATH

Usage

protoc \
    --hive_out=./ \
    --hive_opt=paths=source_relative \
    examples/person.proto

Well-known Protobuf types

Reference: https://developers.google.com/protocol-buffers/docs/reference/google.protobuf.

The following types are supported:

  • google.protobuf.Timestamp

Compatibility

It's tested against the new protobuf API google.golang.org/protobuf or version 1.4.0 of the legacy API github.com/golang/protobuf.

About

A protobuf plugin to generate AWS Glue Data Catalog compatible schemas.

Resources

License

Stars

Watchers

Forks

Packages

No packages published