From 7fae1c5001fc282df3ee1895e0ed38aa27a237fa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Filip=20Tron=C3=AD=C4=8Dek?= Date: Tue, 6 Sep 2022 15:54:47 +0000 Subject: [PATCH] [code browser]: Measure all sessions vs errored sessions Co-authored-by: Anton Kosyakov --- WORKSPACE.yaml | 2 +- .../src/ide/ide-metrics-service-client.ts | 3 ++- .../cmd/testdata/render/aws-setup/output.golden | 16 +++++++++++++++- .../testdata/render/azure-setup/output.golden | 16 +++++++++++++++- .../testdata/render/customization/output.golden | 16 +++++++++++++++- .../render/external-registry/output.golden | 16 +++++++++++++++- .../cmd/testdata/render/gcp-setup/output.golden | 16 +++++++++++++++- .../cmd/testdata/render/minimal/output.golden | 16 +++++++++++++++- .../statefulset-customization/output.golden | 16 +++++++++++++++- .../use-pod-security-policies/output.golden | 16 +++++++++++++++- .../workspace-requests-limits/output.golden | 16 +++++++++++++++- .../pkg/components/ide-metrics/configmap.go | 10 ++++++++++ 12 files changed, 148 insertions(+), 11 deletions(-) diff --git a/WORKSPACE.yaml b/WORKSPACE.yaml index 25a43ac8c47f88..d13a6b26d3b7d7 100644 --- a/WORKSPACE.yaml +++ b/WORKSPACE.yaml @@ -7,7 +7,7 @@ defaultArgs: jbMarketplacePublishTrigger: "false" publishToJBMarketplace: true localAppVersion: unknown - codeCommit: 06783e74552ddefd74c7e02cdcce19054b294469 + codeCommit: 1f461720ba4ff9d860c6cd6650371fa9586d4770 codeQuality: stable intellijDownloadUrl: "https://download.jetbrains.com/idea/ideaIU-2022.2.1.tar.gz" golandDownloadUrl: "https://download.jetbrains.com/go/goland-2022.2.2.tar.gz" diff --git a/components/supervisor/frontend/src/ide/ide-metrics-service-client.ts b/components/supervisor/frontend/src/ide/ide-metrics-service-client.ts index 67d9b6206b0b09..d2b0215d734164 100644 --- a/components/supervisor/frontend/src/ide/ide-metrics-service-client.ts +++ b/components/supervisor/frontend/src/ide/ide-metrics-service-client.ts @@ -8,7 +8,8 @@ import { serverUrl } from '../shared/urls'; export enum MetricsName { SupervisorFrontendClientTotal = "gitpod_supervisor_frontend_client_total", - SupervisorFrontendErrorTotal = "gitpod_supervisor_frontend_error_total" + SupervisorFrontendErrorTotal = "gitpod_supervisor_frontend_error_total", + SupervisorFrontendLoadTotal = "gitpod_vscode_web_load_total", } const MetricsUrl = serverUrl.asIDEMetrics().toString(); diff --git a/install/installer/cmd/testdata/render/aws-setup/output.golden b/install/installer/cmd/testdata/render/aws-setup/output.golden index edfa5a20cd8090..b5e07c84685092 100644 --- a/install/installer/cmd/testdata/render/aws-setup/output.golden +++ b/install/installer/cmd/testdata/render/aws-setup/output.golden @@ -3165,6 +3165,20 @@ data: } ] }, + { + "name": "gitpod_vscode_web_load_total", + "help": "Total count of supervisor frontend client loading / errored windows", + "labels": [ + { + "name": "status", + "allowValues": [ + "loading", + "failed" + ], + "defaultValue": "" + } + ] + }, { "name": "gitpod_supervisor_frontend_client_total", "help": "Total count of supervisor frontend client", @@ -7431,7 +7445,7 @@ spec: template: metadata: annotations: - gitpod.io/checksum_config: 5f647d019f026f04a85e04ad8e695083db2a70f97ee7199143859879d5d40ebe + gitpod.io/checksum_config: 99857889bb5dd2fe08efbb38fa510956566ce067cf2d1e1e945bd024cf4c6bb3 creationTimestamp: null labels: app: gitpod diff --git a/install/installer/cmd/testdata/render/azure-setup/output.golden b/install/installer/cmd/testdata/render/azure-setup/output.golden index 65963797335b52..8c289be0a5645b 100644 --- a/install/installer/cmd/testdata/render/azure-setup/output.golden +++ b/install/installer/cmd/testdata/render/azure-setup/output.golden @@ -3083,6 +3083,20 @@ data: } ] }, + { + "name": "gitpod_vscode_web_load_total", + "help": "Total count of supervisor frontend client loading / errored windows", + "labels": [ + { + "name": "status", + "allowValues": [ + "loading", + "failed" + ], + "defaultValue": "" + } + ] + }, { "name": "gitpod_supervisor_frontend_client_total", "help": "Total count of supervisor frontend client", @@ -7265,7 +7279,7 @@ spec: template: metadata: annotations: - gitpod.io/checksum_config: 5f647d019f026f04a85e04ad8e695083db2a70f97ee7199143859879d5d40ebe + gitpod.io/checksum_config: 99857889bb5dd2fe08efbb38fa510956566ce067cf2d1e1e945bd024cf4c6bb3 creationTimestamp: null labels: app: gitpod diff --git a/install/installer/cmd/testdata/render/customization/output.golden b/install/installer/cmd/testdata/render/customization/output.golden index fd910c930354ff..d2709851204abd 100644 --- a/install/installer/cmd/testdata/render/customization/output.golden +++ b/install/installer/cmd/testdata/render/customization/output.golden @@ -3865,6 +3865,20 @@ data: } ] }, + { + "name": "gitpod_vscode_web_load_total", + "help": "Total count of supervisor frontend client loading / errored windows", + "labels": [ + { + "name": "status", + "allowValues": [ + "loading", + "failed" + ], + "defaultValue": "" + } + ] + }, { "name": "gitpod_supervisor_frontend_client_total", "help": "Total count of supervisor frontend client", @@ -8658,7 +8672,7 @@ spec: metadata: annotations: gitpod.io: hello - gitpod.io/checksum_config: 8beda82ff6c689641e3e3d74cfa333942daf49ba5617133a5c6ec21a44408f22 + gitpod.io/checksum_config: 8aa9b1bcf89417e5ff2353d33891b50ff53411c4255430c3ed4329d7c707739f hello: world creationTimestamp: null labels: diff --git a/install/installer/cmd/testdata/render/external-registry/output.golden b/install/installer/cmd/testdata/render/external-registry/output.golden index df4cf53e855889..b74cd94c9a5d0a 100644 --- a/install/installer/cmd/testdata/render/external-registry/output.golden +++ b/install/installer/cmd/testdata/render/external-registry/output.golden @@ -3224,6 +3224,20 @@ data: } ] }, + { + "name": "gitpod_vscode_web_load_total", + "help": "Total count of supervisor frontend client loading / errored windows", + "labels": [ + { + "name": "status", + "allowValues": [ + "loading", + "failed" + ], + "defaultValue": "" + } + ] + }, { "name": "gitpod_supervisor_frontend_client_total", "help": "Total count of supervisor frontend client", @@ -7706,7 +7720,7 @@ spec: template: metadata: annotations: - gitpod.io/checksum_config: 5f647d019f026f04a85e04ad8e695083db2a70f97ee7199143859879d5d40ebe + gitpod.io/checksum_config: 99857889bb5dd2fe08efbb38fa510956566ce067cf2d1e1e945bd024cf4c6bb3 creationTimestamp: null labels: app: gitpod diff --git a/install/installer/cmd/testdata/render/gcp-setup/output.golden b/install/installer/cmd/testdata/render/gcp-setup/output.golden index cda875b3c82c88..39dac206451fab 100644 --- a/install/installer/cmd/testdata/render/gcp-setup/output.golden +++ b/install/installer/cmd/testdata/render/gcp-setup/output.golden @@ -3054,6 +3054,20 @@ data: } ] }, + { + "name": "gitpod_vscode_web_load_total", + "help": "Total count of supervisor frontend client loading / errored windows", + "labels": [ + { + "name": "status", + "allowValues": [ + "loading", + "failed" + ], + "defaultValue": "" + } + ] + }, { "name": "gitpod_supervisor_frontend_client_total", "help": "Total count of supervisor frontend client", @@ -7320,7 +7334,7 @@ spec: template: metadata: annotations: - gitpod.io/checksum_config: 5f647d019f026f04a85e04ad8e695083db2a70f97ee7199143859879d5d40ebe + gitpod.io/checksum_config: 99857889bb5dd2fe08efbb38fa510956566ce067cf2d1e1e945bd024cf4c6bb3 creationTimestamp: null labels: app: gitpod diff --git a/install/installer/cmd/testdata/render/minimal/output.golden b/install/installer/cmd/testdata/render/minimal/output.golden index db021d9a4de591..4031a7634b317c 100644 --- a/install/installer/cmd/testdata/render/minimal/output.golden +++ b/install/installer/cmd/testdata/render/minimal/output.golden @@ -3390,6 +3390,20 @@ data: } ] }, + { + "name": "gitpod_vscode_web_load_total", + "help": "Total count of supervisor frontend client loading / errored windows", + "labels": [ + { + "name": "status", + "allowValues": [ + "loading", + "failed" + ], + "defaultValue": "" + } + ] + }, { "name": "gitpod_supervisor_frontend_client_total", "help": "Total count of supervisor frontend client", @@ -7986,7 +8000,7 @@ spec: template: metadata: annotations: - gitpod.io/checksum_config: 5f647d019f026f04a85e04ad8e695083db2a70f97ee7199143859879d5d40ebe + gitpod.io/checksum_config: 99857889bb5dd2fe08efbb38fa510956566ce067cf2d1e1e945bd024cf4c6bb3 creationTimestamp: null labels: app: gitpod diff --git a/install/installer/cmd/testdata/render/statefulset-customization/output.golden b/install/installer/cmd/testdata/render/statefulset-customization/output.golden index f7417ee5bd624c..930d6ea2963603 100644 --- a/install/installer/cmd/testdata/render/statefulset-customization/output.golden +++ b/install/installer/cmd/testdata/render/statefulset-customization/output.golden @@ -3402,6 +3402,20 @@ data: } ] }, + { + "name": "gitpod_vscode_web_load_total", + "help": "Total count of supervisor frontend client loading / errored windows", + "labels": [ + { + "name": "status", + "allowValues": [ + "loading", + "failed" + ], + "defaultValue": "" + } + ] + }, { "name": "gitpod_supervisor_frontend_client_total", "help": "Total count of supervisor frontend client", @@ -7998,7 +8012,7 @@ spec: template: metadata: annotations: - gitpod.io/checksum_config: 5f647d019f026f04a85e04ad8e695083db2a70f97ee7199143859879d5d40ebe + gitpod.io/checksum_config: 99857889bb5dd2fe08efbb38fa510956566ce067cf2d1e1e945bd024cf4c6bb3 creationTimestamp: null labels: app: gitpod diff --git a/install/installer/cmd/testdata/render/use-pod-security-policies/output.golden b/install/installer/cmd/testdata/render/use-pod-security-policies/output.golden index 0c55f10bcd452d..ee53ef52afc1ff 100644 --- a/install/installer/cmd/testdata/render/use-pod-security-policies/output.golden +++ b/install/installer/cmd/testdata/render/use-pod-security-policies/output.golden @@ -3723,6 +3723,20 @@ data: } ] }, + { + "name": "gitpod_vscode_web_load_total", + "help": "Total count of supervisor frontend client loading / errored windows", + "labels": [ + { + "name": "status", + "allowValues": [ + "loading", + "failed" + ], + "defaultValue": "" + } + ] + }, { "name": "gitpod_supervisor_frontend_client_total", "help": "Total count of supervisor frontend client", @@ -8430,7 +8444,7 @@ spec: template: metadata: annotations: - gitpod.io/checksum_config: 5f647d019f026f04a85e04ad8e695083db2a70f97ee7199143859879d5d40ebe + gitpod.io/checksum_config: 99857889bb5dd2fe08efbb38fa510956566ce067cf2d1e1e945bd024cf4c6bb3 creationTimestamp: null labels: app: gitpod diff --git a/install/installer/cmd/testdata/render/workspace-requests-limits/output.golden b/install/installer/cmd/testdata/render/workspace-requests-limits/output.golden index d9f3b10cc9083c..224dc5e4071218 100644 --- a/install/installer/cmd/testdata/render/workspace-requests-limits/output.golden +++ b/install/installer/cmd/testdata/render/workspace-requests-limits/output.golden @@ -3393,6 +3393,20 @@ data: } ] }, + { + "name": "gitpod_vscode_web_load_total", + "help": "Total count of supervisor frontend client loading / errored windows", + "labels": [ + { + "name": "status", + "allowValues": [ + "loading", + "failed" + ], + "defaultValue": "" + } + ] + }, { "name": "gitpod_supervisor_frontend_client_total", "help": "Total count of supervisor frontend client", @@ -7989,7 +8003,7 @@ spec: template: metadata: annotations: - gitpod.io/checksum_config: 5f647d019f026f04a85e04ad8e695083db2a70f97ee7199143859879d5d40ebe + gitpod.io/checksum_config: 99857889bb5dd2fe08efbb38fa510956566ce067cf2d1e1e945bd024cf4c6bb3 creationTimestamp: null labels: app: gitpod diff --git a/install/installer/pkg/components/ide-metrics/configmap.go b/install/installer/pkg/components/ide-metrics/configmap.go index 6db5908983d328..cd3e13c2068db5 100644 --- a/install/installer/pkg/components/ide-metrics/configmap.go +++ b/install/installer/pkg/components/ide-metrics/configmap.go @@ -46,6 +46,16 @@ func configmap(ctx *common.RenderContext) ([]runtime.Object, error) { }, }, }, + { + Name: "gitpod_vscode_web_load_total", + Help: "Total count of supervisor frontend client loading / errored windows", + Labels: []config.LabelAllowList{ + { + Name: "status", + AllowValues: []string{"loading", "failed"}, + }, + }, + }, { Name: "gitpod_supervisor_frontend_client_total", Help: "Total count of supervisor frontend client",