Preview. Stack v4.0 has not been released, and what is documented here can still change before it does. The current release is v3.2, which does not have this page.Go to Ledger in v3.2
Ledger

gRPC API

Locate the protobuf contract and decide when a direct gRPC integration is appropriate.

This hidden page maps the gRPC services found in the Ledger 3.0 source snapshot. It is not yet a published gRPC client contract.

Service boundaries#

The source defines separate listeners and service classes. A service being present in the repository does not make it safe or supported for application clients.

BoundaryServices in the snapshotIntended caller
Client-facing service listenerBucketService; authorized ClusterServiceApplications for business and query operations; ledgerctl or authorized operators for cluster administration
Internal Raft listenerRaftTransportService; ClusterBootstrapService; SnapshotServiceLedger nodes only
Restore-only service listenerRestoreServiceA restricted recovery workflow against a fresh target data directory
Health serviceStandard gRPC Health is registered in several modes or listenersDepends on the listener; its external availability meaning is not finalized

ClusterService belongs to the client-facing listener but remains an administrative surface. The internal Raft and snapshot services must never be exposed as application APIs. Restore mode runs a deliberately reduced service set and requires its own network boundary.

Preview source#

The current protobuf definitions live in misc/proto on release/v3.0. Use them to audit the intended surface only. Wait for a final, release-tagged descriptor set before generating a production client.

Reflection can help inspect a running development server. It does not establish which listener is public, which services are supported, or whether a field is compatible across releases.

The external gRPC Health contract is unresolved in this snapshot. Do not equate a successful gRPC Health response with strict cluster availability. For Kubernetes, use HTTP /readyz; use HTTP /clusterz to verify healthy Raft connectivity and an elected leader as documented in HTTP API. Monitor the separate disk-space and clock-skew write gates directly.

Read controls and request metadata#

A future direct client will need to account for more than request messages:

  • send the bearer token in authorization metadata when authentication is enabled;
  • choose a read consistency level deliberately;
  • use min_log_sequence only on request messages that carry ReadOptions; for example, the preview GetTemplateUsage method has no checkpoint or minimum-sequence barrier;
  • preserve pagination cursors returned by streaming list operations;
  • set deadlines and handle leader-election failures as retryable only when the operation is safe to repeat.

The default read behavior is linearizable. A stale read can reduce coordination for monitoring or other explicitly lag-tolerant use cases. See Consistency and Checkpoints before changing the default.

Gates for publication#

Keep this page hidden until:

  1. a release-tagged descriptor set is published from the same revision as the Ledger image;
  2. the public listener exposes only the documented client-facing and authorized administrative services;
  3. network and authentication tests prove that internal Raft and restore-only services are isolated;
  4. the meaning of gRPC Health is defined and tested for every exposed listener and server mode;
  5. generated clients pass compatibility, authentication, consistency, deadline, pagination, and retry tests against the released server.
  6. protobuf compatibility tests cover removed fields and changed public log payload semantics before any mixed-client or mixed-binary support is claimed.