Open-Awesome
CategoriesAlternativesStacksSelf-HostedExplore
Open-Awesome

© 2026 Open-Awesome. Curated for the developer elite.

TermsPrivacyAboutGitHubRSS
  1. Home
  2. Rust
  3. rust-ajson

rust-ajson

MITRust

A high-performance Rust JSON parser that extracts values using dotpath syntax, inspired by gjson.

Visit WebsiteGitHubGitHub
108 stars12 forks0 contributors

What is rust-ajson?

AJSON is a Rust JSON parser that allows developers to quickly extract specific values from JSON data using a dotpath query syntax. It is a port of the popular Go library gjson, designed for high-performance scenarios where only partial data access is needed. The library avoids full deserialization, making it significantly faster for targeted queries.

Target Audience

Rust developers working with JSON data who need to efficiently query or extract specific fields without parsing entire structures, such as those building data processing pipelines, APIs, or performance-sensitive applications.

Value Proposition

Developers choose AJSON for its exceptional speed in JSON value extraction, its intuitive dotpath syntax similar to gjson, and its ability to query complex nested structures with minimal overhead compared to traditional deserialization libraries.

Overview

Rust port of gjson,get JSON value by dotpath syntax

Use Cases

Best For

  • Extracting specific fields from large JSON documents without full parsing
  • Building high-performance data processing tools in Rust
  • Querying nested JSON structures with conditional logic
  • Replacing slower JSON parsers like serde_json for read-heavy operations
  • Implementing lightweight JSON query interfaces in applications
  • Porting gjson-based Go projects to Rust with similar syntax

Not Ideal For

  • Projects requiring full JSON deserialization into Rust structs with serde integration
  • Teams that prioritize extensive documentation and API stability for long-term maintenance
  • Applications needing complex JSON transformations or validations beyond simple querying
  • Environments where JSON serialization or schema validation is a primary concern

Pros & Cons

Pros

Blazing Fast Parsing

Benchmarks show AJSON parsing is over 10x faster than serde_json for targeted queries, as it avoids full deserialization by extracting values directly from the JSON string.

Intuitive Dotpath Syntax

Uses a concise syntax inspired by gjson, enabling easy extraction with wildcards and conditional queries like `friends.#(last=="Murphy")#.first` for complex nested data.

Efficient Value Conversion

Provides convenient methods such as as_str() and as_u64() to quickly convert extracted values to Rust types without additional parsing overhead.

JSON Construction Support

Allows building new JSON structures using selector syntax, offering flexibility beyond mere reading, as shown in examples with assembled outputs.

Cons

Documentation Gaps

The README's todo list explicitly includes 'Add documentation', indicating current documentation is incomplete or lacking, which can hinder onboarding and advanced usage.

API Instability Risks

At version 0.3 with a todo to 'Follow api-guidelines', the library is in early development, meaning potential breaking changes and less predictability for production code.

Limited Ecosystem

Compared to established alternatives like serde_json, AJSON has fewer integrations, community resources, and tooling support, which may complicate adoption in complex projects.

Frequently Asked Questions

Quick Stats

Stars108
Forks12
Contributors0
Open Issues3
Last commit3 years ago
CreatedSince 2019

Tags

#query-language#rust-library#json-path#json#rust#data-extraction#json-parser#performance

Built With

R
Rust

Links & Resources

Website

Included in

Rust56.6k
Auto-fetched 1 day ago

Related Projects

jsonjson

Strongly typed JSON library for Rust

Stars5,570
Forks647
Last commit10 days ago
prostprost

PROST! a Protocol Buffers implementation for the Rust Language

Stars4,704
Forks621
Last commit2 days ago
rkyvrkyv

Zero-copy deserialization framework for Rust

Stars4,235
Forks228
Last commit14 days ago
https://github.com/ron-rs/ronhttps://github.com/ron-rs/ron

Rusty Object Notation

Stars3,915
Forks144
Last commit1 day ago
Community-curated · Updated weekly · 100% open source

Found a gem we're missing?

Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.

Submit a projectStar on GitHub