Skip to content

[Protocol/PostgreSQL] MVP PostgreSQL Wire Protocol Implementation #47

@avelino

Description

@avelino

ChronDB aims to act as a Git-backed schemaless database that can be accessed through multiple protocols.
A PostgreSQL wire-compatible interface would allow developers to connect using psql, ORMs, and BI tools without any special drivers.

Why
This unlocks huge interoperability — ChronDB could be queried from tools like Superset, Metabase, or any language that supports PostgreSQL natively.

What to do

  • Implement minimal PostgreSQL wire protocol (startup/authentication, text protocol).
  • Map KV reads/writes to SQL-like queries:
    • Example: SELECT key, value FROM kv WHERE key = $1
  • Expose historical commits via a virtual view kv_history (key, commit_id, ts, value).
  • Test with psql and pgx.

Acceptance Criteria

  • PostgreSQL wire handshake working with basic auth.
  • Basic SELECT and INSERT supported.
  • kv_history view returning consistent history.
  • Works with Postgres-native clients and ORMs.

References

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions