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

feat: add sumo logic datastore #3428

Merged
merged 12 commits into from
Dec 8, 2023
Merged

feat: add sumo logic datastore #3428

merged 12 commits into from
Dec 8, 2023

Conversation

mathnogueira
Copy link
Contributor

@mathnogueira mathnogueira commented Dec 6, 2023

This PR adds the implementation for the new Sumo Logic datastore. Related to issue #3423

Checklist

  • tested locally
  • added new dependencies
  • updated the docs
  • added a test

Loom video

https://www.loom.com/share/c1a5b5bb40fb4100bde6ed48dce0e9f5

Settings page

Screenshot 2023-12-08 at 09 22 53

@mathnogueira mathnogueira marked this pull request as ready for review December 7, 2023 19:19
Copy link
Contributor

@xoscar xoscar left a comment

Choose a reason for hiding this comment

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

Hey @mathnogueira I added two comments, let me know what you think

@@ -145,6 +145,16 @@ func (w *tracePollerEvaluatorWorker) ProcessItem(ctx context.Context, job execut
return
}

if augmenter, ok := traceDB.(tracedb.TraceAugmenter); ok {
Copy link
Contributor

Choose a reason for hiding this comment

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

what is this about? was this needed for sumologic?

Copy link
Contributor

Choose a reason for hiding this comment

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

Sumo Logic Trace API returns trace spans without attributes. I believe that this method is used to augment the trace and fetch another API that returns the span attributes.

Copy link
Contributor

Choose a reason for hiding this comment

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

Is there a reason why this needs to happen in a different step? i.e not in the same step as the trace poller?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I just added a detailed comment on why this should be here and not in the other step.

}

// GetTraceByID implements TraceDB.
func (db *sumologicDB) GetTraceByID(ctx context.Context, traceID string) (traces.Trace, error) {
Copy link
Contributor

Choose a reason for hiding this comment

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

I don't see a test connection function, maybe I'm missing something?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Forgot about it. Just added it

@@ -0,0 +1,296 @@
package tracedb
Copy link
Contributor

Choose a reason for hiding this comment

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

Question: don't we need an implementation like this for the Agent? We need to implement something on https://github.com/kubeshop/tracetest/tree/main/agent/workers/datastores, no?

Copy link
Contributor

Choose a reason for hiding this comment

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

Also, it would be good to have a unit test for SumoLogic on the RM's Provisioner, here: https://github.com/kubeshop/tracetest/blob/main/server/provisioning/provisioning_test.go#L350

Copy link
Contributor

@xoscar xoscar left a comment

Choose a reason for hiding this comment

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

The FE code looks good to me! we just missing the icon right?

@jorgeepc
Copy link
Contributor

jorgeepc commented Dec 8, 2023

The FE code looks good to me! we just missing the icon right?

@xoscar icon added

@mathnogueira mathnogueira merged commit 6d3d91f into main Dec 8, 2023
38 checks passed
@mathnogueira mathnogueira deleted the feat/sumo-logic branch December 8, 2023 17:32
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.

4 participants