Skip to content

Commit 3774e9b

Browse files
rwinchrstoyanchev
authored andcommitted
Trim IDs with parent
1 parent 9c38f8c commit 3774e9b

File tree

17 files changed

+94
-94
lines changed

17 files changed

+94
-94
lines changed

framework-docs/modules/ROOT/pages/core/aop/ataspectj/aspectj-support.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ element, as the following example shows:
4848

4949
This assumes that you use schema support as described in
5050
xref:core/appendix/xsd-schemas.adoc[XML Schema-based configuration].
51-
See xref:core/appendix/xsd-schemas.adoc#core.appendix.xsd-schemas-aop[the AOP schema] for how to
51+
See xref:core/appendix/xsd-schemas.adoc#aop[the AOP schema] for how to
5252
import the tags in the `aop` namespace.
5353

5454

framework-docs/modules/ROOT/pages/core/aop/schema.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ of advice parameters.
1010

1111
To use the aop namespace tags described in this section, you need to import the
1212
`spring-aop` schema, as described in xref:core/appendix/xsd-schemas.adoc[XML Schema-based configuration]
13-
. See xref:core/appendix/xsd-schemas.adoc#core.appendix.xsd-schemas-aop[the AOP schema]
13+
. See xref:core/appendix/xsd-schemas.adoc#aop[the AOP schema]
1414
for how to import the tags in the `aop` namespace.
1515

1616
Within your Spring configurations, all aspect and advisor elements must be placed within

framework-docs/modules/ROOT/pages/core/aop/using-aspectj.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ use Java-based configuration, you can add `@EnableSpringConfigured` to any
182182
----
183183

184184
If you prefer XML based configuration, the Spring
185-
xref:core/appendix/xsd-schemas.adoc#core.appendix.xsd-schemas-context[`context` namespace]
185+
xref:core/appendix/xsd-schemas.adoc#context[`context` namespace]
186186
defines a convenient `context:spring-configured` element, which you can use as follows:
187187

188188
[source,xml,indent=0,subs="verbatim"]

framework-docs/modules/ROOT/pages/core/aot.adoc

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
[[core.aot]]
1+
[[aot]]
22
= Ahead of Time Optimizations
33

44
This chapter covers Spring's Ahead of Time (AOT) optimizations.
55

66
For AOT support specific to integration tests, see xref:testing/testcontext-framework/aot.adoc[Ahead of Time Support for Tests].
77

8-
[[core.aot.introduction]]
8+
[[aot.introduction]]
99
== Introduction to Ahead of Time Optimizations
1010

1111
Spring's support for AOT optimizations is meant to inspect an `ApplicationContext` at build time and apply decisions and discovery logic that usually happens at runtime.
@@ -30,7 +30,7 @@ A Spring AOT processed application typically generates:
3030
NOTE: At the moment, AOT is focused on allowing Spring applications to be deployed as native images using GraalVM.
3131
We intend to support more JVM-based use cases in future generations.
3232

33-
[[core.aot.basics]]
33+
[[aot.basics]]
3434
== AOT engine overview
3535

3636
The entry point of the AOT engine for processing an `ApplicationContext` arrangement is `ApplicationContextAotGenerator`. It takes care of the following steps, based on a `GenericApplicationContext` that represents the application to optimize and a {api-spring-framework}/aot/generate/GenerationContext.html[`GenerationContext`]:
@@ -46,21 +46,21 @@ The `RuntimeHints` instance can also be used to generate the relevant GraalVM na
4646

4747
Those steps are covered in greater detail in the sections below.
4848

49-
[[core.aot.refresh]]
49+
[[aot.refresh]]
5050
== Refresh for AOT Processing
5151

5252
Refresh for AOT processing is supported on all `GenericApplicationContext` implementations.
5353
An application context is created with any number of entry points, usually in the form of `@Configuration`-annotated classes.
5454

5555
Let's look at a basic example:
5656

57-
include-code::AotProcessingSample[tag=myapplication]
57+
include-code::./AotProcessingSample[tag=myapplication]
5858

5959
Starting this application with the regular runtime involves a number of steps including classpath scanning, configuration class parsing, bean instantiation, and lifecycle callback handling.
6060
Refresh for AOT processing only applies a subset of what happens with a xref:core/beans/introduction.adoc[regular `refresh`].
6161
AOT processing can be triggered as follows:
6262

63-
include-code::AotProcessingSample[tag=aotcontext]
63+
include-code::./AotProcessingSample[tag=aotcontext]
6464

6565
In this mode, xref:core/beans/factory-extension.adoc#beans-factory-extension-factory-postprocessors[`BeanFactoryPostProcessor` implementations] are invoked as usual.
6666
This includes configuration class parsing, import selectors, classpath scanning, etc.
@@ -76,7 +76,7 @@ This makes sure to create any proxy that will be required at runtime.
7676

7777
Once this part completes, the `BeanFactory` contains the bean definitions that are necessary for the application to run. It does not trigger bean instantiation but allows the AOT engine to inspect the beans that will be created at runtime.
7878

79-
[[core.aot.bean-factory-initialization-contributions]]
79+
[[aot.bean-factory-initialization-contributions]]
8080
== Bean Factory Initialization AOT Contributions
8181

8282
Components that want to participate in this step can implement the {api-spring-framework}/beans/factory/aot/BeanFactoryInitializationAotProcessor.html[`BeanFactoryInitializationAotProcessor`] interface.
@@ -99,7 +99,7 @@ If such a bean is registered using an `@Bean` factory method, ensure the method
9999
====
100100

101101

102-
[[core.aot.bean-registration-contributions]]
102+
[[aot.bean-registration-contributions]]
103103
=== Bean Registration AOT Contributions
104104

105105
A core `BeanFactoryInitializationAotProcessor` implementation is responsible for collecting the necessary contributions for each candidate `BeanDefinition`.
@@ -186,7 +186,7 @@ When a `datasource` instance is required, a `BeanInstanceSupplier` is called.
186186
This supplier invokes the `dataSource()` method on the `dataSourceConfiguration` bean.
187187

188188

189-
[[core.aot.hints]]
189+
[[aot.hints]]
190190
== Runtime Hints
191191

192192
Running an application as a native image requires additional information compared to a regular JVM runtime.
@@ -210,22 +210,22 @@ For cases that the core container cannot infer, you can register such hints prog
210210
A number of convenient annotations are also provided for common use cases.
211211

212212

213-
[[core.aot.hints.import-runtime-hints]]
213+
[[aot.hints.import-runtime-hints]]
214214
=== `@ImportRuntimeHints`
215215

216216
`RuntimeHintsRegistrar` implementations allow you to get a callback to the `RuntimeHints` instance managed by the AOT engine.
217217
Implementations of this interface can be registered using `@ImportRuntimeHints` on any Spring bean or `@Bean` factory method.
218218
`RuntimeHintsRegistrar` implementations are detected and invoked at build time.
219219

220-
include-code::SpellCheckService[]
220+
include-code::./SpellCheckService[]
221221

222222
If at all possible, `@ImportRuntimeHints` should be used as close as possible to the component that requires the hints.
223223
This way, if the component is not contributed to the `BeanFactory`, the hints won't be contributed either.
224224

225225
It is also possible to register an implementation statically by adding an entry in `META-INF/spring/aot.factories` with a key equal to the fully qualified name of the `RuntimeHintsRegistrar` interface.
226226

227227

228-
[[core.aot.hints.reflective]]
228+
[[aot.hints.reflective]]
229229
=== `@Reflective`
230230

231231
{api-spring-framework}/aot/hint/annotation/Reflective.html[`@Reflective`] provides an idiomatic way to flag the need for reflection on an annotated element.
@@ -239,7 +239,7 @@ Library authors can reuse this annotation for their own purposes.
239239
If components other than Spring beans need to be processed, a `BeanFactoryInitializationAotProcessor` can detect the relevant types and use `ReflectiveRuntimeHintsRegistrar` to process them.
240240

241241

242-
[[core.aot.hints.register-reflection-for-binding]]
242+
[[aot.hints.register-reflection-for-binding]]
243243
=== `@RegisterReflectionForBinding`
244244

245245
{api-spring-framework}/aot/hint/annotation/RegisterReflectionForBinding.html[`@RegisterReflectionForBinding`] is a specialization of `@Reflective` that registers the need for serializing arbitrary types.
@@ -262,14 +262,14 @@ The following example registers `Account` for serialization.
262262
}
263263
----
264264

265-
[[core.aot.hints.testing]]
265+
[[aot.hints.testing]]
266266
=== Testing Runtime Hints
267267

268268
Spring Core also ships `RuntimeHintsPredicates`, a utility for checking that existing hints match a particular use case.
269269
This can be used in your own tests to validate that a `RuntimeHintsRegistrar` contains the expected results.
270270
We can write a test for our `SpellCheckService` and ensure that we will be able to load a dictionary at runtime:
271271

272-
include-code::SpellCheckServiceTests[tag=hintspredicates]
272+
include-code::./SpellCheckServiceTests[tag=hintspredicates]
273273

274274
With `RuntimeHintsPredicates`, we can check for reflection, resource, serialization, or proxy generation hints.
275275
This approach works well for unit tests but implies that the runtime behavior of a component is well known.
@@ -281,11 +281,11 @@ For more targeted discovery and testing, Spring Framework ships a dedicated modu
281281
This module contains the RuntimeHints Agent, a Java agent that records all method invocations that are related to runtime hints and helps you to assert that a given `RuntimeHints` instance covers all recorded invocations.
282282
Let's consider a piece of infrastructure for which we'd like to test the hints we're contributing during the AOT processing phase.
283283

284-
include-code::SampleReflection[]
284+
include-code::./SampleReflection[]
285285

286286
We can then write a unit test (no native compilation required) that checks our contributed hints:
287287

288-
include-code::SampleReflectionRuntimeHintsTests[]
288+
include-code::./SampleReflectionRuntimeHintsTests[]
289289

290290
If you forgot to contribute a hint, the test will fail and provide some details about the invocation:
291291

framework-docs/modules/ROOT/pages/core/appendix.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
[[core.appendix]]
1+
[[appendix]]
22
= Appendix
33
:page-section-summary-toc: 1
44

framework-docs/modules/ROOT/pages/core/appendix/application-startup-steps.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
[[core.appendix.application-startup-steps]]
1+
[[application-startup-steps]]
22
= Application Startup Steps
33

44
This part of the appendix lists the existing `StartupSteps` that the core container is instrumented with.

framework-docs/modules/ROOT/pages/core/appendix/xml-custom.adoc

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
[[core.appendix.xml-custom]]
1+
[[xml-custom]]
22
= XML Schema Authoring
33

4-
[[core.appendix.xsd-custom-introduction]]
4+
[[xsd-custom-introduction]]
55
Since version 2.0, Spring has featured a mechanism for adding schema-based extensions to the
66
basic Spring XML format for defining and configuring beans. This section covers
77
how to write your own custom XML bean definition parsers and
@@ -39,7 +39,7 @@ through the basic steps of making a custom extension.)
3939

4040

4141

42-
[[core.appendix.xsd-custom-schema]]
42+
[[xsd-custom-schema]]
4343
== Authoring the Schema
4444

4545
Creating an XML configuration extension for use with Spring's IoC container starts with
@@ -111,7 +111,7 @@ defined in the enumeration.
111111

112112

113113

114-
[[core.appendix.xsd-custom-namespacehandler]]
114+
[[xsd-custom-namespacehandler]]
115115
== Coding a `NamespaceHandler`
116116

117117
In addition to the schema, we need a `NamespaceHandler` to parse all elements of
@@ -182,7 +182,7 @@ custom element, as we can see in the next step.
182182

183183

184184

185-
[[core.appendix.xsd-custom-parser]]
185+
[[xsd-custom-parser]]
186186
== Using `BeanDefinitionParser`
187187

188188
A `BeanDefinitionParser` is used if the `NamespaceHandler` encounters an XML
@@ -272,7 +272,7 @@ is the extraction and setting of the bean definition's unique identifier.
272272

273273

274274

275-
[[core.appendix.xsd-custom-registration]]
275+
[[xsd-custom-registration]]
276276
== Registering the Handler and the Schema
277277

278278
The coding is finished. All that remains to be done is to make the Spring XML
@@ -284,7 +284,7 @@ XML parsing infrastructure automatically picks up your new extension by consumin
284284
these special properties files, the formats of which are detailed in the next two sections.
285285

286286

287-
[[core.appendix.xsd-custom-registration-spring-handlers]]
287+
[[xsd-custom-registration-spring-handlers]]
288288
=== Writing `META-INF/spring.handlers`
289289

290290
The properties file called `spring.handlers` contains a mapping of XML Schema URIs to
@@ -303,7 +303,7 @@ namespace extension and needs to exactly match exactly the value of the `targetN
303303
attribute, as specified in your custom XSD schema.
304304

305305

306-
[[core.appendix.xsd-custom-registration-spring-schemas]]
306+
[[xsd-custom-registration-spring-schemas]]
307307
=== Writing 'META-INF/spring.schemas'
308308

309309
The properties file called `spring.schemas` contains a mapping of XML Schema locations
@@ -327,7 +327,7 @@ the `NamespaceHandler` and `BeanDefinitionParser` classes on the classpath.
327327

328328

329329

330-
[[core.appendix.xsd-custom-using]]
330+
[[xsd-custom-using]]
331331
== Using a Custom Extension in Your Spring XML Configuration
332332

333333
Using a custom extension that you yourself have implemented is no different from using
@@ -361,13 +361,13 @@ in a Spring XML configuration file:
361361

362362

363363

364-
[[core.appendix.xsd-custom-meat]]
364+
[[xsd-custom-meat]]
365365
== More Detailed Examples
366366

367367
This section presents some more detailed examples of custom XML extensions.
368368

369369

370-
[[core.appendix.xsd-custom-custom-nested]]
370+
[[xsd-custom-custom-nested]]
371371
=== Nesting Custom Elements within Custom Elements
372372

373373
The example presented in this section shows how you to write the various artifacts required
@@ -719,7 +719,7 @@ http\://www.foo.example/schema/component/component.xsd=com/foo/component.xsd
719719
----
720720

721721

722-
[[core.appendix.xsd-custom-custom-just-attributes]]
722+
[[xsd-custom-custom-just-attributes]]
723723
=== Custom Attributes on "`Normal`" Elements
724724

725725
Writing your own custom parser and the associated artifacts is not hard. However,

0 commit comments

Comments
 (0)