Update graphql statistics holders to GraphQL::FLOAT_TYPE
What does this MR do?
This is a barebone attempt to get #42671 (closed) fixed.
If this does not work as expected, then ;-;, but in any other case ^-^
Currently the project- and group-statistics are saved in an INT_TYPE field, which fails for values that are larger than 2^31 (as per the graphql spec). As the amounts of data stored for a project can easily go past 2 GiB, this means that queries requesting statistics for large projects will always fail with an error 500 for those projects.
The error thrown implies that replacing GraphQL::INT_TYPE with GraphQL::FLOAT_TYPE could fix most of the problem, so here we go.
Screenshots
n/a
Does this MR meet the acceptance criteria?
Conformity
-
Changelog entry -
Documentation (if required) -
Code review guidelines -
Merge request performance guidelines -
Style guides -
Database guides -
Separation of EE specific content
Availability and Testing
What risks does this change pose? Metrics could also break for projects/root groups < 4GiB large.
How might it affect the quality/performance of the product? The frontend may not like GraphQL::FLOAT_TYPE
on places where it expects integer values, but that's me guessing.
What additional test coverage or changes to tests will be needed? Someone should probably create tests which also include a project/projects with ginormous amounts of stuff, like 2^33 issues, 2^33 included projects, 2^33 storage used, 2^33 artifacts, etc... But until that time, nothing much...
Will it require cross-browser testing? Probably just as much as any other graphql schema change.
This change has not been tested locally.
I am available for comments / pointers, but have no dev environment to work with, so any work is on a best-effort basis, at probably the same level of effort as the current MR.
-
Review and add/update tests for this feature/bug. Consider all test levels. See the Test Planning Process. -
Tested in all supported browsers
Security
N/A