cli icon indicating copy to clipboard operation
cli copied to clipboard

[CLI] Add 'source' metadata for metrics collected

Open peter-rr opened this issue 1 year ago • 0 comments
trafficstars

Why do we need this improvement?

We need to include source metadata as a unique identifier for every file handled in CLI when collecting metrics for the commands executed.

How will this change help?

This change will allow us to measure the Time to first API Design metric as described here.

How could it be implemented/designed?

We need to consider two different issues we've found so far:

  • The hashing algorithm to use: We should make a decision based on computational cost and security aspects according to New Relic requirements and also the recommendations from SonarCloud. Some research about algorithms like md5, sha1 or sha256 is needed.
  • Find another way to calculate the Time to first API Design metric, or a different way to identify the source so it doesn't change between file creation and generation. See https://github.com/asyncapi/cli/pull/859#discussion_r1520842866

Related issue(s)

Relates to https://github.com/asyncapi/cli/issues/1161

peter-rr avatar Mar 12 '24 12:03 peter-rr