ex-aws / ex_aws

A flexible, easy to use set of clients AWS APIs for Elixir
https://hex.pm/packages/ex_aws
MIT License
1.28k stars 526 forks source link

Please include the "x-amz-target" header value in telemetry events #930

Closed juancgalvis closed 1 year ago

juancgalvis commented 1 year ago

Environment

Current behavior

The current events have only the AWS service name in metadata.

%{
  attempt: 1,
  options: [],
  result: :ok,
  service: :secretsmanager,
  telemetry_span_context: #Reference<0.3450093779.1724645383.45512>
}

Expected behavior

Would be great to include the operation that is being executed. For example:

%{
  attempt: 1,
  options: [],
  result: :ok,
  service: :secretsmanager,
  operation: "secretsmanager.GetSecretValue"
  telemetry_span_context: #Reference<0.3450093779.1724645383.45512>
}

I will be able to contribute if you appreciate this functionality.

bernardd commented 1 year ago

Ha - I've got to be honest, I only just now learned that ex_aws even emits telemetry events :) Yes, I'm quite happy to have extra information like the operation added to them - please feel free to submit a PR!