mirror of
https://github.com/Ark0N/Codeman.git
synced 2026-11-14 10:39:32 +01:00
fix(limits): lower the session ceiling to 462 so the layout budget holds
An owner's tab layout holds at most MAX_TAB_REFS (512) refs, counting saved web tabs (up to MAX_WEBVIEWS, 50 by default) as well as sessions. With a ceiling of 500, session creation could still fail with HTTP 500 on the layout limit before the capacity message. 512 - 50 = 462; a test pins the ceiling plus MAX_WEBVIEWS inside MAX_TAB_REFS so the two limits cannot drift apart again. Co-Authored-By: Christian Haberl <116439789+christianhaberl@users.noreply.github.com> Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
1 parent
b073035bdc
commit
e58c1a2f19
9 files changed
+28
-19
No files matched your search
+1
-1
@@ -1981,7 +1981,7 @@ export const CaseOrderSchema = z.object({
|
||||
/** PUT /api/session-order — global tab order (ordered sessionIds), COD-131 */
|
||||
export const SessionOrderUpdateSchema = z.object({
|
||||
// Bounded defensively: ids are uuid-ish (<=100 chars) and the client pushes only
|
||||
// its open-tab order (max sessions is 50 by default, at most 500 via CODEMAN_MAX_SESSIONS,
|
||||
// its open-tab order (max sessions is 50 by default, at most 462 via CODEMAN_MAX_SESSIONS,
|
||||
// see MAX_CONCURRENT_SESSIONS_CEILING) — 500 leaves enough room while
|
||||
// keeping a hostile/buggy client from persisting megabytes into state.json.
|
||||
order: z.array(z.string().max(100)).max(500),
|
||||
|
||||
Reference in new issue
Block a user