Show HN: pg_raw_parse, parse Postgres SQL in Rust 20-60x faster than pg_query.rs
Category: library
Tags: rust, postgresql, parser, ffi, memory-management, ast
Score: 7.5/10 (Innovation: 7, Technical: 9, Documentation: 8, Utility: 6)
pg_raw_parse is a Rust library that provides direct access to the PostgreSQL parser, achieving 20-60x speedup and 90% memory reduction compared to pg_query.rs by avoiding Protobuf serialization and using PostgreSQL's arena allocator. It enables fast parsing, deparsing, and AST manipulation for Rust applications, with a focus on zero-copy and memory safety via lifetime branding.
Target audience: backend devs, database engineers, Rust developers working with PostgreSQL
Repository: https://github.com/pgdogdev/pg_raw_parse · Rust · Apache-2.0 · 3 stars
View on Hacker News