Skip to content

Cap REST API page size to prevent unbounded queries - #1013

Merged
oliche merged 1 commit into
masterfrom
fix/dataset-pagination-limit
Jul 22, 2026
Merged

Cap REST API page size to prevent unbounded queries#1013
oliche merged 1 commit into
masterfrom
fix/dataset-pagination-limit

Conversation

@oliche

@oliche oliche commented Jul 20, 2026

Copy link
Copy Markdown
Collaborator

Caps the DRF pagination limit at 1000 (LimitedLimitOffsetPagination). Previously a client could request ?limit=5000 (or higher), and parallel requests like this OOM-killed openalyx.

Fixes int-brain-lab/iblalyx#151

A client requesting large limit values (e.g. limit=5000) in parallel caused
an out-of-memory crash on openalyx. Add LimitedLimitOffsetPagination with
max_limit=1000 as the default DRF pagination class.

Fixes int-brain-lab/iblalyx#151
@oliche
oliche requested a review from grg2rsr July 20, 2026 20:17
@oliche
oliche merged commit a461acf into master Jul 22, 2026
2 checks passed
@oliche
oliche deleted the fix/dataset-pagination-limit branch July 22, 2026 05:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

openalyx outage 2026-07-18: OOM from parallel limit=5000 /datasets queries

1 participant