Browse Source

chore(stats): remove metrics (#65220)

Ogi 1 year ago
parent
commit
639faec194

+ 0 - 8
static/app/constants/index.tsx

@@ -312,14 +312,6 @@ export const DATA_CATEGORY_INFO = {
     titleName: t('Cron Monitors'),
     uid: 13,
   },
-  [DataCategoryExact.METRICS]: {
-    name: DataCategoryExact.METRICS,
-    apiName: 'metric_bucket',
-    plural: 'metric_buckets',
-    displayName: 'metrics',
-    titleName: t('Metrics'),
-    uid: 15,
-  },
 } as const satisfies Record<DataCategoryExact, DataCategoryInfo>;
 
 // Special Search characters

+ 0 - 1
static/app/types/core.tsx

@@ -97,7 +97,6 @@ export enum DataCategoryExact {
   TRANSACTION_INDEXED = 'transaction_indexed',
   MONITOR = 'monitor',
   MONITOR_SEAT = 'monitorSeat',
-  METRICS = 'metric_bucket',
 }
 
 export interface DataCategoryInfo {

+ 0 - 7
static/app/views/organizationStats/index.tsx

@@ -35,7 +35,6 @@ import type {
   PageFilters,
   Project,
 } from 'sentry/types';
-import {hasDDMFeature} from 'sentry/utils/metrics/features';
 import withOrganization from 'sentry/utils/withOrganization';
 import withPageFilters from 'sentry/utils/withPageFilters';
 import HeaderTabs from 'sentry/views/organizationStats/header';
@@ -263,9 +262,6 @@ export class OrganizationStats extends Component<OrganizationStatsProps> {
       if (opt.value === DATA_CATEGORY_INFO.replay.plural) {
         return organization.features.includes('session-replay');
       }
-      if (opt.value === DATA_CATEGORY_INFO.metric_bucket.plural) {
-        return hasDDMFeature(organization);
-      }
       return true;
     });
 
@@ -321,9 +317,6 @@ export class OrganizationStats extends Component<OrganizationStatsProps> {
       if (opt.value === DATA_CATEGORY_INFO.replay.plural) {
         return organization.features.includes('session-replay');
       }
-      if (opt.value === DATA_CATEGORY_INFO.metric_bucket.plural) {
-        return hasDDMFeature(organization);
-      }
       return true;
     });
 

+ 0 - 6
static/app/views/organizationStats/usageChart/index.tsx

@@ -89,12 +89,6 @@ export const CHART_OPTIONS_DATACATEGORY: CategoryOption[] = [
     disabled: false,
     yAxisMinInterval: 100,
   },
-  {
-    label: DATA_CATEGORY_INFO.metric_bucket.titleName,
-    value: DATA_CATEGORY_INFO.metric_bucket.plural,
-    disabled: false,
-    yAxisMinInterval: 100,
-  },
 ];
 
 export enum ChartDataTransform {