Skip to content

[ide-metrics] remove gcp logging report api #12841

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Sep 10, 2022
Merged

Conversation

iQQBot
Copy link
Contributor

@iQQBot iQQBot commented Sep 9, 2022

Description

We decide to remove using API to upload logs to GCP logging, now we only write logs to stdout with GCP error reporting format, so that GKE can automatically collect logs, and report to GCP.

Related Issue(s)

Fixes #

How to test

  1. run below curl command
## cURL
curl -X "POST" "https://ide.pd-r-ide-metrics-gcp.preview.gitpod-dev.com/metrics-api/reportError" \
     -H 'Content-Type: application/json; charset=utf-8' \
     -d $'{
  "component": "supervisor-frontend",
  "workspaceId": "workspaceId1",
  "error_stack": "Error: test-error\\n    at REPL16:1:7\\n    at Script.runInThisContext (node:vm:129:12)\\n    at REPLServer.defaultEval (node:repl:566:29)\\n    at bound (node:domain:421:15)\\n    at REPLServer.runBound [as eval] (node:domain:432:12)\\n    at REPLServer.onLine (node:repl:893:10)\\n    at REPLServer.emit (node:events:539:35)\\n    at REPLServer.emit (node:domain:475:12)\\n    at REPLServer.[_onLine] [as _onLine] (node:internal/readline/interface:418:12)\\n    at REPLServer.[_line] [as _line] (node:internal/readline/interface:879:18)",
  "instanceId": "instanceId1",
  "userId": "userId",
  "properties": {
    "p2": "v2",
    "p1": "v1"
  }
}'
  1. see pod ide-metrics logs, it should be log.
  2. go to GCP error reporting dashboard you will see this error.

Release Notes

NONE

Documentation

Werft options:

  • /werft with-preview

@iQQBot iQQBot force-pushed the pd/r-ide-metrics-gcp branch from 5dae1bf to 577d980 Compare September 9, 2022 14:30
@iQQBot iQQBot marked this pull request as ready for review September 9, 2022 15:44
@iQQBot iQQBot requested review from a team September 9, 2022 15:44
@github-actions github-actions bot added team: IDE team: delivery Issue belongs to the self-hosted team labels Sep 9, 2022
Copy link
Contributor

@mustard-mh mustard-mh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code LGTM, tested and worked well 👍

image

@roboquat roboquat merged commit 145defe into main Sep 10, 2022
@roboquat roboquat deleted the pd/r-ide-metrics-gcp branch September 10, 2022 00:26
@roboquat roboquat added the deployed: IDE IDE change is running in production label Sep 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
deployed: IDE IDE change is running in production release-note-none size/XL team: delivery Issue belongs to the self-hosted team team: IDE
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants