Skip to main content
Version: 1.0

Lattice Metadata

The wasmCloud lattice makes use of a distributed cache for lattice-wide metadata. The information in this cache is required to allow a lattice to function properly. It contains the following information:

  • Claims - JWTs are stored for both providers and components
  • Link Definitions
  • OCI References - a mapping between OCI URLs and public keys

The persistence and implementation of this cache is actually a NATS JetStream Key-Value Bucket.

Default Configuration

When any wasmCloud host starts up, it will create this bucket with the default configuration if it does not yet exist. The bucket name will always be LATTICEDATA_{lattice-id}, where lattice-id is the unique identifier for the lattice. The default configuration for this bucket is to be unlimited in size and have a single replica.

Production Configuration

The default configuration is fine for local development and testing, but is not suitable for production deploys. It is strongly recommended to configure this bucket with 3 or more replicas, and to configure backups of this data.

To change the number of replicas, the maximum size of the bucket, or any other configuration, create a KV bucket via the nats CLI before the first wasmCloud host starts. If the host detects a pre-existing KV bucket when it starts, it will simply reuse it.


It is strongly recommended that developers never interact with the KV bucket contents directly, and instead use the various operations available on the lattice control interface via the wash CLI, in order to ensure stability of the bucket's contents. Manually editing these values could result in corrupted data and unpredictable behavior by hosts.

To query the contents of the KV bucket, use the wash CLI tool to interact with the control interface. For example, to get the list of all link definitions in the lattice, use wash get links. A full list of available commands is available in the wash documentation.