Java streaming parser/serializer for Ion.
Clone or download
raganhan Memleak gzip (#204)
* Fixing memleak when auto detecting gzipped bytes

Correctly closes the created IonReader in order to free the memory
allocated outside the heap by GzipInputStream.

For methods that return an iterator changed the signature to
return a CloseableIterator which is closeable permiting users to
close the iterator. This iterator also closes itself when there are
no more values next to return.

The gzip auto detect functionality should be removed from this package
as it is an orthogonal concern to reading/writing Ion data. Right now
our API has to close streams created by users to guaranteed that the
internal wrapped Gzip stream is correctly closed.

Latest commit 9dc90d4 Jan 8, 2019

Amazon Ion Java

A Java implementation of the Ion data notation.

Build Status Maven Central Javadoc


This repository contains a git submodule called ion-tests, which holds test data used by ion-java's unit tests.

The easiest way to clone the ion-java repository and initialize its ion-tests submodule is to run the following command.

$ git clone --recursive ion-java

Alternatively, the submodule may be initialized independently from the clone by running the following commands.

$ git submodule init
$ git submodule update

The submodule points to the tip of the branch of the ion-tests repository specified in ion-java's .gitmodules file.

ion-java may now be built and installed into the local Maven repository with the following command.

$ mvn install

Pulling in Upstream Changes

To pull upstream changes into ion-java, start with a simple git pull. This will pull in any changes to ion-java itself (including any changes to its .gitmodules file), but not any changes to the ion-tests submodule. To make sure the submodule is up-to-date, use the following command.

$ git submodule update --remote

This will fetch and update the ion-tests submodule from the ion-tests branch currently specified in the .gitmodules file.

For detailed walkthroughs of git submodule usage, see the Git Tools documentation.

Depending on the Library

To start using ion-java in your code with Maven, insert the following dependency into your project's pom.xml:


Using the Library

A great way to get started is to use the Ion cookbook. The API documentation will give a lot of detailed information about how to use the library.