I need to implement RFC2616-14.35.2 Range Headers pagination for my project.
It seems that no implementation is available for Spring Boot natively nor through an external dependency.
For example, upon a simple GET my controller should return:
GET /cars
Accept-Ranges: cars
To request a specific range of records, my request headers would contain:
GET /cars
Content-Range: cars 0-9
and controller would return:
GET /cars
Content-Range: cars 0-9/100 (total records)
I’ve tried to manually implement all of this, but I end up having to manually code repository methods and polluting my codebase. I also need to implement filtering and ordering along this feature.
Is there a library that could help? Or a simple implementation for this?