Просмотр исходного кода

ref(starfish) Remove existing span summary page and panel (#49954)

All the functionality has been moved over to a new dedicated span
summary page and sample list panel.

- Move out generic code
- Delete SpanSummaryPanel
- Swap in new span summary page
- Extract reusable util
- Move out queries
- Remove old span summary page
- Lift up span summary page
George Gritsouk 1 год назад
Родитель
Сommit
3bdb22eb59

+ 1 - 7
static/app/routes.tsx

@@ -1725,13 +1725,7 @@ function buildRoutes() {
       />
       <Route
         path="span/:groupId/"
-        component={make(() => import('sentry/views/starfish/views/spanSummary'))}
-      />
-      <Route
-        path="span-summary/:groupId/"
-        component={make(
-          () => import('sentry/views/starfish/views/spans/spanSummaryPage')
-        )}
+        component={make(() => import('sentry/views/starfish/views/spanSummaryPage'))}
       />
     </Fragment>
   );

+ 0 - 0
static/app/views/starfish/views/spans/spanSummaryPanel/releasePreview.tsx → static/app/views/starfish/components/releasePreview.tsx


+ 4 - 2
static/app/views/starfish/components/samplesTable/spanSamplesTable.tsx

@@ -5,8 +5,10 @@ import GridEditable, {GridColumnHeader} from 'sentry/components/gridEditable';
 import {useLocation} from 'sentry/utils/useLocation';
 import {SpanDurationBar} from 'sentry/views/performance/transactionSummary/transactionSpans/spanDetails/spanDetailsTable';
 import {DurationComparisonCell} from 'sentry/views/starfish/components/samplesTable/common';
-import {TextAlignRight} from 'sentry/views/starfish/components/textAlign';
-import {OverflowEllipsisTextContainer} from 'sentry/views/starfish/views/spanSummary';
+import {
+  OverflowEllipsisTextContainer,
+  TextAlignRight,
+} from 'sentry/views/starfish/components/textAlign';
 
 type Keys = 'transaction_id' | 'timestamp' | 'duration' | 'p50_comparison';
 type TableColumnHeader = GridColumnHeader<Keys>;

+ 1 - 1
static/app/views/starfish/views/spans/spanSummaryPanel/spanDescription.tsx → static/app/views/starfish/components/spanDescription.tsx

@@ -1,8 +1,8 @@
 import styled from '@emotion/styled';
 
 import {FormattedCode} from 'sentry/views/starfish/components/formattedCode';
+import type {Span} from 'sentry/views/starfish/queries/types';
 import {highlightSql} from 'sentry/views/starfish/utils/highlightSql';
-import type {Span} from 'sentry/views/starfish/views/spans/spanSummaryPanel/types';
 
 export function SpanDescription({span}: {span: Span}) {
   if (span.span_operation.startsWith('db')) {

+ 0 - 0
static/app/views/starfish/views/spans/spanSummaryPanel/types.tsx → static/app/views/starfish/queries/types.tsx


+ 0 - 0
static/app/views/starfish/views/spans/spanSummaryPanel/useApplicationMetrics.tsx → static/app/views/starfish/queries/useApplicationMetrics.tsx


+ 1 - 1
static/app/views/starfish/views/spans/spanSummaryPanel/useSpanById.ts → static/app/views/starfish/queries/useSpanById.ts

@@ -1,6 +1,6 @@
 import {useQuery} from 'sentry/utils/queryClient';
+import type {Span} from 'sentry/views/starfish/queries/types';
 import {HOST} from 'sentry/views/starfish/utils/constants';
-import type {Span} from 'sentry/views/starfish/views/spans/spanSummaryPanel/types';
 
 export const useSpanById = (groupId: string, referrer: string) => {
   const query = `

+ 1 - 1
static/app/views/starfish/views/spans/spanSummaryPanel/useSpanMetricSeries.tsx → static/app/views/starfish/queries/useSpanMetricSeries.tsx

@@ -4,11 +4,11 @@ import moment from 'moment';
 import {Series} from 'sentry/types/echarts';
 import {useQuery} from 'sentry/utils/queryClient';
 import usePageFilters from 'sentry/utils/usePageFilters';
+import type {Span} from 'sentry/views/starfish/queries/types';
 import {HOST} from 'sentry/views/starfish/utils/constants';
 import {getDateFilters} from 'sentry/views/starfish/utils/dates';
 import {getDateQueryFilter} from 'sentry/views/starfish/utils/getDateQueryFilter';
 import {zeroFillSeries} from 'sentry/views/starfish/utils/zeroFillSeries';
-import type {Span} from 'sentry/views/starfish/views/spans/spanSummaryPanel/types';
 
 const INTERVAL = 12;
 

+ 1 - 1
static/app/views/starfish/views/spans/spanSummaryPanel/useSpanMetrics.tsx → static/app/views/starfish/queries/useSpanMetrics.tsx

@@ -1,9 +1,9 @@
 import {useQuery} from 'sentry/utils/queryClient';
 import usePageFilters from 'sentry/utils/usePageFilters';
+import type {Span} from 'sentry/views/starfish/queries/types';
 import {HOST} from 'sentry/views/starfish/utils/constants';
 import {getDateFilters} from 'sentry/views/starfish/utils/dates';
 import {getDateQueryFilter} from 'sentry/views/starfish/utils/getDateQueryFilter';
-import type {Span} from 'sentry/views/starfish/views/spans/spanSummaryPanel/types';
 
 const INTERVAL = 12;
 

+ 1 - 1
static/app/views/starfish/views/spans/spanSummaryPanel/useSpanSeenEvent.tsx → static/app/views/starfish/queries/useSpanSeenEvent.tsx

@@ -1,7 +1,7 @@
 import {useQuery} from 'sentry/utils/queryClient';
 import {useQueryGetEvent} from 'sentry/views/starfish/modules/databaseModule/queries';
+import type {Span} from 'sentry/views/starfish/queries/types';
 import {HOST} from 'sentry/views/starfish/utils/constants';
-import type {Span} from 'sentry/views/starfish/views/spans/spanSummaryPanel/types';
 
 type HasTransaction = {
   transaction_id: string;

Некоторые файлы не были показаны из-за большого количества измененных файлов