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

SQS Integration (Aws Sdk) #546

Closed
wants to merge 9 commits into from
Closed

Conversation

colin-higgins
Copy link
Member

@colin-higgins colin-higgins commented Nov 7, 2019

Changes proposed in this pull request:

  • Introduce SQS client instrumentation from the AWS SDK
  • Tests verifying sample app sends spans
  • Test framework refactors

@DataDog/apm-dotnet

@colin-higgins colin-higgins added area:automatic-instrumentation Automatic instrumentation managed C# code (Datadog.Trace.ClrProfiler.Managed) area:tests unit tests, integration tests labels Nov 7, 2019
@colin-higgins colin-higgins requested a review from a team as a code owner November 7, 2019 14:10
@colin-higgins colin-higgins self-assigned this Nov 7, 2019
@colin-higgins colin-higgins changed the title Colin/integrations/aws sqs SQS Integration (Aws Sdk) Nov 7, 2019
@colin-higgins colin-higgins added this to the 1.10.0 milestone Nov 7, 2019
@bobuva
Copy link
Contributor

bobuva commented Nov 7, 2019

@colin-higgins For the purpose of code review, it would be good to know the steps you went through to retrieve and set up the AWS SDK. One thing, for example, I'd like to do is verify that the integration points are complete, and being able to look at the AWS SDK assemblies would allow me to do that.

var serviceName = $"{tracer.DefaultServiceName}-{ServiceName}";
scope = Tracer.Instance.StartActive(OperationName, serviceName: serviceName);
var span = scope.Span;
span.Type = SpanTypes.Http; // TODO, is this right?
Copy link
Contributor

Choose a reason for hiding this comment

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

Since Amazon SQS is a queuing system, it seems that we should have a new SpanType.Queue.

Copy link
Member Author

Choose a reason for hiding this comment

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

I would agree if this code were acting as the queue, but it is only the client for the queue.

Copy link
Member Author

Choose a reason for hiding this comment

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

Copy link
Member Author

Choose a reason for hiding this comment

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

Copy link
Contributor

Choose a reason for hiding this comment

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

This seems like a consistency issue then. I would check for RFCs that apply to naming operations if such an RFC exists. And maybe asking in the apm-integrations Slack channel.

Copy link
Member Author

@colin-higgins colin-higgins Nov 7, 2019

Choose a reason for hiding this comment

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

I worked with @tylerbenson to get a better idea of what Java is doing, so we can match up with them. I'll put up a draft RFC tomorrow sometime.

Copy link
Contributor

Choose a reason for hiding this comment

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

Sounds good, thanks @colin-higgins !

@@ -146,42 +146,6 @@ protected virtual void OnRequestReceived(HttpListenerContext context)
RequestReceived?.Invoke(this, new EventArgs<HttpListenerContext>(context));
}

private static List<Span> ToSpans(dynamic data)
Copy link
Member

Choose a reason for hiding this comment

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

Should we merge the PR that this come from first so this (unrelated) diff is not here?

Copy link
Member Author

Choose a reason for hiding this comment

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

I'm fine with that.

Copy link
Member

Choose a reason for hiding this comment

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

@lucaspimentel
Copy link
Member

Closing this PR for now. We will refactor this integration to use the new "call target" instrumentation in the near future.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:automatic-instrumentation Automatic instrumentation managed C# code (Datadog.Trace.ClrProfiler.Managed) area:tests unit tests, integration tests status:on-hold type:new-feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants