Skip to content

Releases: linkedin/goavro

Release to expose underlying TypeName in Codec

02 May 20:09
d517b19
Compare
Choose a tag to compare

This release updates the Codec type to surface the underlying typeName via a public API

  • Adds the TypeName method to Codec to expose the underlying type name outside the goavro package scope
  • Adds the ShortName method to Name to expose the short name (i.e. record name excluding classpath) as a public method

Ref. PR: #285 by @mittal-aashay

Release to fix Version Number

08 Sep 15:27
9a47646
Compare
Choose a tag to compare

The version number should be the full v2.12.0 to be fully semver compatible. There's no new content in this release. Its just the fix to the version number.

Thanks

Here are the release notes copied from v2.12:

This release includes full support for sending regular internet JSON into avro and getting regular JSON back out again, and a large number of cleanup and fixing. Many thanks to the help from the community!

  • A large number of cleaning up and fixes from @mihaitodor
  • Full two-way json serialization support for regular internet json
  • OCF reader and writer from @kishaningithub

About JSON to Avro and Avro to JSON

Regular internet json is wild and can have various values for a particular field, such as a "human" field having a value of null of maybe a string containing a name, or even a struct containing details about the "human". To handle accepting JSON of such a form, the previous release provided a one-way JSON encoder, where an avro union is required to be defined, in order to accept the possible types that we will can expect. This functionality was provided in the previous release, but the previous release did not take avro encoded data from within the avro ecosystem and produce regular internet JSON. Instead it produced the style of avro-json described in the avro-spec. This release provides the full two-way support, so that we can take regular internet JSON into the avro ecosystem, and we can send it back out into the internet's standard json ecosystem.

There are many examples in union_test.go where the production of standard JSON is done via the test utility function testNativeToTextualJSONPass.

Also much gratitude to @karrick for his work on this project and his ongoing interest and support. Though he did not contribute directly to this release, I still wanted to thank him here.

Two Way Standard JSON

07 Sep 16:44
9a47646
Compare
Choose a tag to compare

This release includes full support for sending regular internet JSON into avro and getting regular JSON back out again, and a large number of cleanup and fixing. Many thanks to the help from the community!

  • A large number of cleaning up and fixes from @mihaitodor
  • Full two-way json serialization support for regular internet json
  • OCF reader and writer from @kishaningithub

About JSON to Avro and Avro to JSON

Regular internet json is wild and can have various values for a particular field, such as a "human" field having a value of null of maybe a string containing a name, or even a struct containing details about the "human". To handle accepting JSON of such a form, the previous release provided a one-way JSON encoder, where an avro union is required to be defined, in order to accept the possible types that we will can expect. This functionality was provided in the previous release, but the previous release did not take avro encoded data from within the avro ecosystem and produce regular internet JSON. Instead it produced the style of avro-json described in the avro-spec. This release provides the full two-way support, so that we can take regular internet JSON into the avro ecosystem, and we can send it back out into the internet's standard json ecosystem.

There are many examples in union_test.go where the production of standard JSON is done via the test utility function testNativeToTextualJSONPass.

Also much gratitude to @karrick for his work on this project and his ongoing interest and support. Though he did not contribute directly to this release, I still wanted to thank him here.

Custom Logical Types, Enums, Standard JSON

26 Jan 23:08
91f8062
Compare
Choose a tag to compare

This release contains 3 new capabilities and a fix for canonical representation for enums

  • Allow decimal logical type of precision 1
  • Added support for custom logical types
  • Enum should be managed like records, parent namespace should be used to generate canonical form
  • Added nativeFromTextual to support standard json
  • Added avro roundtrip debugging tool

Support for Ingestion of Common JSON

29 Sep 03:48
5d44cdf
Compare
Choose a tag to compare
Pre-release

There is an increasing demand to ingesting common JSON into the avro-encoded systems.

This release adds support for accepting common JSON , so we can take JSON from regular (non-avro-enabled) applications and encode it into avro per a schema in the expected way. This was a problem because union-types were expected to be of a form that satisfies the avro json encoding spec:

avro spec: ["null", "string"]
common json: null, or "some string"
avro json encoded: null and {"string": "some string"}

Example code, and tests are included in union_test.go

README.md directs users to import using gopkg.in

09 Nov 14:57
Compare
Choose a tag to compare

Update to project README.md file recommending that users import this project using gopkg.in style import statements for both V1 and V2 of this library.

This is because V2 was released prior to the proposal to add package version support to the Go toolchain, which requires library authors to leave V1 code in the top level directory of the repository, and create a v2 directory for V2 of the library.