argoproj / gitops-engine

Democratizing GitOps
https://pkg.go.dev/github.com/argoproj/gitops-engine?tab=subdirectories
Apache License 2.0
1.7k stars 260 forks source link

feat: add user agent parameter for agent #472

Open alswl opened 2 years ago

alswl commented 2 years ago

For traffic control and log analysis, we use the UA to identify the client's identity.

This PR allows the user to set up the User Agent by adding a command line parameter, which facilitates tracking and analysis for performance evaluation.

Usage:

./agent --user-agent "argocd-application-controller" ...
sonarcloud[bot] commented 2 years ago

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

codecov[bot] commented 2 years ago

Codecov Report

Base: 55.46% // Head: 55.46% // No change to project coverage :thumbsup:

Coverage data is based on head (650d39f) compared to base (98ccd3d). Patch coverage: 0.00% of modified lines in pull request are covered.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #472 +/- ## ======================================= Coverage 55.46% 55.46% ======================================= Files 41 41 Lines 4504 4504 ======================================= Hits 2498 2498 Misses 1813 1813 Partials 193 193 ``` | [Impacted Files](https://codecov.io/gh/argoproj/gitops-engine/pull/472?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=argoproj) | Coverage Δ | | |---|---|---| | [pkg/cache/cluster.go](https://codecov.io/gh/argoproj/gitops-engine/pull/472/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=argoproj#diff-cGtnL2NhY2hlL2NsdXN0ZXIuZ28=) | `54.86% <0.00%> (ø)` | | Help us with your feedback. Take ten seconds to tell us [how you rate us](https://about.codecov.io/nps?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=argoproj). Have a feature suggestion? [Share it here.](https://app.codecov.io/gh/feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=argoproj)

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

alswl commented 2 years ago

@zachaller

Hi, could you review this simple pull request?

alswl commented 1 year ago

Friendly ping with @alexmt .