Skip to content
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

sentry integration #1118

Open
Tracked by #1565
ashraffouda opened this issue Jul 7, 2024 · 3 comments
Open
Tracked by #1565

sentry integration #1118

ashraffouda opened this issue Jul 7, 2024 · 3 comments
Assignees
Labels
type_feature New feature or request
Milestone

Comments

@ashraffouda
Copy link
Collaborator

Is your feature request related to a problem? Please describe

we need to track and monitor errors happends in sdk during deploymnets

Describe the solution you'd like

we will track errors on sentry more info is here
threefoldtech/home#1554

@ashraffouda ashraffouda added the type_feature New feature or request label Jul 7, 2024
@ashraffouda ashraffouda added this to the 1.0.0 milestone Jul 7, 2024
@ashraffouda ashraffouda moved this to In Progress in 3.15.x Jul 9, 2024
@AbdelrahmanElawady
Copy link
Collaborator

So, after trying it out and discussing how we should integrate it with our tools, there are some points we need to consider:

  • Sentry has a lot of integration with various frameworks in Go to enrich the context sent with events. However, we are not using any of them :) For example web frameworks include: gin, echo, net/http but not mux. Also, for loggers it supports logrus and we are using zerolog. It might be worth it to switch to one of the supported frameworks.
  • Since we will be sending some deployment data, we need to implement a proper redaction of deployment data to make sure no sensitive data is sent.
  • Instead of having to implement the same error capturing in all of our tools we could do it in the go-client itself so that it can be configured to capture and send data and all tools built on go-client can just add its specific context. For example: tfrobot can add some details about number of groups or number of vms.
  • We need to configure all of our tools to give the user the option whether to opt in with the error collection or not. I think for development/testing environment it should be on by default while production should have it turned off.

So, in summary:

  • Redact sensitive workload data in client.
  • Add an option to tfPluginClient to use an instance of Sentry client.
  • Based on whether the option is used report in different client operation (deploy, cancel, list, etc...)
  • Tools based on client would just need to add their context and just pass an instance to the plugin client where it will report the rest.
  • Tools not using the client (farmerbot, grid-proxy) needs to have a bit of a manual configuration since they are using mux and zerolog (which aren't supported).

@xmonader xmonader modified the milestones: 1.0.0, v0.16.0 Aug 26, 2024
@ashraffouda ashraffouda removed this from 3.15.x Oct 1, 2024
@ashraffouda ashraffouda removed this from the v0.16.x milestone Oct 1, 2024
@ramezsaeed ramezsaeed added this to the v0.17.x milestone Oct 2, 2024
@rawdaGastan
Copy link
Collaborator

@rawdaGastan
Copy link
Collaborator

working now

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type_feature New feature or request
Projects
None yet
Development

No branches or pull requests

5 participants