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

[enhancement] Add new metrics based on repo format #25

Open
andrey-gava opened this issue Jan 6, 2022 · 0 comments
Open

[enhancement] Add new metrics based on repo format #25

andrey-gava opened this issue Jan 6, 2022 · 0 comments

Comments

@andrey-gava
Copy link

Hello!

It would be great to add some new metrics, which can show usage of repos by they format(type)

All this data resides in data url json, in key "gauge" and have next names:
nexus.analytics.format_request_rates count (lables format,type,status)
nexus.analytics.repository_asset_count_by_format_type count (lables format,type)
nexus.analytics.repository_component_count_by_format_type count (lables format,type)
nexus.analytics.repository_type_counts count (lables format,type)

All this keys have similar structure.
Like:

{
  "gauges": {
    "nexus.analytics.format_request_rates": {
      "value": [
        {
          "key": "value",
          "key": "value",
          "key": "value",
        },
   ......
        {
          "key": "value",
          "key": "value",
          "key": "value",
        },
      ]
    },
 },
}

So maybe it take only one parse script to write, and then duplicate it for every new metric key.

Example from my server:

"nexus.analytics.repository_type_counts": { "value": [ { "format": "npm", "type": "hosted", "count": 1 }, { "format": "docker", "type": "hosted", "count": 4 }, { "format": "maven2", "type": "proxy", "count": 2 }, { "format": "maven2", "type": "hosted", "count": 3 }, { "format": "yum", "type": "hosted", "count": 3 }, { "format": "maven2", "type": "group", "count": 1 }, { "format": "nuget", "type": "proxy", "count": 1 }, { "format": "yum", "type": "group", "count": 1 }, { "format": "nuget", "type": "group", "count": 1 }, { "format": "yum", "type": "proxy", "count": 4 }, { "format": "npm", "type": "proxy", "count": 1 }, { "format": "helm", "type": "hosted", "count": 1 }, { "format": "nuget", "type": "hosted", "count": 1 } ] },
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

No branches or pull requests

1 participant