Parse and generate JSON, YAML, or CSV data in an Erlang or Elixir application with high performance.
Stream-decode large JSON or CSV feeds without loading the entire input into memory first.
Query and extract values from JSON documents using jq-style filter syntax.
Replace a slower pure-Erlang parsing library in a system where encoding and decoding speed matters.
| saleyn/glazer | neo773/d9mt | widberg/xlive-research | |
|---|---|---|---|
| Stars | 16 | 16 | 16 |
| Language | C++ | C++ | C++ |
| Setup difficulty | moderate | hard | hard |
| Complexity | 2/5 | 5/5 | 5/5 |
| Audience | developer | developer | developer |
Figures from each repo's GitHub metadata at analysis time.
Requires a C++ toolchain to compile the NIF during installation.
Glazer is a library for Erlang and Elixir applications that converts data between three common text formats, JSON, YAML, and CSV, and native Erlang data structures. Erlang is a programming language used in systems that need high reliability and concurrency. JSON, YAML, and CSV are all ways of storing or transmitting structured data as plain text. Glazer reads those text formats and turns them into Erlang values your code can work with, and it also goes the other direction, turning Erlang values back into those text formats. The library is written in C++ and connects to Erlang through a mechanism called a NIF (native implemented function), which lets Erlang code call compiled C++ code directly for maximum speed. According to the benchmarks in the README, it is faster than every other library tested for JSON encoding and decoding, running about 25 to 40 percent ahead of the next fastest option. For YAML it is 2 to 7 times faster than comparable libraries. For CSV it is 4 to 12 times faster than common alternatives, with some pure-Erlang CSV libraries timing out entirely on large files. For JSON, the library supports reading and writing all standard JSON value types: objects, arrays, strings, numbers including very large integers, booleans, and null. It also supports streaming decoding, which lets you process data as it arrives rather than waiting for a complete input, useful for things like a continuous feed of JSON records over a network. There is optional support for jq filter queries, which lets you search and extract values from a JSON document using a well-known path syntax. A simpler path lookup function is also included and works without the jq dependency. YAML support covers reading YAML documents into Erlang maps, lists, and scalar values, and writing Erlang terms back to YAML block-style output. CSV support handles the standard RFC 4180 format, with options for header rows and field type conversion, plus the same streaming approach available for JSON. XML is intentionally not supported. The README explains that XML's data model does not map cleanly onto Erlang's native structures, and Erlang's standard library already includes an XML parser. The full README is longer than what was shown.
Glazer is a fast C++ powered Erlang and Elixir library that converts data between JSON, YAML, CSV, and native Erlang structures, outperforming pure-Erlang alternatives.
Mainly C++. The stack also includes Erlang, Elixir, C++.
Setup difficulty is rated moderate, with roughly 30min to a first successful run.
Mainly developer.
This repo across BitVibe Labs
Verify against the repo before relying on details.