mastra-ai/mastra · error · MastraError

OBSERVABILITY_STORAGE_GET_FEEDBACK_BREAKDOWN_NOT_IMPLEMENTED

OBSERVABILITY_STORAGE_GET_FEEDBACK_BREAKDOWN_NOT_IMPLEMENTED

Error message

This storage provider does not support feedback breakdown

What it means

Thrown by the base MastraObservabilityStorage class when a storage adapter does not override getFeedbackBreakdown(). Feedback breakdown aggregation (grouping feedback counts/values by attribute) is an optional capability; the abstract base marks it unimplemented by default. Hitting this means the active storage provider was never extended to implement feedback analytics.

Source

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

    throw new MastraError({
      id: 'OBSERVABILITY_STORAGE_LIST_FEEDBACK_NOT_IMPLEMENTED',
      domain: ErrorDomain.MASTRA_OBSERVABILITY,
      category: ErrorCategory.SYSTEM,
      text: 'This storage provider does not support listing feedback',
    });
  }

  async getFeedbackAggregate(_args: GetFeedbackAggregateArgs): Promise<GetFeedbackAggregateResponse> {
    throw new MastraError({
      id: 'OBSERVABILITY_STORAGE_GET_FEEDBACK_AGGREGATE_NOT_IMPLEMENTED',
      domain: ErrorDomain.MASTRA_OBSERVABILITY,
      category: ErrorCategory.SYSTEM,
      text: 'This storage provider does not support feedback aggregation',
    });
  }

  async getFeedbackBreakdown(_args: GetFeedbackBreakdownArgs): Promise<GetFeedbackBreakdownResponse> {
    throw new MastraError({
      id: 'OBSERVABILITY_STORAGE_GET_FEEDBACK_BREAKDOWN_NOT_IMPLEMENTED',
      domain: ErrorDomain.MASTRA_OBSERVABILITY,
      category: ErrorCategory.SYSTEM,
      text: 'This storage provider does not support feedback breakdown',
    });
  }

  async getFeedbackTimeSeries(_args: GetFeedbackTimeSeriesArgs): Promise<GetFeedbackTimeSeriesResponse> {
    throw new MastraError({
      id: 'OBSERVABILITY_STORAGE_GET_FEEDBACK_TIME_SERIES_NOT_IMPLEMENTED',
      domain: ErrorDomain.MASTRA_OBSERVABILITY,
      category: ErrorCategory.SYSTEM,
      text: 'This storage provider does not support feedback time series',
    });
  }

  async getFeedbackPercentiles(_args: GetFeedbackPercentilesArgs): Promise<GetFeedbackPercentilesResponse> {
    throw new MastraError({

View on GitHub (pinned to 75dd419e61)

Solutions

  1. Switch to a storage provider that implements getFeedbackBreakdown (e.g. one of the first-party DB adapters) and register it as your observability storage.
  2. If you own the adapter, override getFeedbackBreakdown(args) and return a GetFeedbackBreakdownResponse computed from your feedback records.
  3. Guard the call with a capability check or feature flag so the UI/API degrades gracefully when feedback analytics are unavailable.
  4. Check for a Mastra version mismatch where the caller expects an adapter feature the installed adapter version lacks; upgrade the adapter package.

Example fix

// before
const storage = new MyMinimalStorage();
const breakdown = await storage.getFeedbackBreakdown({ ... }); // throws

// after
const storage = new PostgresStore({ connectionString }); // implements feedback methods
const breakdown = await storage.getFeedbackBreakdown({ ... });
Defensive patterns

Strategy: fallback

Validate before calling

if (typeof (storage as any).getFeedbackBreakdown !== 'function' || storage.constructor === MastraObservabilityStorage) { /* unsupported */ }

Type guard

function supportsFeedbackBreakdown(s: unknown): s is MastraObservabilityStorage & { getFeedbackBreakdown(a: GetFeedbackBreakdownArgs): Promise<GetFeedbackBreakdownResponse> } {
  return typeof (s as any)?.getFeedbackBreakdown === 'function' && !isBaseDefaultImpl(s, 'getFeedbackBreakdown');
}

Try / catch

try {
  breakdown = await storage.getFeedbackBreakdown(args);
} catch (e) {
  if ((e as MastraError).id === 'OBSERVABILITY_STORAGE_GET_FEEDBACK_BREAKDOWN_NOT_IMPLEMENTED') {
    breakdown = emptyBreakdownFallback;
  } else throw e;
}

Prevention

When it happens

Trigger: Calling observabilityStorage.getFeedbackBreakdown(args) on a provider that inherits the base class default (custom or minimal adapter, or a provider without feedback aggregation support).

Common situations: Using a custom/community storage adapter that implements only core trace persistence; upgrading Mastra and calling a new feedback-analytics API against a provider that has not added support; wiring the default base class directly instead of a concrete adapter like Postgres/Upstash that implements the method.

Related errors


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