Browse Source

feat: add Go to the profiling wizard (#51050)

Related to https://github.com/getsentry/sentry-docs/pull/7127 - adds Go
Profiling wizard
Ivan Dlugos 1 year ago
parent
commit
bd4d63ca00

+ 1 - 0
static/app/components/profiling/ProfilingOnboarding/util.ts

@@ -28,6 +28,7 @@ export const supportedPlatformExpectedDocKeys: Record<
     '3-configure-profiling',
     '3-configure-profiling',
     '4-upload',
     '4-upload',
   ],
   ],
+  go: ['0-alert', '1-install', '2-configure-performance', '3-configure-profiling'],
   node: ['1-install', '2-configure-performance', '3-configure-profiling'],
   node: ['1-install', '2-configure-performance', '3-configure-profiling'],
   python: ['1-install', '2-configure-performance', '3-configure-profiling'],
   python: ['1-install', '2-configure-performance', '3-configure-profiling'],
   php: ['1-install', '2-configure-performance', '3-configure-profiling'],
   php: ['1-install', '2-configure-performance', '3-configure-profiling'],

+ 2 - 0
static/app/data/platformCategories.tsx

@@ -220,6 +220,8 @@ export const profiling: PlatformKey[] = [
   // mobile
   // mobile
   'android',
   'android',
   'apple-ios',
   'apple-ios',
+  // go
+  'go',
   // nodejs
   // nodejs
   'node',
   'node',
   'node-express',
   'node-express',

+ 7 - 0
static/app/utils/profiling/platforms.tsx

@@ -5,6 +5,7 @@ export const supportedProfilingPlatforms = profiling;
 export const supportedProfilingPlatformSDKs = [
 export const supportedProfilingPlatformSDKs = [
   'android',
   'android',
   'apple-ios',
   'apple-ios',
+  'go',
   'node',
   'node',
   'python',
   'python',
   'php',
   'php',
@@ -36,6 +37,12 @@ export function getDocsPlatformSDKForPlatform(
   if (platform === 'apple-ios') {
   if (platform === 'apple-ios') {
     return 'apple-ios';
     return 'apple-ios';
   }
   }
+
+  // Go
+  if (platform === 'go') {
+    return 'go';
+  }
+
   // Javascript
   // Javascript
   if (platform.startsWith('node')) {
   if (platform.startsWith('node')) {
     return 'node';
     return 'node';