Skip to content

Disable SpEL expression compilation by default in SimpleEvaluationContext #37035

Closed

Description

@sbrannen
No description provided.

Activity

  1. added this to the 7.0.9 milestone on Jul 9, 2026
  2. self-assigned this
    on Jul 9, 2026
  3. added
    in: coreIssues in core modules (aop, beans, core, context, expression)
    on Jul 9, 2026
  4. surangamadhushan24 commented on Aug 5, 2026

    @surangamadhushan24
  5. sbrannen commented on Aug 5, 2026

    @sbrannen
    Author
  6. added a commit that references this issue on Aug 20, 2026
    ea3e61f
  7. added a commit that references this issue on Aug 20, 2026
    0d08f8d
  8. changed the title [-]Improve documentation for SpEL compilation support[/-] [+]Disable SpEL expression compilation by default in `SimpleEvaluationContext`[/+] on Aug 21, 2026
  9. added and removed
    status: backportedAn issue that has been backported to maintenance branches
    on Aug 21, 2026
  10. sbrannen commented on Aug 21, 2026

    @sbrannen
    MemberAuthor

    Attention Required: In Spring Framework 7.0.9, SimpleEvaluationContext no longer supports expression compilation by default, regardless of the compiler mode configured via SpelParserConfiguration or the spring.expression.compiler.mode system property or Spring property. Applications that intentionally use SimpleEvaluationContext with trusted expressions and require compilation for performance reasons can opt in by calling withCompilationSupported() on the SimpleEvaluationContext builder. Care should be taken when opting in to compilation, as doing so removes the safety guards applied during interpreted evaluation.

  11. added a commit that references this issue on Sep 11, 2026
    3bdf702
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

for: upgrade-attentionAn issue requiring extra attention when upgradingin: coreIssues in core modules (aop, beans, core, context, expression)type: enhancementA general enhancement

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions