marley


License

License

GroupId

GroupId

com.gu
ArtifactId

ArtifactId

marley_2.12
Last Version

Last Version

0.2.17
Release Date

Release Date

Type

Type

jar
Description

Description

marley
marley
Project URL

Project URL

https://github.com/guardian/marley
Project Organization

Project Organization

com.gu
Source Code Management

Source Code Management

https://github.com/guardian/marley

Download marley_2.12

How to add to project

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

Dependencies

compile (6)

Group / Artifact Type Version
org.scala-lang : scala-library jar 2.12.10
org.apache.avro : avro jar 1.7.7
org.parboiled : parboiled_2.12 jar 2.1.8
org.scala-lang : scala-reflect jar 2.12.10
com.twitter : scrooge-core_2.12 jar 19.10.0
org.apache.thrift : libthrift jar 0.12.0

provided (1)

Group / Artifact Type Version
org.scala-lang : scala-compiler jar 2.12.10

test (3)

Group / Artifact Type Version
com.gu » thriftexample_2.12 jar 0.2.17
org.scalatest : scalatest_2.12 jar 3.0.8
org.scalacheck : scalacheck_2.12 jar 1.14.2

Project Modules

There are no modules declared in this project.

Marley Build Status Maven Central

Marley is a library for serialising Scrooge generated classes representing Thrift objects as Avro with minimal boilerplate.

Installation

libraryDependencies ++= Seq(
  "com.gu" %% "marley" % "0.2.16"
)

Usage

import com.gu.marley._

implicit val enumSer = AvroSerialisable.enum[ExampleEnum]
implicit val structSer = AvroSerialisable.struct[ExampleStruct]

AvroFile.write(Seq(struct))(file)

val readStructs: Iterable[ExampleStruct] = AvroFile.read[ExampleStruct](file)

Is this usable in production?

Marley has been extracted from a project where it's been running successfully for a number of months.

Marley is macro based and doesn't perform any runtime reflection. I haven't done any micro-benchmarking, but it's currently serialising more than 5000 reasonably complicated messages/minute on an EC2 t2.medium without breaking a sweat.

License

Marley is licensed under the Apache License, Version 2.0 (the "License"); you may not use this software except in compliance with the License.

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

com.gu

The Guardian

The source code of the world's leading liberal voice

Versions

Version
0.2.17
0.2.16
0.2.15
0.2.13
0.2.12
0.2.10
0.2.9