Hi,
While working on Pageable and PageableDefault, I realize that the defaults are 20 and 10 respectively.
I did a search, and found it mentioned in https://github.com/spring-projects/spring-data-commons/issues/2279, but it does not seem to have reported in here (I tried to search). Hence, I wanted to raise this, and ask if this was intentional?
Thanks!
Comment From: wilkinsona
Spring Boot's default aligns with the default in Spring Data's PageableHandlerMethodArgumentResolverSupport:
static final Pageable DEFAULT_PAGE_REQUEST = PageRequest.of(0, 20);
It's to this resolver which the Spring Boot configuration property is applied so I don't think we should do anything in Spring Boot at this time.
I think this should be considered again by the Spring Data team as they may want to align the defaults in @PageableDefault and PageableHandlerMethodArgumentResolverSupport. If that alignment results in the default becoming 10, we can update Boot accordingly. Until that happens, I don't think we should do anything in Boot so I am going to close this issue.
Comment From: bwgjoseph
Thanks for looking into it. Agreed, the alignment should probably be on Spring Data side.