mastra-ai/mastra · warning · MastraError

OBSERVABILITY_STORAGE_GET_TAGS_NOT_IMPLEMENTED

OBSERVABILITY_STORAGE_GET_TAGS_NOT_IMPLEMENTED

Error message

This storage provider does not support tag discovery

What it means

MastraError OBSERVABILITY_STORAGE_GET_TAGS_NOT_IMPLEMENTED. The base getTags method in the observability storage domain always throws, meaning tag discovery is optional and unimplemented in the configured provider. Callers should treat it as 'this backend cannot enumerate tags'.

Source

Thrown at packages/core/src/storage/domains/observability/base.ts:553

    throw new MastraError({
      id: 'OBSERVABILITY_STORAGE_GET_SERVICE_NAMES_NOT_IMPLEMENTED',
      domain: ErrorDomain.MASTRA_OBSERVABILITY,
      category: ErrorCategory.SYSTEM,
      text: 'This storage provider does not support service name discovery',
    });
  }

  async getEnvironments(_args: GetEnvironmentsArgs): Promise<GetEnvironmentsResponse> {
    throw new MastraError({
      id: 'OBSERVABILITY_STORAGE_GET_ENVIRONMENTS_NOT_IMPLEMENTED',
      domain: ErrorDomain.MASTRA_OBSERVABILITY,
      category: ErrorCategory.SYSTEM,
      text: 'This storage provider does not support environment discovery',
    });
  }

  async getTags(_args: GetTagsArgs): Promise<GetTagsResponse> {
    throw new MastraError({
      id: 'OBSERVABILITY_STORAGE_GET_TAGS_NOT_IMPLEMENTED',
      domain: ErrorDomain.MASTRA_OBSERVABILITY,
      category: ErrorCategory.SYSTEM,
      text: 'This storage provider does not support tag discovery',
    });
  }

  // ============================================================================
  // Scores
  // ============================================================================

  /**
   * Creates a single score record.
   */
  async createScore(_args: CreateScoreArgs): Promise<void> {
    throw new MastraError({
      id: 'OBSERVABILITY_STORAGE_CREATE_SCORE_NOT_IMPLEMENTED',
      domain: ErrorDomain.MASTRA_OBSERVABILITY,

View on GitHub (pinned to 75dd419e61)

Solutions

  1. Use a storage provider that implements tag discovery
  2. Override getTags in your storage class to return persisted tags
  3. Catch and degrade (empty tags, hide filter) when the backend lacks support

Example fix

// before
const tags = await storage.getTags({});
// after
let tags = [];
try {
  tags = (await storage.getTags({})).tags ?? [];
} catch (e) {
  if (e.id !== 'OBSERVABILITY_STORAGE_GET_TAGS_NOT_IMPLEMENTED') throw e;
}
Defensive patterns

Strategy: fallback

Validate before calling

async function supportsTags(storage) {
  try { await storage.getTags({}); return true; }
  catch (e) { return e?.id === 'OBSERVABILITY_STORAGE_GET_TAGS_NOT_IMPLEMENTED' ? false : true; }
}

Type guard

function isNotImplementedError(e: unknown): e is MastraError {
  return e instanceof MastraError && e.id === 'OBSERVABILITY_STORAGE_GET_TAGS_NOT_IMPLEMENTED';
}

Try / catch

try {
  const res = await storage.getTags(args);
} catch (e) {
  if (isNotImplementedError(e)) return { tags: [] };
  throw e;
}

Prevention

When it happens

Trigger: Calling getTags(args) on a storage instance that relies on the base class default.

Common situations: Tag filter UIs against minimal storage adapters; custom providers missing the newer discovery methods; swapping backends (e.g. from a full Postgres observability store to a lightweight one) without updating feature expectations.

Related errors


AI-assisted analysis of mastra-ai/mastra@75dd419e61 (2026-08-30). Data as JSON: /api/errors/13201b39c39c9beb. Report an issue: GitHub.