Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ public class ScenePoolService {
private static final int DEFAULT_LIMIT = 200;
private static final String CLEAR_LIMIT_KEY = "clear.pool.limit";
private static final int MAX_PAGE_SIZE = 300;
private static final int MAX_PAGE_INDEX = 200;
private static final int MAX_ITERATIONS = 200;
private static final int MAX_LIMIT = 5000;
private static final int MIN_LIMIT = 0;
Expand Down Expand Up @@ -84,8 +85,14 @@ public SceneDTO findRecordsByAppId(String appId, String category, Integer pageIn
}

pageSize = Math.min(pageSize, MAX_PAGE_SIZE);
pageIndex = Math.min(pageIndex, MAX_PAGE_INDEX);

SceneDTO sceneDTO = new SceneDTO();
if (pageIndex == MAX_PAGE_INDEX) {
sceneDTO.setTotal(0L);
sceneDTO.setSceneList(Collections.emptyList());
return sceneDTO;
}
long count = provider.countByAppId(appId);
sceneDTO.setTotal(count);
if (count == 0L) {
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -449,7 +449,7 @@
</profiles>

<properties>
<revision>2.0.8</revision>
<revision>2.0.9</revision>
<commons-lang3.version>3.3.2</commons-lang3.version>
<java.version>1.8</java.version>

Expand Down