refactor(db): introduce ORACLE_MAX_CHUNK_SIZE constant for array_chunk query limits - #13462
Conversation
…k query limits Fixes nextcloud#5214
There was a problem hiding this comment.
Pull request overview
This PR introduces a named constant in MessageMapper to document and centralize the Oracle IN (...) chunk-size limit, and replaces one hardcoded 1000 chunk size with the constant.
Changes:
- Added
MessageMapper::ORACLE_MAX_CHUNK_SIZE = 1000. - Replaced one
array_chunk(..., 1000)usage witharray_chunk(..., self::ORACLE_MAX_CHUNK_SIZE).
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
| public const ORACLE_MAX_CHUNK_SIZE = 1000; | ||
|
|
|
Thanks for catching those! Updated |
|
Thanks for looking into this Was an AI agent used for the contribution? Then please disclose it via the commit trailer and the PR description template. See contributing and agents files. |
b721ff1 to
2fdc88b
Compare
|
Thanks @ChristophWurst! I have updated the PR according to Nextcloud's AI agent guidelines:
Also, all 12 hardcoded |
|
Read the guides carefully. We use assisted-by, not co-authored-by. |
304ff4d to
3b90eb7
Compare
|
Updated the commit trailer to |
…k query limits Replace hardcoded 1000 array_chunk sizes across MessageMapper with self::ORACLE_MAX_CHUNK_SIZE constant to document and centralize the Oracle IN (...) query limit. Fixes nextcloud#5214 Signed-off-by: LAKSHAN MURUGANANDAM <95610803+lakshanmuruganandam@users.noreply.github.com> Assisted-by: LAKSHAN MURUGANANDAM <95610803+lakshanmuruganandam@users.noreply.github.com>
3b90eb7 to
4f09ce2
Compare
|
Updated the commit trailer format: |
|
Am I communicating with a human or an AI? |
|
Human here! I'm Lakshan, driving all the contributions and managing the PRs manually. |
|
Cool! Please read the contributing/agents file and fix the commit trailer |
Summary of Changes
MessageMapper::ORACLE_MAX_CHUNK_SIZE = 1000constant.array_chunk(..., 1000)occurrences acrossMessageMapper.phpwithself::ORACLE_MAX_CHUNK_SIZEto document and centralize the Oracle SQLIN (...)chunk size limit.Fixes #5214