Annotation Type ScopedProxy

public @interface ScopedProxy

Marker annotation identical in functionality with <aop:scoped-proxy/> tag. Provides a smart proxy backed by a scoped bean, which can be injected into object instances (usually singletons) allowing the same reference to be held while delegating method invocations to the backing, scoped beans.

Used with scoped beans (non-singleton and non-prototype).

 public class ScopedConfig {

  @Bean(scope = "myScope")
  public SomeBean someBean() {
      return new SomeBean();

  public SomeOtherBean() {
      return new AnotherBean(someBean());

See Spring reference documentation for more details.

Costin Leau

Optional Element Summary
 boolean proxyTargetClass
          Use CGLib-based class proxies (true) or JDK interface-based (false).


public abstract boolean proxyTargetClass
Use CGLib-based class proxies (true) or JDK interface-based (false). Default is CGLib (true).