Skip to content

Commit 36060e2

Browse files
committed
Polishing.
Refine documentation links. See #5028
1 parent 39a42b4 commit 36060e2

File tree

5 files changed

+25
-20
lines changed

5 files changed

+25
-20
lines changed

spring-data-mongodb/src/main/java/org/springframework/data/mongodb/core/MongoOperations.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1415,8 +1415,8 @@ default long exactCount(Query query, String collectionName) {
14151415
* Id from MongoDB. If your Id property is a String then MongoDB ObjectId will be used to populate that string.
14161416
* Otherwise, the conversion from ObjectId to your property type will be handled by Spring's BeanWrapper class that
14171417
* leverages Type Conversion API. See
1418-
* <a href="https://docs.spring.io/spring/docs/current/spring-framework-reference/core.html#validation" > Spring's
1419-
* Type Conversion"</a> for more details. <br />
1418+
* <a href="https://docs.spring.io/spring-framework/reference/core/validation/convert.html">Spring's Type
1419+
* Conversion</a> for more details. <br />
14201420
* Insert is used to initially store the object into the database. To update an existing object use the
14211421
* {@link #save(Object)} method.
14221422
* <p>
@@ -1503,8 +1503,8 @@ default long exactCount(Query query, String collectionName) {
15031503
* If your object has an "Id' property, it will be set with the generated Id from MongoDB. If your Id property is a
15041504
* String then MongoDB ObjectId will be used to populate that string. Otherwise, the conversion from ObjectId to your
15051505
* property type will be handled by Spring's BeanWrapper class that leverages Type Conversion API. See
1506-
* <a href="https://docs.spring.io/spring/docs/current/spring-framework-reference/core.html#validation" > Spring's
1507-
* Type Conversion"</a> for more details.
1506+
* <a href="https://docs.spring.io/spring-framework/reference/core/validation/convert.html">Spring's Type
1507+
* Conversion</a> for more details.
15081508
* <p>
15091509
* A potential {@link org.springframework.data.annotation.Version} the property will be auto incremented. The
15101510
* operation raises an error in case the document has been modified in between.
@@ -1529,7 +1529,7 @@ default long exactCount(Query query, String collectionName) {
15291529
* If your object has an "Id' property, it will be set with the generated Id from MongoDB. If your Id property is a
15301530
* String then MongoDB ObjectId will be used to populate that string. Otherwise, the conversion from ObjectId to your
15311531
* property type will be handled by Spring's BeanWrapper class that leverages Type Conversion API. See
1532-
* <a href="https://docs.spring.io/spring/docs/current/spring-framework-reference/core.html#validation">Spring's Type
1532+
* <a href="https://docs.spring.io/spring-framework/reference/core/validation/convert.html">Spring's Type
15331533
* Conversion</a> for more details.
15341534
* <p>
15351535
* A potential {@link org.springframework.data.annotation.Version} the property will be auto incremented. The

spring-data-mongodb/src/main/java/org/springframework/data/mongodb/core/ReactiveMongoOperations.java

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1212,8 +1212,8 @@ default Mono<Long> exactCount(Query query, String collectionName) {
12121212
* Id from MongoDB. If your Id property is a String then MongoDB ObjectId will be used to populate that string.
12131213
* Otherwise, the conversion from ObjectId to your property type will be handled by Spring's BeanWrapper class that
12141214
* leverages Type Conversion API. See
1215-
* <a href="https://docs.spring.io/spring/docs/current/spring-framework-reference/core.html#validation" > Spring's
1216-
* Type Conversion"</a> for more details. <br />
1215+
* <a href="https://docs.spring.io/spring-framework/reference/core/validation/convert.html">Spring's Type
1216+
* Conversion</a> for more details. <br />
12171217
* Insert is used to initially store the object into the database. To update an existing object use the save method.
12181218
* <p>
12191219
* Inserting new objects will trigger {@link org.springframework.data.annotation.Version} property initialization.
@@ -1297,8 +1297,8 @@ default Mono<Long> exactCount(Query query, String collectionName) {
12971297
* If your object has an "Id' property, it will be set with the generated Id from MongoDB. If your Id property is a
12981298
* String then MongoDB ObjectId will be used to populate that string. Otherwise, the conversion from ObjectId to your
12991299
* property type will be handled by Spring's BeanWrapper class that leverages Type Conversion API. See
1300-
* <a href="https://docs.spring.io/spring/docs/current/spring-framework-reference/core.html#validation" > Spring's
1301-
* Type Conversion"</a> for more details. <br />
1300+
* <a href="https://docs.spring.io/spring-framework/reference/core/validation/convert.html">Spring's Type
1301+
* Conversion</a> for more details. <br />
13021302
* Insert is used to initially store the object into the database. To update an existing object use the save method.
13031303
* <p>
13041304
* A potential {@link org.springframework.data.annotation.Version} the property will be auto incremented. The
@@ -1361,8 +1361,8 @@ default Mono<Long> exactCount(Query query, String collectionName) {
13611361
* If your object has an "Id' property, it will be set with the generated Id from MongoDB. If your Id property is a
13621362
* String then MongoDB ObjectId will be used to populate that string. Otherwise, the conversion from ObjectId to your
13631363
* property type will be handled by Spring's BeanWrapper class that leverages Type Conversion API. See
1364-
* <a href="https://docs.spring.io/spring/docs/current/spring-framework-reference/core.html#validation" > Spring's
1365-
* Type Conversion"</a> for more details.
1364+
* <a href="https://docs.spring.io/spring-framework/reference/core/validation/convert.html">Spring's Type
1365+
* Conversion</a> for more details.
13661366
* <p>
13671367
* A potential {@link org.springframework.data.annotation.Version} the property will be auto incremented. The
13681368
* operation raises an error in case the document has been modified in between.
@@ -1387,7 +1387,7 @@ default Mono<Long> exactCount(Query query, String collectionName) {
13871387
* If your object has an "Id' property, it will be set with the generated Id from MongoDB. If your Id property is a
13881388
* String then MongoDB ObjectId will be used to populate that string. Otherwise, the conversion from ObjectId to your
13891389
* property type will be handled by Spring's BeanWrapper class that leverages Type Conversion API. See
1390-
* <a href="https://docs.spring.io/spring/docs/current/spring-framework-reference/core.html#validation">Spring's Type
1390+
* <a href="https://docs.spring.io/spring-framework/reference/core/validation/convert.html">Spring's Type
13911391
* Conversion</a> for more details.
13921392
* <p>
13931393
* A potential {@link org.springframework.data.annotation.Version} the property will be auto incremented. The
@@ -1410,7 +1410,7 @@ default Mono<Long> exactCount(Query query, String collectionName) {
14101410
* If your object has an "Id' property, it will be set with the generated Id from MongoDB. If your Id property is a
14111411
* String then MongoDB ObjectId will be used to populate that string. Otherwise, the conversion from ObjectId to your
14121412
* property type will be handled by Spring's BeanWrapper class that leverages Type Conversion API. See
1413-
* <a href="https://docs.spring.io/spring/docs/current/spring-framework-reference/core.html#validation"> Spring's Type
1413+
* <a href="https://docs.spring.io/spring-framework/reference/core/validation/convert.html">Spring's Type
14141414
* Conversion</a> for more details.
14151415
* <p>
14161416
* A potential {@link org.springframework.data.annotation.Version} the property will be auto incremented. The
@@ -1433,7 +1433,7 @@ default Mono<Long> exactCount(Query query, String collectionName) {
14331433
* If your object has an "Id' property, it will be set with the generated Id from MongoDB. If your Id property is a
14341434
* String then MongoDB ObjectId will be used to populate that string. Otherwise, the conversion from ObjectId to your
14351435
* property type will be handled by Spring's BeanWrapper class that leverages Type Conversion API. See
1436-
* <a href="https://docs.spring.io/spring/docs/current/spring-framework-reference/core.html#validation">Spring's Type
1436+
* <a href="https://docs.spring.io/spring-framework/reference/core/validation/convert.html">Spring's Type
14371437
* Conversion</a> for more details.
14381438
* <p>
14391439
* A potential {@link org.springframework.data.annotation.Version} the property will be auto incremented. The

src/main/antora/modules/ROOT/pages/mongodb/mongo-group.adoc

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,11 @@
33

44
As an alternative to using Map-Reduce to perform data aggregation, you can use the https://www.mongodb.org/display/DOCS/Aggregation#Aggregation-Group[`group` operation] which feels similar to using SQL's group by query style, so it may feel more approachable vs. using Map-Reduce. Using the group operations does have some limitations, for example it is not supported in a shared environment and it returns the full result set in a single BSON object, so the result should be small, less than 10,000 keys.
55

6-
Spring provides integration with MongoDB's group operation by providing methods on MongoOperations to simplify the creation and running of group operations. It can convert the results of the group operation to a POJO and also integrates with Spring's https://docs.spring.io/spring-framework/docs/{springVersion}/reference/html/core.html#resources[Resource abstraction] abstraction. This will let you place your JavaScript files on the file system, classpath, http server or any other Spring Resource implementation and then reference the JavaScript resources via an easy URI style syntax, e.g. 'classpath:reduce.js;. Externalizing JavaScript code in files if often preferable to embedding them as Java strings in your code. Note that you can still pass JavaScript code as Java strings if you prefer.
6+
Spring provides integration with MongoDB's group operation by providing methods on MongoOperations to simplify the creation and running of group operations.
7+
It can convert the results of the group operation to a POJO and also integrates with Spring's {spring-framework-docs}/core/resources.html[Resource abstraction] abstraction.
8+
This will let you place your JavaScript files on the file system, classpath, http server or any other Spring Resource implementation and then reference the JavaScript resources via an easy URI style syntax, e.g. 'classpath:reduce.js;.
9+
Externalizing JavaScript code in files if often preferable to embedding them as Java strings in your code.
10+
Note that you can still pass JavaScript code as Java strings if you prefer.
711

812
[[mongo.group.example]]
913
== Example Usage

src/main/antora/modules/ROOT/pages/mongodb/template-gridfs.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ Alternatively, you can also provide a `Document`.
120120

121121
The MongoDB's driver uses `AsyncInputStream` and `AsyncOutputStream` interfaces to exchange binary streams.
122122
Spring Data MongoDB adapts these interfaces to `Publisher<DataBuffer>`.
123-
Read more about `DataBuffer` in https://docs.spring.io/spring-framework/docs/{springVersion}/reference/html/core.html#databuffers[Spring's reference documentation].
123+
Read more about `DataBuffer` in {spring-framework-docs}/core/databuffer-codec.html[Spring's reference documentation].
124124
====
125125
======
126126

src/main/antora/resources/antora-resources/antora.yml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,18 +3,19 @@ prerelease: ${antora-component.prerelease}
33

44
asciidoc:
55
attributes:
6+
attribute-missing: 'warn'
7+
chomp: 'all'
68
version: ${project.version}
79
copyright-year: ${current.year}
810
springversionshort: ${spring.short}
911
springversion: ${spring}
10-
attribute-missing: 'warn'
1112
commons: ${springdata.commons.docs}
1213
include-xml-namespaces: false
13-
spring-data-commons-docs-url: https://docs.spring.io/spring-data/commons/reference
14-
spring-data-commons-javadoc-base: https://docs.spring.io/spring-data/commons/docs/${springdata.commons}/api/
14+
spring-data-commons-docs-url: https://docs.spring.io/spring-data/commons/reference/{commons}
15+
spring-data-commons-javadoc-base: '{spring-data-commons-docs-url}/api/java'
1516
springdocsurl: https://docs.spring.io/spring-framework/reference/{springversionshort}
16-
springjavadocurl: https://docs.spring.io/spring-framework/docs/${spring}/javadoc-api
1717
spring-framework-docs: '{springdocsurl}'
18+
springjavadocurl: https://docs.spring.io/spring-framework/docs/${spring}/javadoc-api
1819
spring-framework-javadoc: '{springjavadocurl}'
1920
springhateoasversion: ${spring-hateoas}
2021
releasetrainversion: ${releasetrain}

0 commit comments

Comments
 (0)