Skip to content

Commit 3eb1042

Browse files
committed
Revised AOP documentation: load-time weaving, CGLIB etc
Includes removal of outdated Spring 1.2/2.0 references. Closes gh-22429
1 parent 013c0bc commit 3eb1042

File tree

2 files changed

+195
-281
lines changed

2 files changed

+195
-281
lines changed

src/docs/asciidoc/core/core-aop-api.adoc

+9-17
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,10 @@
11
[[aop-api]]
22
= Spring AOP APIs
33

4-
The previous chapter described the Spring's support for AOP with
5-
@AspectJ and schema-based aspect definitions. In this chapter, we discuss the lower-level
6-
Spring AOP APIs and the AOP support typically used in Spring 1.2 applications. For new
7-
applications, we recommend the use of the Spring 2.0 and later AOP support described in
8-
the previous chapter. However, when you work with existing applications (or when you read books
9-
and articles), you may come across Spring 1.2-style examples. Spring 5 remains backwards
10-
compatible with Spring 1.2, and everything described in this chapter is fully supported
11-
in Spring 5.
4+
The previous chapter described the Spring's support for AOP with @AspectJ and schema-based
5+
aspect definitions. In this chapter, we discuss the lower-level Spring AOP APIs. For common
6+
applications, we recommend the use of Spring AOP with AspectJ pointcuts as described in the
7+
previous chapter.
128

139

1410

@@ -117,7 +113,7 @@ Since 2.0, the most important type of pointcut used by Spring is
117113
`org.springframework.aop.aspectj.AspectJExpressionPointcut`. This is a pointcut that
118114
uses an AspectJ-supplied library to parse an AspectJ pointcut expression string.
119115

120-
See the <<aop,previous chapter>> for a discussion of supported AspectJ pointcut primitives.
116+
See the <<aop, previous chapter>> for a discussion of supported AspectJ pointcut primitives.
121117

122118

123119

@@ -253,8 +249,7 @@ following example shows how to subclass `StaticMethodMatcherPointcut`:
253249
====
254250

255251
There are also superclasses for dynamic pointcuts.
256-
257-
You can use custom pointcuts with any advice type in Spring 1.0 RC2 and above.
252+
You can use custom pointcuts with any advice type.
258253

259254

260255

@@ -1046,8 +1041,7 @@ to consider:
10461041
and included in the spring-core JAR. In other words, CGLIB-based AOP works "`out of
10471042
the box`", as do JDK dynamic proxies.
10481043

1049-
There is little performance difference between CGLIB proxying and dynamic proxies. As of
1050-
Spring 1.0, dynamic proxies are slightly faster. However, this may change in the future.
1044+
There is little performance difference between CGLIB proxying and dynamic proxies.
10511045
Performance should not be a decisive consideration in this case.
10521046

10531047

@@ -1150,7 +1144,7 @@ we override the transaction propagation settings:
11501144

11511145
Note that in the parent bean example, we explicitly marked the parent bean definition as
11521146
being abstract by setting the `abstract` attribute to `true`, as described
1153-
<<beans-child-bean-definitions,previously>>, so that it may not actually ever be
1147+
<<beans-child-bean-definitions, previously>>, so that it may not actually ever be
11541148
instantiated. Application contexts (but not simple bean factories), by default,
11551149
pre-instantiate all singletons. Therefore, it is important (at least for singleton beans)
11561150
that, if you have a (parent) bean definition that you intend to use only as a template,
@@ -1290,9 +1284,7 @@ Depending on how you created the proxy, you can usually set a `frozen` flag. In
12901284
case, the `Advised` `isFrozen()` method returns `true`, and any attempts to modify
12911285
advice through addition or removal results in an `AopConfigException`. The ability
12921286
to freeze the state of an advised object is useful in some cases (for example, to
1293-
prevent calling code removing a security interceptor). It may also be used in Spring 1.1
1294-
to allow aggressive optimization if runtime advice modification is known not to be
1295-
required.
1287+
prevent calling code removing a security interceptor).
12961288

12971289

12981290

0 commit comments

Comments
 (0)