arcadedb-protocol 0.3.2

A lightweight gRPC client for ArcadeDB: tonic stubs, a typed record-decode path (RecordDecode derive), and a serde_json bridge.
Documentation

A lightweight gRPC client for ArcadeDB.

Generated tonic stubs for com.arcadedb.grpc, a typed record-decode path (RecordDecode derive + runtime), a serde_json bridge for dynamic access, and nothing else.

What's here

  • [client::ArcadeDbClient] — wraps the data + admin gRPC services (connect with retry, auth headers, execute/query/create_database/ bulk_insert, …). Clone (shares one tonic Channel).
  • [error::ArcadeDbError] — the typed error for every fallible client call: match on the failure category (transport, server-rejected command, decode, invalid input) and inspect the gRPC code/metadata.
  • JSON bridge ([grpc_record_to_json]): GrpcRecord → serde_json::Value for callers that need dynamic access. The typed decode path is [RecordDecode] (see below) — there is no serde Deserializer anymore.
  • [record] — the typed-decode runtime: [record::FromGrpcValue], [record::RecordDecodeError], and the property-access helpers used by the generated code.
  • [RecordDecode] (re-exported derive) — #[derive(RecordDecode)] turns a model struct into [TryFrom<&GrpcRecord>]+FromGrpcValuewith per-field type coercion, honoring#[serde(rename/default/flatten)]for drop-in adoption. Custom types plug in via the#[record(with = "...")]attribute or by implementingFromGrpcValue` directly.
  • [RecordEncode] (re-exported derive) — the write-side mirror: derives [record::ToGrpcRecord] so bulk writers call dto.to_grpc_record(class) instead of hand-assembling GrpcValue/GrpcRecord protos.
  • Value builders ([Params], [IntoGrpcValue]) for fixture/test code.

What's NOT here

Identity types and query/repository layers. ArcadeDB's native RID (#bucket:pos) is the only identifier this crate deals with; apps choose their own logical identity scheme (e.g. table:key or an external id) and build their repo + query functions on top of [ArcadeDbClient].

# async fn demo() -> arcadedb_protocol::Result<()> {
use arcadedb_protocol::ArcadeDbClient;
let client = ArcadeDbClient::connect("127.0.0.1:50051", "root", "password", "mydb").await?;
let res = client.query("mydb", "SELECT FROM item LIMIT 10").await?;
println!("{} rows in {} ms", res.len(), res.execution_time_ms);
# Ok(()) }