Skip to content

Allow opt-out of cglib proxy #31635

Open
Open
@chrylis

Description

@chrylis

Due to the interaction between Spring Security and Spring MVC, I need to keep using cglib proxies in my Web application. However, I have a bean whose implementation does not play nicely with cglib, and I would like a mechanism to mark a bean explicitly as "use a JDK proxy".

The @Scope annotation provides an attribute proxyMode and suggests that proxyMode = INTERFACES should get me a JDK proxy, but the ProxyFactory appears to go straight to CglibAopProxy, which throws.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    in: coreIssues in core modules (aop, beans, core, context, expression)type: enhancementA general enhancement

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @jhoeller@chrylis@spring-projects-issues

        Issue actions

          Allow opt-out of cglib proxy · Issue #31635 · spring-projects/spring-framework