resolveSpanModule.tsx 373 B

1234567891011
  1. const OP_MAPPING = {
  2. 'db.redis': 'cache',
  3. 'db.sql.room': 'other',
  4. };
  5. /**
  6. * This is a frontend copy of `resolve_span_module` in Discover. `span.category` is a synthetic tag, computed from a combination of the span op and the span category.
  7. */
  8. export function resolveSpanModule(op?: string, category?: string) {
  9. return OP_MAPPING[op ?? ''] ?? category ?? 'other';
  10. }