everyone. I have a controller with Specification and Pageable parameters. If I need to return data form db in a usual way - everything works fine. I get my data by 20 size pages. Like this:
............
"totalElements": 2612,
"totalPages": 131,
"last": false,
"size": 20,
"number": 0,
But also, I need to return all my elements. Acording to the example, if I get totalElements: 2612 - I want to get all 2612. As I understant, Spring has default max-page-size = 2000. Because of it, If I have a query with size = 2612
http://localhost:7038/api/get-journal/2c9a508179b2933a0179b2be69fd0003?yearReg=2023&page=0&size=2612
I get an answer :
"totalElements": 2612,
"totalPages": 2,
"last": false,
"size": 2000,
You can see, that instead of 2612, I have 2000 and two pages.
Similar problems didn't help me:
https://stackoverflow.com/questions/23751193/spring-data-jpa-limit-pagesize-how-to-set-to-maxsize
I've already tried to create ConfigClass or add into app.properties : spring.data.web.pageable.max-page-size=10000 or spring.data.web.pageable.max-page-size=10000
I use Spring Boot 2.3.3.
EDIT I get a changed variable even in my rest controller: