mirror of
https://github.com/morluto/rea.git
synced 2026-11-16 03:33:25 +00:00
fix(javascript): refuse member-mutation work beyond a fixed allowance (#11144)
* fix(javascript): refuse member-mutation work beyond a fixed allowance Member-mutation indexing retained every scheduled alias state until its query finished, with no bound on the phase. Conditional self-selections before one member write (#8294) multiplied those states until the worker heap was exhausted. Charge each scheduled alias state to a per-phase work meter. Past 524,288 states the phase is refused with a resource_constraint that names the fixed work allowance. The application and web bundle workers carry the reported limit to the parent, which rebuilds the refusal with that allowance instead of heap advice. Refs #8294 #6127 #6344 #7170 #7510 #8298 * test(javascript): prove the member-mutation meter spans the phase
This commit is contained in:
1 parent
4eafd9dee5
commit
d07ab79f9b
12 files changed
+371
-34
No files matched your search
@@ -831,6 +831,14 @@ caller can change the resource actually exhausted. Finite inline literal object
|
||||
spreads use iterative syntax traversal and no longer inherit a duplicate
|
||||
semantic-depth cut.
|
||||
|
||||
Member-mutation analysis also has a fixed work allowance of 524,288 alias
|
||||
states per source. It is not a `semantic_precision` field. A source whose alias
|
||||
histories exceed it is refused with a `resource_constraint` that names the
|
||||
fixed work allowance, instead of exhausting the worker heap. Static facts the
|
||||
worker had not yet reported are not kept, because a partial mutation index
|
||||
would let later reads keep stale values. Raising `max_heap_mb`,
|
||||
`analysis_timeout_ms` or `semantic_precision` does not admit the same source.
|
||||
|
||||
Byte, entry, path, and graph-shape bounds are hard limits. The parse deadline is
|
||||
checked before and between bounded parsing and traversal phases; the synchronous
|
||||
Babel and JSON parser calls cannot be preempted mid-call, so their input byte
|
||||
|
||||
Reference in new issue
Block a user