You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Account for all array objects when checking array size in SpELΒ #36998
When constructing a multidimensional array in a SpEL expression, ConstructorReference.createArray() enforces a size limit by checking the product of all dimension sizes. However, Java allocates a distinct array object at every nesting level, and the current check does not consider this count.
Ideally, the MAX_ARRAY_ELEMENTS threshold should apply to both the product of all dimension sizes and the total number of array objects allocated across all nesting levels.
Since SimpleEvaluationContext does not permit array creation within SpEL expressions, this enhancement effectively only applies to expressions evaluated via StandardEvaluationContext.
NOTE: This issue is assigned and therefore not suitable for community contributions.
Activity
Account for all array objects when checking array size in SpEL