commons-avro


License

License

GroupId

GroupId

com.gilt
ArtifactId

ArtifactId

commons-avro_2.10
Last Version

Last Version

0.0.3
Release Date

Release Date

Type

Type

jar
Description

Description

commons-avro
commons-avro
Project URL

Project URL

https://github.com/gilt/commons-avro
Project Organization

Project Organization

com.gilt
Source Code Management

Source Code Management

https://github.com/gilt/commons-avro.git

Download commons-avro_2.10

How to add to project

<!-- https://jarcasting.com/artifacts/com.gilt/commons-avro_2.10/ -->
<dependency>
    <groupId>com.gilt</groupId>
    <artifactId>commons-avro_2.10</artifactId>
    <version>0.0.3</version>
</dependency>
// https://jarcasting.com/artifacts/com.gilt/commons-avro_2.10/
implementation 'com.gilt:commons-avro_2.10:0.0.3'
// https://jarcasting.com/artifacts/com.gilt/commons-avro_2.10/
implementation ("com.gilt:commons-avro_2.10:0.0.3")
'com.gilt:commons-avro_2.10:jar:0.0.3'
<dependency org="com.gilt" name="commons-avro_2.10" rev="0.0.3">
  <artifact name="commons-avro_2.10" type="jar" />
</dependency>
@Grapes(
@Grab(group='com.gilt', module='commons-avro_2.10', version='0.0.3')
)
libraryDependencies += "com.gilt" % "commons-avro_2.10" % "0.0.3"
[com.gilt/commons-avro_2.10 "0.0.3"]

Dependencies

compile (3)

Group / Artifact Type Version
org.scala-lang : scala-library jar 2.10.3
org.apache.avro : avro jar 1.7.6
org.scala-lang : scala-pickling_2.10 jar 0.8.0

test (2)

Group / Artifact Type Version
org.scalatest : scalatest_2.10 jar 2.1.3
org.scalacheck : scalacheck_2.10 jar 1.11.3

Project Modules

There are no modules declared in this project.

DEPRECATED

This library has been deprecated. We will not accept pull requests or make any changes to this repo going forward. If you are using gfc-avro already and want to add new features or fix any bugs you may find, please fork the repo and continue development there.

Gfc Avro

An Avro library in Scala base on scala pickling. Supports the conversion of case class to avro records or schema definitions.

Example Usage

Converting a case class to avro

case class SomeObject(id: Int)

import scala.pickling._
import com.gilt.pickling.avro._

val obj = SomeObject(1)
val pckl = obj.pickle

Convert avro bytes to case class

import scala.pickling._
import com.gilt.pickling.avro._

val bytes = ...

val obj = bytes.unpickle[SomeObject]

Converting a case class to avro schema

val schema = Schema[SomeObject]

ToDos/Missing Features

  1. No support for Enums
  2. No support for fixed length.
  3. Schema resolution has not been implemented.
  4. List[Byte] and Set[Byte] should be converted avro bytes type instead of an array of bytes.
  5. Blocked array or maps are not supported.
  6. Writing case classes straight into an 'InputStream'.

License

Copyright 2014 Gilt Groupe, Inc.

Licensed under the Apache License, Version 2.0: http://www.apache.org/licenses/LICENSE-2.0

com.gilt

Gilt Tech

Versions

Version
0.0.3