Browse Source

feat(insights): render full span description in cache samples (#71255)

We're thinking we should just render the entire span description instead
of the key. Reason being
1. In most cases, the span description is the key anyways
2. In manually instrumented cases, you might set your span description
to something that has more meaning, like `User auth cache`, which in
this case it would be a lot more interesting to know the auth cache is
missing vs the key itself!
Dominik Buszowiecki 9 months ago
parent
commit
6384ff2389
1 changed files with 5 additions and 4 deletions
  1. 5 4
      static/app/views/performance/cache/tables/spanSamplesTable.tsx

+ 5 - 4
static/app/views/performance/cache/tables/spanSamplesTable.tsx

@@ -49,12 +49,12 @@ const COLUMN_ORDER: Column[] = [
   },
   {
     key: SpanIndexedField.SPAN_DESCRIPTION,
-    name: t('Key'),
+    name: t('Span Description'),
     width: COL_WIDTH_UNDEFINED,
   },
   {
     key: 'transaction.duration',
-    name: t('Txn Duration'),
+    name: t('Transaction Duration'),
     width: COL_WIDTH_UNDEFINED,
   },
   {
@@ -137,8 +137,9 @@ function renderBodyCell(
   }
 
   if (column.key === SpanIndexedField.SPAN_DESCRIPTION) {
-    const cacheKey = row[column.key].split(' ')[1]; // TODO - test with multiple keys
-    return <SpanDescriptionCell>{cacheKey}</SpanDescriptionCell>;
+    return (
+      <SpanDescriptionCell>{row[SpanIndexedField.SPAN_DESCRIPTION]}</SpanDescriptionCell>
+    );
   }
 
   if (column.key === SpanIndexedField.CACHE_HIT) {