Skip to content

Core interceptors overhaul [SPR-12584] #17185

@spring-projects-issues

Description

@spring-projects-issues

Stéphane Nicoll opened SPR-12584 and commented

Core framework interceptors essentially require the same infrastructure but does not share a lot of code.

For instance, some interceptors are qualified-based (i.e. a qualifier can be set in the annotation to customize the "handler") which brings the need for a smart cache and proper handling for AspectJ (that should clean that cache appropriately since the aspect is basically a singleton for the classloader).

This issue is a general overhaul of that infrastructure that could span other issues along the way depending of the outcome of the initial investigation.

Things to investigate:

  • Some interceptor uses a qualifier on the annotation. Instead of retrieving the service every time (determineXyz) we should cache it. Transaction support has a good support now.
  • ReflectionUtils#doWithMethods can return the same method several times if it's overridden. If the parent method also has the annotation we may register a proxy or a handler several times for the same bean instance! Check ReflectionUtils.getUniqueDeclaredMethods instead

Issue Links:

Metadata

Metadata

Assignees

No one assigned

    Labels

    status: bulk-closedAn outdated, unresolved issue that's closed in bulk as part of a cleaning process

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions