Commit Graph

19316 Commits

Author SHA1 Message Date
Sebastien Deleuze db02d38c89 Restore annotated code samples
See gh-21778
2019-08-14 10:00:16 +02:00
Sebastien Deleuze ec740559ed Store refdoc preferred language
See gh-21778
2019-08-14 10:00:16 +02:00
Juergen Hoeller 9bd3a535cd Avoid UndeclaredThrowableStrategy with 1.8 bytecode level (CGLIB 3.3)
ClassLoaderAwareUndeclaredThrowableStrategy fails with a VerifyError on recent JDKs after the CGLIB 3.3 upgrade. The alternative is to replace it with a plain ClassLoaderAwareGeneratorStrategy (extracted from CglibSubclassingInstantiationStrategy) and custom UndeclaredThrowableException handling in CglibMethodInvocation.

See gh-23453
2019-08-14 00:14:14 +02:00
Brian Clozel 561af5f8f9 Replace propdeps plugin with custom plugin
Prior to this commit, the Spring Framework build would be using the
propdeps Gradle plugin to introduce two new configurations to the build:
"optional" and "provided". This would also configure related conventions
for IDEs, adding those configurations to published POMs.

This commit removes the need for this plugin and creates instead a
custom plugin for an "optional" configuration. While the Eclipse IDE
support is still supported, there is no need for specific conventions
for IntelliJ IDEA anymore.
This new plugin does not introduce the "provided" scope, as
"compileOnly" and "testCompileOnly" are here for that.

Also as of this commit, optional/provided dependencies are not published
with the Spring Framework modules POMs annymore.
Generally, these dependencies do not provide actionable information to
the developers reading / tools consuming the published POMs.

Optional/Provided dependencies are **not**:
* dependencies you can add to enable some supported feature
* dependencies versions that you can use to figure out CVEs or bugs
* dependencies that might be missing in existing Spring applications

In the context of Spring Framework, optional dependencies are just
libraries are Spring is compiling against for various technical reasons.
With that in mind, we are not publishing that information anymore.

See gh-23282
2019-08-13 18:19:37 +02:00
Sebastien Deleuze eff9cae314 Add global language switch capabilities to the refdoc
See gh-21778
2019-08-13 16:29:47 +02:00
Sebastien Deleuze 32a942fda9 Polishing 2019-08-13 16:29:47 +02:00
Sebastien Deleuze a2b8ea5173 Remove the black border from code samples
See gh-21778
2019-08-13 16:29:47 +02:00
Brian Clozel 4e5c780b99 Move TestSourcesPlugin to a Java Gradle plugin
This commit moves the existing "test sources" Gradle plugin from Groovy
to Java and updates the "buildSrc" build file to prepare for additional
plugins in the Spring Framework build.

The plugin itself looks, for a given Spring Framework module, at all the
project dependencies for the following scopes: "compile", "testCompile",
"api", "implementation" and "optional" (to be supported by a different
plugin).

See gh-23282
2019-08-13 16:23:59 +02:00
Sam Brannen e7e5cce735 Polish contribution
See gh-23457
2019-08-13 10:36:46 +02:00
Sauhard Sharma 91c0fbaadb Use valid example in Javadoc for @EnableWebFlux
This commit modifies the class-level Javadoc for the @EnableWebFlux
annotation to reference an actual method in WebFluxConfigurer.

Closes gh-23457
2019-08-13 10:27:29 +02:00
Lars Grefer c863b8994a Improve language-switch CSS
Closes gh-23454
2019-08-13 09:42:08 +02:00
Sebastien Deleuze b52a50a7e0 Use Kotlin extensions for ClassPathXmlApplicationContext refdoc
Closes gh-23456
2019-08-13 09:42:08 +02:00
Juergen Hoeller 4123910d3d Upgrade to CGLIB 3.3
Closes gh-23453
2019-08-12 19:36:06 +02:00
Sebastien Deleuze f3c7879831 Add missing css file
See gh-21778
2019-08-12 16:23:49 +02:00
Sebastien Deleuze 96658235c8 Add Kotlin code snippets to core refdoc
This commit introduces Kotlin code snippets, for now
in the core reference documentation. Other sections
will follow, as well as improvements like global
language switch.

See gh-21778
2019-08-12 15:45:18 +02:00
Sam Brannen fcbca7d569 Remove obsolete references to JUnit 4's ArrayComparisonFailure
See gh-23451
2019-08-12 12:45:14 +02:00
Michał Rowicki ee47bc3a25 Fix typo in data access reference documentation
Closes gh-23450
2019-08-12 11:21:54 +02:00
Sam Brannen 7538561a7a Polish ApplicationContextAwareProcessor
Due to recent changes, the (bean instanceof Aware) check is now
superfluous.
2019-08-10 14:24:10 +02:00
Sam Brannen 6c0e550b86 Polish contribution
See gh-23445
2019-08-10 14:07:15 +02:00
zhuzhuman978 849bbf00b5 Simplify if statements and replace try-finally with try-with-resources
Closes gh-23445
2019-08-10 14:03:18 +02:00
Sam Brannen fabdb07e53 Redeclare default methods in AbstractTestExecutionListener
This commit redeclares default methods in AbstractTestExecutionListener
in order to make them inlinable.
2019-08-09 16:39:35 +02:00
Sam Brannen 8b023b17c9 Polish contribution
See gh-23435
2019-08-09 15:04:07 +02:00
GungnirLaevatain 1dc2177a4a Avoid unnecessary processing in ApplicationContextAwareProcessor
This commit avoids unnecessary processing in the implementation of
postProcessBeforeInitialization() in ApplicationContextAwareProcessor
by immediately returning the supplied bean if it does not meet the
requirements for further processing.

Closes gh-23435
2019-08-09 14:54:05 +02:00
Sam Brannen 1925526df5 Improve reference documentation for ContextClosedEvent
Closes gh-23436
2019-08-09 13:58:31 +02:00
Daniel Le 60ec736264 Fix */* in Javadoc
This commit changes {@code &#42;&#47;&#42;} to <code>&#42;&#47;&#42;</code>
so that "*/*" is rendered correctly.

Closes gh-23439
2019-08-09 13:32:18 +02:00
Sam Brannen 0cdf992433 Fix grammar in Integration chapter regarding MDPs 2019-08-09 13:14:46 +02:00
Sam Brannen e4fec9364c Improve reference documentation for @Autowired's required attribute
Prior to this commit, the corresponding documentation was misleading.

Closes gh-23428
2019-08-09 11:37:46 +02:00
Sam Brannen 56c1e8ffd2 Polishing 2019-08-09 11:08:30 +02:00
Stephane Nicoll 977451064a Merge branch '5.1.x' 2019-08-09 09:37:36 +02:00
Stephane Nicoll 122e2ca2ac Merge pull request #23437 from wyhasany
* pr/23437:
  Fix typo

Closes gh-23437
2019-08-09 09:37:00 +02:00
Michał Rowicki 806fcb3839 Fix typo
See gh-23437
2019-08-09 09:36:46 +02:00
Sam Brannen a532afb15d Use System.nanoTime() in StopWatch
Prior to this commit, StopWatch used System.currentTimeMillis() to
track and report running time in milliseconds.

This commit updates the internals of StopWatch to use System.nanoTime()
instead of System.currentTimeMillis(). Consequently, running time is
now tracked and reported in nanoseconds; however, users still have the
option to retrieve running time in milliseconds or seconds.

Closes gh-23235
2019-08-07 17:39:42 +02:00
Sam Brannen 50e5334378 Simplify assertions within MockMvc internals 2019-08-07 17:32:19 +02:00
Sam Brannen d32cb7dac3 Avoid use of GenericTypeResolver.resolveParameterType() in tests
This commit avoids the use of the deprecated
GenericTypeResolver.resolveParameterType() method in tests in order to
avoid warnings in the Gradle build.
2019-08-07 14:23:15 +02:00
Sam Brannen 24f8d30935 Remove deprecated MergedAnnotations.SearchStrategy.EXHAUSTIVE constant
Closes gh-23391
2019-08-07 12:34:17 +02:00
Sam Brannen a43ba052e9 Remove unnecessary loop in SerializableTypeWrapper
Since arbitrary levels of proxies do not occur, this commit replaces
the `while` loop in SerializableTypeWrapper.unwrap() with a simple
`if` statement.

Closes gh-23415
2019-08-07 12:24:48 +02:00
Sam Brannen 83956f8e8b Overhaul StopWatchTests 2019-08-07 12:13:18 +02:00
Sam Brannen 03dd45fbd6 Use AssertJ in AnnotationAttributesTests 2019-08-06 18:18:16 +02:00
Sam Brannen 34767b14da Merge branch '5.1.x' 2019-08-06 18:11:47 +02:00
Sam Brannen 30ebc3b8e2 Remove superfluous AnnotationAttributes#putIfAbsent implementation
Since Java 8, putIfAbsent() is a standard method in java.util.Map. We
therefore no longer need the custom implementation that overrides the
standard implementation in HashMap.
2019-08-06 18:10:13 +02:00
Sam Brannen a092dc055e Check for instanceof Throwable in AnnotationAttributes#assertNotException
Prior to this commit, AnnotationAttributes#assertNotException checked if
the attribute value was an instance of Exception. Although this was
typically sufficient, the scope was not always broad enough -- for
example, if AnnotationReadingVisitorUtils#convertClassValues stored a
Throwable in the map (such as a LinkageError).

This commit fixes this by checking for an instance of Throwable in
AnnotationAttributes#assertNotException.

Closes gh-23424
2019-08-06 18:06:00 +02:00
Sebastien Deleuze 23cd261b6b Deprecate AnnotationConfigApplicationContext { } Kotlin extension
Closes gh-23420
2019-08-06 11:28:32 +02:00
Sam Brannen 4d6e359e25 Add missing @deprecated tags for ASM-based annotation search classes 2019-08-05 15:30:06 +02:00
Sam Brannen 82f301f42f Polishing 2019-08-05 15:29:04 +02:00
Sam Brannen e6ab6c9fe9 Add missing @deprecated tag for AnnotationMetadataReadingVisitor 2019-08-05 14:39:20 +02:00
Sam Brannen c2f5dabeee Polishing 2019-08-03 00:13:30 +02:00
Rossen Stoyanchev 63bf1bff23 Merge branch '5.1.x' 2019-08-02 16:33:02 +01:00
Rossen Stoyanchev 70be7117f3 Fix link to Spring AMQP and polish
Optimize section headings for dispaly in left hand navigation.
2019-08-02 16:32:01 +01:00
康智冬 5bb5b2b24d Fix grammar in package-info.java
Closes gh-23401
2019-08-02 13:40:25 +02:00
Stephane Nicoll d7a6ee5962 Merge branch '5.1.x' 2019-08-02 11:21:57 +02:00