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

Use new error telemetry API #435

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

orishoshan
Copy link
Collaborator

Description

This PR removes the dependency on the Bugsnag SDK for error telemetry and uses a GraphQL-based API to report errors, similar to the usage telemetry API.

}

func (s *ErrorSender) SendSync(errs []*telemetriesgql.Error) error {
ctxTimeout, cancel := context.WithTimeout(context.Background(), 30*time.Second)
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
ctxTimeout, cancel := context.WithTimeout(context.Background(), 30*time.Second)
clientTimeout := viper.GetDuration(telemetriesconfig.TimeoutKey)
ctxTimeout, cancel := context.WithTimeout(context.Background(), clientTimeout)

return graphql.NewClient(apiAddress, clientWithTimeout)
}

func (s *ErrorSender) SendSync(errs []*telemetriesgql.Error) error {
Copy link
Contributor

Choose a reason for hiding this comment

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

Guess we should also check here

Suggested change
func (s *ErrorSender) SendSync(errs []*telemetriesgql.Error) error {
func (s *ErrorSender) SendSync(errs []*telemetriesgql.Error) error {
if !s.enabled {
return nil
}

@@ -7,6 +7,7 @@ import (

const (
TelemetryAPIAddressKey = "telemetry-address"
TelemetryAPIAddressDefault = "http://localhost:8081/api/telemetry/query"
Copy link
Contributor

Choose a reason for hiding this comment

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

Doesn't this make deployments without helm charts disabled by default? Should be app.otterize.com by default but to change it on init to localhost if version == "0-local" so locally build images won't trigger production

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

Successfully merging this pull request may close these issues.

None yet

2 participants