NuGet / NuGetGallery

NuGet Gallery is a package repository that powers https://www.nuget.org. Use this repo for reporting NuGet.org issues.
https://www.nuget.org/
Apache License 2.0
1.54k stars 643 forks source link

[NuGet.org Bug]: Download statistics are not updated #9352

Closed mariuszgromada closed 1 year ago

mariuszgromada commented 1 year ago

Impact

I'm unable to use NuGet.org statistics

Describe the bug

For many days now, for some packages, the download statistics show the same value.

image

Confirmation can also be found in Nuget Trends.

image

Repro Steps

On this URL: https://www.nuget.org/packages?q=math On this URL: https://nugettrends.com/packages?months=24&ids=MathParser.org-mXparser

Expected Behavior

MathParser.org-mXparser package has c.a. 1500-2000 downloads daily.

Screenshots

No response

Additional Context and logs

No response

agr commented 1 year ago

Investigating. Our statistics pipeline reports 1,324,021 downloads for that package, but apparently it is not propagated to the rest of the system.

agr commented 1 year ago

Actually, this number is also reported by the search service: https://azuresearch-usnc.nuget.org/query?q=MathParser.org-mXparser

image And, as far as I understand, the search service is the data source for nugettrends. So, regarding why data is missing there, you'd probably have to ask nuget-trends folks.

Still looking why Gallery number is off.

agr commented 1 year ago

I'm still looking into the issue. Something seems to be wrong with our statistics ingestion into Gallery. I am preparing a change that adds more telemetry, that hopefully would help understanding what's going on. It will take a few days to roll out.

mariuszgromada commented 1 year ago

Strange, now API shows again less image

agr commented 1 year ago

Regarding the search service numbers: I think we found the cause of it and applied a mitigation. We'll need to wait for some time for the statistics data to get reingested into the search. /cc @advay26

agr commented 1 year ago

We deployed the Gallery with extra telemetry for this case, and the issue seem to have stopped reproducing. I'll keep an eye on the download counts in the next few days.

agr commented 1 year ago

Download counts still seem to be in sync between Gallery and the search service. I'll close the issue for now as we lost repro. Feel free to reopen if it happens again and we'll have more telemetry that hopefully would let us understand what's going on.