silverstripe / silverstripe-asset-admin

Silverstripe assets gallery for asset management
BSD 3-Clause "New" or "Revised" License
20 stars 79 forks source link

graphQL: changed size attribute of File to Float #1299

Closed sirtoobii closed 1 year ago

sirtoobii commented 2 years ago

Resolves #889

This bug needs to be addressed since its effect on the file admin is potentially devastating: In our case we migrated an SS3 installation to SS4 and they had files larger than the 2147483647 32-bit integer size which basically rendered the whole file admin unusable.

As long there is no support for 64-bit integers, this could be feasible workaround.

An other approach would be to define a custom scalar type - is this supported by silverstripe's graphQL implementation?

GuySartorelli commented 1 year ago

Hi there, Thank you for submitting this pull request.

I don't think this is a good approach to resolving the issue - the type should not be a float, it should be an int. An appropriate solution would be to implement a larger int type (which you have also referred to in https://github.com/silverstripe/silverstripe-graphql/issues/501).

I'm going to close this PR but if you want to give a go at implementing a proper 64bit int type I'd be happy to look at a PR which solves it that way.