Class PaginationCeilingExceededException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
co.ankatech.ankasecure.sdk.exception.PaginationCeilingExceededException
- All Implemented Interfaces:
Serializable
Thrown by the auto-paginating
listAllKeys(filters) when the server reports
more pages than the SDK's defensive ceiling allows (ceil(totalElements/size)+1
iterations, hard-capped at 10000 pages). The loop THROWS rather than
silently truncating — a partial "all keys" result would be a correctness lie.
Hitting this ceiling means the tenant's key population is beyond what a single
in-memory aggregation should carry; switch to the paged API
(listKeys(filters, page, size)) and process pages incrementally.
- Since:
- 3.0.0
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intDefensive hard cap on auto-pagination (10,000 pages × 200 = 2,000,000 keys). -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Field Details
-
HARD_PAGE_CAP
public static final int HARD_PAGE_CAPDefensive hard cap on auto-pagination (10,000 pages × 200 = 2,000,000 keys).- See Also:
-
-
Constructor Details
-
PaginationCeilingExceededException
public PaginationCeilingExceededException(long totalElements, int totalPages)
-
-
Method Details
-
getTotalElements
public long getTotalElements() -
getTotalPages
public int getTotalPages()
-