Skip to main content

Metadata

Extensible Attributes

Metadata in MatsuDB provides an extensible key-value storage system that enables nodes to carry additional information beyond their core attributes.

Definition

Metadata in MatsuDB provides an extensible key-value storage system that enables nodes to carry additional information beyond their core attributes. Each node can have multiple metadata entries, each consisting of a key and a value, enabling flexible extension of node information without schema modifications.

The metadata system operates as a simple key-value store where keys are strings and values are text. This simplicity enables organizations to add custom information to nodes as needed, supporting evolving requirements without requiring system changes.

No Schema Changes Required

Unlike core node attributes, metadata can be added, modified, or removed without requiring schema changes or system updates. This makes metadata ideal for custom attributes that evolve with organizational needs.

Structure and Operations

Each metadata entry consists of a key that identifies the metadata type and a value that contains the metadata content. Metadata entries are uniquely identified by the combination of node identifier and key, ensuring that each node has at most one value for each key. When metadata is updated, the existing entry is replaced.

The metadata API provides operations for adding, retrieving, and deleting metadata. Metadata can be added individually or in bulk, enabling efficient metadata management. Metadata is returned as key-value maps, providing convenient access patterns for applications.

Use Cases

Metadata serves diverse organizational needs:

  • Project management: Assign nodes to projects and track progress
  • Quality assurance: Record quality ratings and flag content for review
  • Custom classification: Add domain-specific tags and categories
  • Processing parameters: Store configuration values used by workflows
  • User annotations: Store human-generated notes and comments

Metadata enables query-based filtering that extends beyond core node attributes. Applications can query nodes based on metadata values, enabling filtering by custom attributes that are not part of the core schema.

Searchable and Queryable

Metadata is searchable and queryable, enabling applications to filter and find nodes based on custom attributes without requiring schema modifications.

Relationship to Other Concepts

Metadata is stored within nodes, making extended attributes a native node capability. Metadata operates within namespace boundaries, ensuring that extended attributes remain isolated per organization. Metadata can be queried alongside core node attributes, enabling comprehensive filtering that combines core and extended information.

Integration

Metadata integrates seamlessly with other MatsuDB concepts:

  • Stored within nodes as extended attributes
  • Namespace-scoped for multi-tenant isolation
  • Queryable alongside core node attributes
  • Can be used by workflows for processing decisions