Commit Graph

2194 Commits

Author SHA1 Message Date
Stephane Nicoll
a46b71a4b9 Merge branch '5.3.x' 2022-05-31 10:01:50 +02:00
Ikko Ashimine
6e3b3c5419 Fix typo in webflux.adoc
See gh-28542
2022-05-31 10:01:13 +02:00
Sam Brannen
a3ee27bb4d Polishing 2022-05-30 20:00:07 +02:00
Eddú Meléndez Gonzales
506b78f469 Use getHost instead of getContainerIpAddress in Redis examples
getContainerIpAddress is deprecated.

Closes gh-28461
2022-05-15 15:12:03 +02:00
Sam Brannen
4b0531b4aa Merge branch '5.3.x' 2022-05-11 17:33:52 +02:00
Sam Brannen
48c797e429 Fix Kotlin example for static factory method
Closes gh-28399
2022-05-11 17:33:31 +02:00
Sam Brannen
5ddbdb6ba7 Merge branch '5.3.x' 2022-05-11 17:17:20 +02:00
Sam Brannen
be782a2197 Polish ref docs regarding the BeanFactory API
See gh-28403
2022-05-11 17:16:40 +02:00
rstoyanchev
922636e85e Content decoding in client exceptions
Closes gh-28190
2022-05-10 11:48:46 +01:00
Maciej Walkowiak
2713f28c28 Fix typo in declarative HTTP interfaces docs
Closes gh-28431
2022-05-09 14:12:51 +02:00
rstoyanchev
d2b674391a Add documentation for interface proxy client
Closes gh-28386
2022-05-09 09:52:15 +01:00
rstoyanchev
54d90aa6f5 Remove Remoting and EJB sections in reference docs 2022-05-09 09:52:15 +01:00
Phillip Webb
4b82546b97 Improve TestCompiler and allow lookup based class defines
Update the `TestCompiler` so that classes can be defined using
a `Lookup`. This update allows package-private classes to be
accessed without needing a quite so unusual classloader setup.

The `@CompileWithTargetClassAccess` should be added to any
test that needs to use `Lookup` based defines. The test will
run with a completed forked classloader so not to pollute the
main classloader.

This commit also adds some useful additional APIs.

See gh-28120
2022-05-05 12:35:21 -07:00
Phillip Webb
44bdcef0b9 Tweak Eclipse settings 2022-05-05 12:35:21 -07:00
Juergen Hoeller
f963fc5f98 Check that nullable annotations are from org.springframework.lang
Closes gh-28410
2022-05-05 18:02:27 +02:00
Juergen Hoeller
17c778e3a0 Preserve javax nullability annotations for AOP Alliance fork
See gh-28410
2022-05-05 17:26:17 +02:00
Sam Brannen
0d561caf6d Merge branch '5.3.x' 2022-05-05 16:32:27 +02:00
Lee, Kyutae
7a75b94556 Fix typo in reference docs regarding RequestMappingHandlerAdapter
Closes gh-28370
2022-05-05 16:31:40 +02:00
Phillip Webb
63b129a3f7 Check that nullable annotations are from org.springframework.lang
Fix a few incorrect nullable annotation imports and add a checkstyle
rule to ensure they don't return.

Closes gh-28410
2022-05-03 11:14:53 -07:00
Sam Brannen
437b35b336 Merge branch '5.3.x' 2022-05-03 12:15:45 +02:00
Sam Brannen
ed06a6de26 Convert SimpleFormController example to @Controller in reference manual
This change is necessary since the SimpleFormController class no longer
exists.
2022-05-03 12:03:04 +02:00
Johannes Wengert
08bc9edcbc Use "instanceof pattern matching" in sample in reference docs
Closes gh-28332
2022-04-13 12:16:10 +02:00
Sam Brannen
1574fed90b Merge branch '5.3.x' 2022-04-13 10:08:31 +02:00
Sam Brannen
a7cf19cec5 Improve documentation and matching algorithm in data binders 2022-04-13 09:55:40 +02:00
Sam Brannen
50973f73c7 Change link from 5.3.x to main
See gh-28228
2022-03-27 17:47:41 +02:00
Sam Brannen
e88a88cb7d Merge branch '5.3.x' 2022-03-27 17:46:39 +02:00
Sam Brannen
d927e37364 Add "Testing ORM entity lifecycle callbacks" note to Testing chapter
Closes gh-28228
2022-03-27 17:46:06 +02:00
Stephane Nicoll
defcaae6e4 Merge branch '5.3.x' 2022-03-27 10:05:47 +02:00
Stephane Nicoll
4b150fd451 Update copyright date in reference manual
Closes gh-28237
2022-03-27 09:59:12 +02:00
Brian Clozel
7161940b53 Merge branch '5.3.x' 2022-03-24 13:44:38 +01:00
Yanming Zhou
acf2955b96 Ban jetbrains annotations imports
Closes gh-28226
2022-03-24 13:31:36 +01:00
Sam Brannen
b570f60560 Merge branch '5.3.x'
# Conflicts:
#	spring-aop/src/main/java/org/springframework/aop/support/AopUtils.java
#	spring-aop/src/main/java/org/springframework/aop/support/annotation/AnnotationClassFilter.java
#	spring-aop/src/main/java/org/springframework/aop/support/annotation/AnnotationMatchingPointcut.java
#	spring-aop/src/main/java/org/springframework/aop/support/annotation/AnnotationMethodMatcher.java
#	spring-beans/src/main/java/org/springframework/beans/factory/annotation/RequiredAnnotationBeanPostProcessor.java
#	spring-context/src/main/java/org/springframework/context/annotation/CommonAnnotationBeanPostProcessor.java
#	spring-context/src/main/java/org/springframework/jmx/export/annotation/ManagedNotification.java
#	spring-context/src/main/java/org/springframework/jmx/export/annotation/ManagedOperationParameter.java
#	spring-core/src/main/java/org/springframework/javapoet/support/package-info.java
#	spring-core/src/main/java/org/springframework/util/TypeUtils.java
#	spring-web/src/main/java/org/springframework/http/HttpMethod.java
2022-03-18 16:47:12 +01:00
Sam Brannen
64b64d9ba0 Stop referring to features as "Java 5" features
With a Java 8 baseline in place for quite some time now, it no longer
makes sense to refer to features such as annotations as "Java 5
annotations".

This commit also removes old `Tiger*Tests` classes, thereby avoiding
duplicate execution of various tests.
2022-03-18 16:32:30 +01:00
Sam Brannen
9764f0e59b Merge branch '5.3.x'
# Conflicts:
#	spring-test/src/test/java/org/springframework/mock/http/server/reactive/MockServerHttpRequestTests.java
#	spring-web/src/test/java/org/springframework/http/server/reactive/HeadersAdaptersTests.java
#	spring-web/src/test/java/org/springframework/web/client/RestTemplateIntegrationTests.java
#	spring-webflux/src/test/java/org/springframework/web/reactive/function/client/WebClientIntegrationTests.java
#	spring-webflux/src/test/java/org/springframework/web/reactive/result/method/annotation/SseIntegrationTests.java
#	spring-webmvc/src/test/java/org/springframework/web/servlet/handler/MappedInterceptorTests.java
#	spring-webmvc/src/test/java/org/springframework/web/servlet/mvc/method/annotation/HandlerMethodAnnotationDetectionTests.java
#	spring-websocket/src/test/java/org/springframework/web/socket/AbstractWebSocketIntegrationTests.java
2022-03-16 15:07:53 +01:00
Sam Brannen
c462fe30ed Use Named arguments in parameterized tests 2022-03-16 14:45:47 +01:00
Sam Brannen
c249b578b5 Merge branch '5.3.x' 2022-03-12 16:05:39 +01:00
Sam Brannen
d9c22e657f Document the effect of @DirtiesContext on test execution events
See gh-27757
2022-03-12 16:05:14 +01:00
Sam Brannen
0e7c7b444c Merge branch '5.3.x' 2022-03-10 19:28:51 +01:00
Sam Brannen
af977c0891 Improve documentation for @EnabledIf and @DisabledIf test support
Closes gh-28157
2022-03-10 19:27:41 +01:00
Sam Brannen
5119aafe4f Merge branch '5.3.x' 2022-03-06 17:52:21 +01:00
Sam Brannen
a2f02dbfc0 Improve documentation for TestContext events
This commit improves the documentation for test execution events,
especially with regard to the fact that, by default, a
BeforeTestClassEvent is not published for the first test class using a
particular ApplicationContext.

This commit also introduces tests that verify the default behavior and
the ability to change the default behavior with a custom
TestExecutionListener that eagerly loads the context.

Closes gh-27757
2022-03-06 17:51:49 +01:00
Sam Brannen
f7d49e3957 Merge branch '5.3.x' 2022-03-05 14:54:19 +01:00
Sam Brannen
8cbb188455 Fix links to Spring Security in the reference guide
Closes gh-28135
2022-03-05 14:53:52 +01:00
Sam Brannen
bc973d7001 Fix broken link to "CORS WebFilter" in ref docs 2022-03-05 14:36:52 +01:00
Sam Brannen
c1033dbfb3 Support type-safe transaction rollback rules
Prior to this commit, there was no way to configure type-safe rollback
rules for transactions.

Even though a rollback rule could be defined using a Class reference
via the `rollbackFor` and `noRollbackFor` attributes in @Transactional,
those Class references got converted to Strings (as the fully qualified
class names of the exception types) in RollbackRuleAttribute which then
applied a pattern-based matching algorithm as if the Class references
had been supplied as Strings/patterns to begin with, thereby losing the
type information.

Pattern-based rollback rules suffer from the following three categories
of unintentional matches.

- identically named exceptions in different packages when the pattern
  does not include the package name -- for example,
  example.client.WebException and example.server.WebException both
  match against a "WebException" pattern.

- similarly named exceptions in the same package when a given exception
  name starts with the name of another exception -- for example,
  example.BusinessException and example.BusinessExceptionWithDetails
  both match against an "example.BusinessException" pattern.

- nested exceptions when an exception type is declared in another
  exception -- for example, example.BusinessException and
  example.BusinessException$NestedException both match against an
  "example.BusinessException" pattern.

This commit prevents the latter two categories of unintentional matches
for rollback rules defined using a Class reference by storing the
exceptionType in RollbackRuleAttribute and using that type in the
implementation of RollbackRuleAttribute.getDepth(Class, int), resulting
in type-safe rollback rules whenever the `rollbackFor` and
`noRollbackFor` attributes in `@Transactional` are used.

Note that the first category of unintentional matches never applied to
rollback rules created from a Class reference since the fully qualified
name of a Class reference always includes the package name.

Closes gh-28098
2022-03-04 19:33:39 +01:00
Sam Brannen
9cb4783296 Merge branch '5.3.x'
# Conflicts:
#	spring-tx/src/main/java/org/springframework/transaction/annotation/Transactional.java
#	spring-tx/src/main/java/org/springframework/transaction/interceptor/RollbackRuleAttribute.java
2022-03-04 16:51:26 +01:00
Sam Brannen
fa3130d716 Document that TX rollback rules may result in unintentional matches
Closes gh-28125
2022-03-04 16:39:11 +01:00
Stephane Nicoll
453c6d41f7 Fix Objenesis version
See gh-28100
2022-02-24 10:54:52 +01:00
izeye
a28b49ac27 Fix library name for JavaPoet in src/docs/dist/license.txt
This commit also updates Objenesis version in the file to align with the
version that Spring Framework is using.

See gh-28100
2022-02-24 10:51:54 +01:00
Stephane Nicoll
dfae8effa8 Repackage Javapoet in org.springframework.javapoet
This commit repackages the Javapoet library into spring-core so that it
can be used by the AOT engine without requiring a specific version.

Closes gh-27828
2022-02-10 14:56:36 +01:00