mir-ion 2.0.8

Fast, Expressive, and Easy to use Ion, JSON, Msgpack Serialization Library with SIMD optimization.


To use this package, run the following command in your project's root directory:

Manual usage
Put the following dependency into your project's dependences section:

Dub version Dub downloads License codecov Build Status CircleCI Ion Test Status

Mir Ion

This library seeks to implement the Ion file format. We aim to support both versions of Ion (text & binary Ion), as well as providing an implementation of the format that is performant and easy-to-use.

Mir Ion serialization engine supports

Mir Ion supports JSON de/serialization out of the box. On the other hand, you may want to use another our JSON library -- Asdf. It uses the same serialization User Defined Attributes.

Benchmarks

kostya/benchmarks

ARM64

Twitter data set

Test data from nativejson-benchmark

-------------------------------------------------
Binary Ion writing      0.601 GB/s
     is equivalent of   1.598 GB/s for JSON

JSON    -> binary Ion   1.16 GB/s

MsgPack -> binary Ion   0.841 GB/s
     is equivalent of   1.321 GB/s for JSON


Ion is 96% smaller then minimized JSON
   and 69% smaller then MsgPack
- - - - - - - - - - - - - - - - - - - - - - - - -
processed file: benchmark/twitter.json
number of iterations: 2000
os: 64bit osx
-------------------------------------------------

Kostya data set

Test data from kostya/benchmarks.

-------------------------------------------------
Binary Ion writing      0.251 GB/s
     is equivalent of   1.063 GB/s for JSON

JSON    -> binary Ion   0.6 GB/s

MsgPack -> binary Ion   0.309 GB/s
     is equivalent of   1.098 GB/s for JSON


Ion is 134% smaller then minimized JSON
   and 19% smaller then MsgPack
- - - - - - - - - - - - - - - - - - - - - - - - -
processed file: /tmp/1.json
number of iterations: 10
os: 64bit osx
-------------------------------------------------

Documentation

You can find the documentation for this library here. Additionally, for examples of the Ion format, you can check the Ion Cookbook

Exceptions

Mir Ion internals are @nogc and almost all are preallocated. If DIP1008 is enabled, then the parsing exception will contains additional information about error location in the file and last occured key.

Feature Status

  • [x] Binary Ion Value parsing and skip-scan iteration.
  • [x] Binary Ion conversions to D types.
  • [x] Binary Ion conversions from D types.
  • [x] Fast hash table for Ion Symbol Tables
  • [x] Fast CTFE Symbol Table for deserialization
  • [x] Ion Symbol Tables
  • [x] JSON to Ion
  • [x] Ion to JSON
  • [x] Text Ion to Ion
  • [x] Ion to Text Ion
  • [x] Serialization API
  • [x] Deserialization API
  • [x] Precise decimal to floating conversion (except subnormals)
  • [x] Precise floating to decimal conversion.
  • [x] Local Symbol Tables
  • [ ] Shared Symbol Tables
  • [x] Chunked JSON reader
  • [x] Chunked binary Ion Value Stream reader
  • [x] MessagePack parsing
  • [x] Ion to MessagePack
Authors:
  • Ilia Ki (Asdf & Mir Ion)
  • Yannick Koechlin (Asdf)
Dependencies:
mir-cpuid, mir-algorithm
Versions:
2.1.3 2022-Dec-07
2.1.2 2022-Nov-23
2.1.1 2022-Oct-24
2.1.0 2022-Oct-22
2.0.23 2022-Oct-20
Show all 199 versions
Download Stats:
  • 107 downloads today

  • 612 downloads this week

  • 2915 downloads this month

  • 242158 downloads total

Score:
3.3
Short URL:
mir-ion.dub.pm