Sam Brannen
37e6fe5b64
Update copyright headers
1 year ago
Stéphane Nicoll
cf10cee16a
Polish
1 year ago
Brian Clozel
dab7e03c93
Polish
...
See gh-28041
1 year ago
Chen Jianbin
4bf995fa8b
Support "*" mapping in MockMvc filter registration
...
Prior to this commit, configuring a Servlet filter in MockMvc with a
defined mapping would only consider "/*" as a catch-all pattern.
This commit relaxes this rule by also accepting "*" mappings.
Closes gh-28041
1 year ago
Brian Clozel
31a62ff8ba
Add JMH benchmarks for Protobuf message converter
...
This commit re-generates the protobuf Java classes with a recent version
of the protoc binary and adds JMH benchmarks that exercise the message
converter for both the reading and writing cases.
See gh-29496
1 year ago
Brian Clozel
631a5d1dc1
Remove support for Protobuf 2.x and protobuf-java-format
...
Closes gh-31465
1 year ago
rstoyanchev
7271dfed68
Use CopyOnWriteArrayList for beforeCommit actions
...
Closes gh-27587
1 year ago
rstoyanchev
a2f2f7c348
Use correct RequestParam resolver
...
Closes gh-31329
1 year ago
Sébastien Deleuze
c1437f9817
Refine CRaC restoration logs
...
Closes gh-31462
1 year ago
Brian Clozel
daaccce918
Merge branch '6.0.x'
1 year ago
Brian Clozel
6ec264252b
Ensure consistent value count in ConcurrentReferenceHashMap#Segment
...
Prior to this commit, the `ConcurrentReferenceHashMap#Segment` would
recalculate its element count during the restructure phase by
subtracting the number of polled elements from the queue to the current
count.
Later, the newly restructured `references` array would only contain
references that 1) are not in the set of elements to purge and
2) that hold a non-null value.
The issues with this approach are multiple. The newly calculated count
is only an estimate, as some situations can make it invalid, even
temporarily.
* since we initially collected all elements to be purged from the queue,
the GC might have collected new values. This means that we might
filter out more references that we initially intended to
* because the restructure operation re-creates new references for all
elements in the original array, we might later get references from the
queue that are not in the array anymore. This could lead to
"duplicate" removals for the same value
Because several methods in the Segment class have special no-op behavior
when `count == 0`, an invalid count can lead to keys appearing missing
when they are actually still present. In some scenarios, this can
decrease the performance of the cache since values need to be
recalculated.
This commit fixes this inconsistency count issue by first using an
estimate in order to decide whether the array needs a resize and then by
counting the actual numbers of elements inserted in the restructured
array as the new count.
Fixes gh-31373
1 year ago
Brian Clozel
c73c16f07f
Configure JDK 22 compatibility build on CI
...
This commit does not enable this build right now as testing libraries
are not ready yet for JDK 22.
See gh-31459
1 year ago
Sébastien Deleuze
c6b86af78b
Fall back on UTF-8 charset in WebClientResponseException
...
Instead of ISO-8859-1, consistently with the change done
in RestClientResponseException.
Closes gh-31072
1 year ago
Brian Clozel
9eac9a1831
Upgrade CI to JDK 21.0.1+12
1 year ago
Brian Clozel
0a10c1ffa0
Merge branch '6.0.x'
1 year ago
Brian Clozel
187b4e5ea6
Upgrade CI image to ubuntu:jammy-20231004
1 year ago
Brian Clozel
3bc607df53
Upgrade CI to JDK 17.0.9
1 year ago
Misagh Moayyed
1e7e532ed6
Fix typos in SubstituteOnlyIfPresent Javadoc
...
Closes gh-31455
1 year ago
Sébastien Deleuze
fa57598327
Refine BeanFactory extensions to avoid type erasure when possible
...
Closes gh-31439
1 year ago
Sébastien Deleuze
a9d67878c5
Introduce conditional activation of Hibernate substitutions
...
Closes gh-31452
1 year ago
Stéphane Nicoll
9af239c8be
Clean resources in case of unexpected exception
...
This commit updates AbstractApplicationContext#refresh to handle any
exceptions, not only BeansExceptions.
Closes gh-28878
1 year ago
Stéphane Nicoll
46cc75b3f1
Merge branch '6.0.x'
1 year ago
Stéphane Nicoll
69c92f9ac7
Document when to use multiple property placeholder configurers
...
This commit adds a warning in the reference guide to address the
use cases where users might be tempted to use several property
placeholder configurers.
Closes gh-14623
1 year ago
rstoyanchev
a53d3f3cea
Apply DisconnectedClientHelper to @ExceptionHandler methods
...
Use the helper to reduce logging when an @ExceptionHandler fails
to write to the response due to a network failure where the client
has gone away.
Closes gh-26181
1 year ago
rstoyanchev
a8019f2d0b
Create reusable DisconnectedClientHelper
...
See gh-26181
1 year ago
Stéphane Nicoll
49ff96dd0b
Merge pull request #31368 from izeye
...
* pr/31368:
Polish "Order modifiers to align with JLS"
Order modifiers to align with JLS
Closes gh-31368
1 year ago
Stéphane Nicoll
5c6232e681
Polish "Order modifiers to align with JLS"
...
See gh-31368
1 year ago
Johnny Lim
919faa2ce2
Order modifiers to align with JLS
...
This commit also applies Checkstyle ModifierOrder to enforce it.
See gh-31368
1 year ago
Stéphane Nicoll
f60791a8e2
Merge pull request #31445 from izeye
...
* pr/31445:
Polish "Enable checkstyle in buildSrc"
Enable checkstyle in buildSrc
Closes gh-31445
1 year ago
Stéphane Nicoll
27431b5138
Polish "Enable checkstyle in buildSrc"
...
See gh-31445
1 year ago
Johnny Lim
e95ba4c205
Enable checkstyle in buildSrc
...
See gh-31445
1 year ago
Stéphane Nicoll
73a5229b03
Polish
1 year ago
Stéphane Nicoll
370c8e0b9e
Do not enable spring javaformat plugin
...
We do not use the plugin, but rather apply some checkstyle rules that
should be available on the classpath.
Closes gh-31448
1 year ago
Stéphane Nicoll
4fd1431cea
Restructure test to use Nested more consistently
1 year ago
Sébastien Deleuze
669c723ae0
Merge branch '6.0.x'
1 year ago
Sébastien Deleuze
875eeabb6f
Add a properties setter to ProblemDetail
...
Mainly to allow Kotlin idiomatic properties assignment.
Closes gh-31430
1 year ago
Stéphane Nicoll
6efc99fdd8
Harmonize BeanRegistrationAotContribution class names
1 year ago
Stéphane Nicoll
9465ff0334
Add support for merging two BeanRegistrationAotContribution instances
...
Closes gh-31446
1 year ago
Sébastien Deleuze
22db1ac146
Add Coroutines support for `@EventListener`
...
Closes gh-28343
1 year ago
Brian Clozel
33deaff108
Move performance test to JMH benchmark
...
This commit removes an ignored performance test in the
`ConcurrentReferenceHashMap` test suite and converts it to a JMH
benchmark.
1 year ago
Sam Brannen
1fb2a37957
Apply @DisabledInAotMode for @EJB and SpEL usage
...
Most of the remaining failures are due to @Resource usage.
Current AOT test results for the spring-test module:
Test run finished after 6140 ms
[ 399 containers found ]
[ 64 containers skipped ]
[ 335 containers started ]
[ 0 containers aborted ]
[ 333 containers successful ]
[ 2 containers failed ]
[ 745 tests found ]
[ 116 tests skipped ]
[ 628 tests started ]
[ 1 tests aborted ]
[ 589 tests successful ]
[ 38 tests failed ]
Failing Test Classes:
org.springframework.test.context.groovy.AbsolutePathGroovySpringContextTests
org.springframework.test.context.groovy.GroovySpringContextTests
org.springframework.test.context.groovy.RelativePathGroovySpringContextTests
org.springframework.test.context.jdbc.BeforeTestClassSqlScriptsTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$ConfigOverriddenByDefaultTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$InheritedAndExtendedConfigTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$InheritedAndExtendedConfigTests$DoubleNestedWithOverriddenConfigTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$InheritedAndExtendedConfigTests$DoubleNestedWithOverriddenConfigTests$TripleNestedWithInheritedConfigAndTestInterfaceTests
org.springframework.test.context.junit.jupiter.orm.JpaEntityListenerTests
org.springframework.test.context.junit4.AbsolutePathSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.ClassPathResourceSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.ConcreteTransactionalJUnit4SpringContextTests
org.springframework.test.context.junit4.InheritedConfigSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.MultipleResourcesSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.ParameterizedDependencyInjectionTests
org.springframework.test.context.junit4.RelativePathSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.SpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.annotation.AnnotationConfigSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.spr9799.Spr9799XmlConfigTests
org.springframework.test.context.testng.ConcreteTransactionalTestNGSpringContextTests
See gh-29122
1 year ago
Sam Brannen
88cd0700b2
Filter out TestNG @EJB tests in AOT end-to-end tests
...
See gh-29122
1 year ago
Sam Brannen
9cac5eeeab
Consistently use generated name in embedded databases
...
... to avoid database name conflicts when test classes are executed in
a different order.
See gh-29122
1 year ago
Sam Brannen
0adec6d15a
Apply @DisabledInAotMode to remaining @ContextHierarchy integration tests
...
See gh-29122
1 year ago
Sam Brannen
bb95f2e5ca
Apply @DisabledInAotMode to @ContextHierarchy integration tests
...
This commit applies @DisabledInAotMode to all integration test classes
in the spring-test module that use @ContextHierarchy since that
feature is not supported for AOT optimizations.
Current AOT test results for the spring-test module:
Test run finished after 6888 ms
[ 403 containers found ]
[ 57 containers skipped ]
[ 346 containers started ]
[ 0 containers aborted ]
[ 338 containers successful ]
[ 8 containers failed ]
[ 757 tests found ]
[ 98 tests skipped ]
[ 654 tests started ]
[ 9 tests aborted ]
[ 576 tests successful ]
[ 69 tests failed ]
Failing Test Classes:
org.springframework.test.context.configuration.interfaces.SqlConfigInterfaceTests
org.springframework.test.context.expression.ExpressionUsageTests
org.springframework.test.context.groovy.AbsolutePathGroovySpringContextTests
org.springframework.test.context.groovy.GroovySpringContextTests
org.springframework.test.context.groovy.RelativePathGroovySpringContextTests
org.springframework.test.context.hierarchies.meta.MetaHierarchyLevelTwoTests
org.springframework.test.context.hierarchies.standard.TestHierarchyLevelTwoWithBareContextConfigurationInSubclassTests
org.springframework.test.context.jdbc.CustomScriptSyntaxSqlScriptsTests
org.springframework.test.context.jdbc.GlobalCustomScriptSyntaxSqlScriptsTests
org.springframework.test.context.jdbc.InferredDataSourceTransactionalSqlScriptsTests
org.springframework.test.context.jdbc.InfrastructureProxyTransactionalSqlScriptsTests
org.springframework.test.context.jdbc.MultipleDataSourcesAndTransactionManagersSqlScriptsTests
org.springframework.test.context.jdbc.MultipleDataSourcesAndTransactionManagersTransactionalSqlScriptsTests
org.springframework.test.context.jdbc.NonTransactionalSqlScriptsTests
org.springframework.test.context.jdbc.RepeatableSqlAnnotationSqlScriptsChildTests
org.springframework.test.context.jdbc.RepeatableSqlAnnotationSqlScriptsParentTests
org.springframework.test.context.jdbc.TransactionalAfterTestMethodSqlScriptsTests
org.springframework.test.context.jdbc.TransactionalInlinedStatementsSqlScriptsTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$ConfigOverriddenByDefaultTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$InheritedAndExtendedConfigTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$InheritedAndExtendedConfigTests$DoubleNestedWithOverriddenConfigTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$InheritedAndExtendedConfigTests$DoubleNestedWithOverriddenConfigTests$TripleNestedWithInheritedConfigAndTestInterfaceTests
org.springframework.test.context.junit.jupiter.orm.JpaEntityListenerTests
org.springframework.test.context.junit4.AbsolutePathSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.ClassPathResourceSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.ConcreteTransactionalJUnit4SpringContextTests
org.springframework.test.context.junit4.InheritedConfigSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.MultipleResourcesSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.ParameterizedDependencyInjectionTests
org.springframework.test.context.junit4.RelativePathSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.SpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.annotation.AnnotationConfigSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.rules.TransactionalSqlScriptsSpringRuleTests
org.springframework.test.context.junit4.spr9799.Spr9799XmlConfigTests
org.springframework.test.context.testng.ConcreteTransactionalTestNGSpringContextTests
org.springframework.test.context.testng.transaction.ejb.CommitForRequiredEjbTxDaoTestNGTests
org.springframework.test.context.testng.transaction.ejb.CommitForRequiresNewEjbTxDaoTestNGTests
org.springframework.test.context.testng.transaction.ejb.RollbackForRequiredEjbTxDaoTestNGTests
org.springframework.test.context.testng.transaction.ejb.RollbackForRequiresNewEjbTxDaoTestNGTests
org.springframework.test.context.transaction.ejb.CommitForRequiredEjbTxDaoTests
org.springframework.test.context.transaction.ejb.CommitForRequiresNewEjbTxDaoTests
org.springframework.test.context.transaction.ejb.RollbackForRequiredEjbTxDaoTests
org.springframework.test.context.transaction.ejb.RollbackForRequiresNewEjbTxDaoTests
See gh-29122
1 year ago
Sam Brannen
44931dca44
Include all failing test classes in AOT end-to-end test report
...
Prior to this commit, AotIntegrationTests only printed "failing test
classes" for tests that failed at the class level.
This commit updates the reporting logic to report test classes for
failing test methods as well.
Current results for the spring-test module:
Test run finished after 6531 ms
[ 403 containers found ]
[ 27 containers skipped ]
[ 376 containers started ]
[ 0 containers aborted ]
[ 366 containers successful ]
[ 10 containers failed ]
[ 757 tests found ]
[ 61 tests skipped ]
[ 689 tests started ]
[ 9 tests aborted ]
[ 585 tests successful ]
[ 95 tests failed ]
Failing Test Classes:
org.springframework.test.context.configuration.interfaces.ContextHierarchyInterfaceTests
org.springframework.test.context.configuration.interfaces.SqlConfigInterfaceTests
org.springframework.test.context.expression.ExpressionUsageTests
org.springframework.test.context.groovy.AbsolutePathGroovySpringContextTests
org.springframework.test.context.groovy.GroovySpringContextTests
org.springframework.test.context.groovy.RelativePathGroovySpringContextTests
org.springframework.test.context.hierarchies.meta.MetaHierarchyLevelTwoTests
org.springframework.test.context.hierarchies.standard.ClassHierarchyWithMergedConfigLevelOneTests
org.springframework.test.context.hierarchies.standard.ClassHierarchyWithMergedConfigLevelTwoTests
org.springframework.test.context.hierarchies.standard.ClassHierarchyWithOverriddenConfigLevelTwoTests
org.springframework.test.context.hierarchies.standard.DirtiesContextWithContextHierarchyTests
org.springframework.test.context.hierarchies.standard.SingleTestClassWithTwoLevelContextHierarchyAndMixedConfigTypesTests
org.springframework.test.context.hierarchies.standard.SingleTestClassWithTwoLevelContextHierarchyTests
org.springframework.test.context.hierarchies.standard.TestHierarchyLevelTwoWithBareContextConfigurationInSubclassTests
org.springframework.test.context.hierarchies.standard.TestHierarchyLevelTwoWithBareContextConfigurationInSuperclassTests
org.springframework.test.context.hierarchies.standard.TestHierarchyLevelTwoWithSingleLevelContextHierarchyAndMixedConfigTypesTests
org.springframework.test.context.hierarchies.standard.TestHierarchyLevelTwoWithSingleLevelContextHierarchyTests
org.springframework.test.context.hierarchies.web.ControllerIntegrationTests
org.springframework.test.context.hierarchies.web.DispatcherWacRootWacEarTests
org.springframework.test.context.hierarchies.web.RootWacEarTests
org.springframework.test.context.jdbc.CustomScriptSyntaxSqlScriptsTests
org.springframework.test.context.jdbc.GlobalCustomScriptSyntaxSqlScriptsTests
org.springframework.test.context.jdbc.InferredDataSourceTransactionalSqlScriptsTests
org.springframework.test.context.jdbc.InfrastructureProxyTransactionalSqlScriptsTests
org.springframework.test.context.jdbc.MultipleDataSourcesAndTransactionManagersSqlScriptsTests
org.springframework.test.context.jdbc.MultipleDataSourcesAndTransactionManagersTransactionalSqlScriptsTests
org.springframework.test.context.jdbc.NonTransactionalSqlScriptsTests
org.springframework.test.context.jdbc.RepeatableSqlAnnotationSqlScriptsChildTests
org.springframework.test.context.jdbc.RepeatableSqlAnnotationSqlScriptsParentTests
org.springframework.test.context.jdbc.TransactionalAfterTestMethodSqlScriptsTests
org.springframework.test.context.jdbc.TransactionalInlinedStatementsSqlScriptsTests
org.springframework.test.context.junit.jupiter.nested.ContextHierarchyNestedTests$NestedTestCaseWithInheritedConfigTests
org.springframework.test.context.junit.jupiter.nested.ContextHierarchyNestedTests$NestedTestCaseWithInheritedConfigTests$DoubleNestedTestCaseWithOverriddenConfigTests
org.springframework.test.context.junit.jupiter.nested.ContextHierarchyNestedTests$NestedTestCaseWithInheritedConfigTests$DoubleNestedTestCaseWithOverriddenConfigTests$TripleNestedWithInheritedConfigAndTestInterfaceTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$ConfigOverriddenByDefaultTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$InheritedAndExtendedConfigTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$InheritedAndExtendedConfigTests$DoubleNestedWithOverriddenConfigTests
org.springframework.test.context.junit.jupiter.nested.TestExecutionListenersNestedTests$InheritedAndExtendedConfigTests$DoubleNestedWithOverriddenConfigTests$TripleNestedWithInheritedConfigAndTestInterfaceTests
org.springframework.test.context.junit.jupiter.orm.JpaEntityListenerTests
org.springframework.test.context.junit4.AbsolutePathSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.ClassPathResourceSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.ConcreteTransactionalJUnit4SpringContextTests
org.springframework.test.context.junit4.InheritedConfigSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.MultipleResourcesSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.ParameterizedDependencyInjectionTests
org.springframework.test.context.junit4.RelativePathSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.SpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.annotation.AnnotationConfigSpringJUnit4ClassRunnerAppCtxTests
org.springframework.test.context.junit4.rules.TransactionalSqlScriptsSpringRuleTests
org.springframework.test.context.junit4.spr9799.Spr9799XmlConfigTests
org.springframework.test.context.testng.ConcreteTransactionalTestNGSpringContextTests
org.springframework.test.context.testng.transaction.ejb.CommitForRequiredEjbTxDaoTestNGTests
org.springframework.test.context.testng.transaction.ejb.CommitForRequiresNewEjbTxDaoTestNGTests
org.springframework.test.context.testng.transaction.ejb.RollbackForRequiredEjbTxDaoTestNGTests
org.springframework.test.context.testng.transaction.ejb.RollbackForRequiresNewEjbTxDaoTestNGTests
org.springframework.test.context.transaction.ejb.CommitForRequiredEjbTxDaoTests
org.springframework.test.context.transaction.ejb.CommitForRequiresNewEjbTxDaoTests
org.springframework.test.context.transaction.ejb.RollbackForRequiredEjbTxDaoTests
org.springframework.test.context.transaction.ejb.RollbackForRequiresNewEjbTxDaoTests
org.springframework.test.web.servlet.samples.client.context.JavaConfigTests
org.springframework.test.web.servlet.samples.client.context.WebAppResourceTests
org.springframework.test.web.servlet.samples.client.context.XmlConfigTests
org.springframework.test.web.servlet.samples.context.JavaConfigTests
org.springframework.test.web.servlet.samples.context.WebAppResourceTests
org.springframework.test.web.servlet.samples.context.XmlConfigTests
See gh-29122
1 year ago
Sam Brannen
32b4f55d92
Update copyright headers
1 year ago
Sam Brannen
119a9ffc3e
Rename test class to NestedTests for AOT integration testing
...
Prior to this commit, the NestedTestCase resulted in errors during our
AOT end-to-end integration tests since it did not comply to our "*Tests"
naming convention.
See gh-29122
1 year ago
Sam Brannen
66e3a7a25c
Apply @DisabledInAotMode to appropriate test classes
...
This commit applies @DisabledInAotMode to test classes in the
spring-test module that will never be able to be processed for AOT
optimizations.
Test classes that fail for reasons that can potentially be addressed in
a future version of the framework have not been annotated with
@DisabledInAotMode.
See gh-29122
1 year ago
Sam Brannen
991afe0939
Fix formatting for @DisabledInAotMode error messages
...
See gh-30834
1 year ago