Releases: spring-projects/spring-framework
v6.0.2
β New Features
- Rely on standard parameter name resolution in Bean Validation 3.0 #29566
π Bug Fixes
- ResponseStatusException does not use the reason to set the "detail" field #29567
- LocalVariableTableParameterNameDiscoverer logs many warnings with Hibernate validation #29563
π Documentation
- org.springframework.web.multipart.commons not found #29562
v6.0.1
β New Features
- Make
SourceHttpMessageConverter
optional #29535 - Deprecate
LocalVariableTableParameterNameDiscoverer
completely (avoiding its exposure in native images) #29531 - Make GeneratorStrategy.generate unreachable on native #29521
- Update
LogAdapter
to allow build-time code removal #29506
π Bug Fixes
- Unhandled exceptions should mark Servlet observation outcome as error #29512
π Documentation
- Broken link in documentation section 6.10 #29554
- Fix Javadoc link text in BindingResult #29551
- Fix some typos in Kotlin WebClient example code #29538
- Fix link to Bean Utils Light Library in BeanUtils Javadoc #29534
- Fix link to WebFlux section in reference manual #29525
- Document RuntimeHints testing strategies #29523
- Reorganize and modularize the Testing chapter in the reference manual #29522
- Document switch to
SQLExceptionSubclassTranslator
in the upgrade guide #29518 - Update documentation to mention Java 17+ baseline #29514
- Link to Spring WebFlux section is broken #29513
- Update javadoc of Jackson-based decoders to reflect 2.14 baseline #29508
- Code example has callout from a different code example #29505
- Code listing callouts are displayed incorrectly in core-beans.adoc #29457
- Fix a syntax error in an XML listing in core-validation.adoc #29456
π¨ Dependency Upgrades
β€οΈ Contributors
Thank you to all the contributors who worked on this release:
@Encyclopedias, @andregasser, @davidcostanzo, @divcon, @jiangying000, @mdeinum, and @wilkinsona
v6.0.0
See What's New in Spring Framework 6.x and Upgrading to Spring Framework 6.x for upgrade instructions and details of new features.
β New Features
- Avoid direct URL construction and URL equality checks #29486
- Simplify creating RFC 7807 responses from functional endpoints #29462
- Allow test classes to provide runtime hints via declarative mechanisms #29455
π Documentation
- Align javadoc of DefaultParameterNameDiscoverer with its behavior #29494
- Document AOT support in the TestContext framework #29482
- Document Ahead of Time processing in the reference guide #29350
π¨ Dependency Upgrades
- Upgrade to Reactor 2022.0.0 #29465
β€οΈ Contributors
Thank you to all the contributors who worked on this release:
@ophiuhus and @wilkinsona
v5.3.24
β New Features
- Avoid reflection for annotation method invocations #29448
- Avoid unnecessary allocations in StompDecoder#unescape #29443
- Avoid String allocations in MediaType.checkParameters #29428
- Reduce allocations caused by producible media types #29412
- Provide optional SimpleBeanInfoFactory for better introspection performance in 5.3.x #29330
- Filter out
null
WebSocket session attributes #29315 - Introduce TestSocketUtils as a replacement for SocketUtils #29132
- Avoid Commons Logging API for using LoggingCacheErrorHandler with a custom logger #28678
π Bug Fixes
- Missing SessionFactory property (filter AutoCloseable from PropertyDescriptors) #29480
- SpEL ternary and Elvis expressions are missing enclosing parentheses in toStringAST() #29463
- If-Unmodified-Since header check removes Last-Modified and Etag headers from response, even if condition passes #29362
- Annotation searches fail for non-public repeatable annotations #29301
- AbstractBeanFactory's interaction with BeanPostProcessorCacheAwareList is not fully thread-safe #29299
- WebTestClient cannot assert custom HTTP status code #29283
- Body token not expected error when trying to upload a large multipart file #29227
- Avoid resizing of Maps created by CollectionUtils #29190
- DefaultWebClient logging sensitive information in URI #29148
- Fix SimpleMailMessage nullability annotations #29139
- Webflux fails to apply the rule for controller methods returning void to kotlin suspend functions returning Unit #27629
- Resource.isFile() return true when the resource path actually not exists #26707
- AnnotatedElementUtils does not find merged repeatable annotations on other repeatable annotations #20279
π Documentation
- Fix two typos in integration.adoc and webflux.adoc #29469
- Fix typo: "as describe in" -> "as described in" #29393
- Fix typos #29364
- Correct documentation for "other return values" from a web controller method #29349
- Document how to use WebJars without
webjars-locator-core
dependency #29322 - Update RestTemplate Javadoc with regards to setting interceptors on startup vs at runtime #29311
- Document how to switch to the default set of TestExecutionListeners #29281
- Document limitation of AopTestUtils.getUltimateTargetObject() regarding non-static TargetSource #29276
- Fix typo in WebSocket reference doc regarding subscription header #29228
- Fix MockMvc sample setup #29201
π¨ Dependency Upgrades
- Upgrade to Reactor 2020.0.25 #29464
β€οΈ Contributors
We'd like to thank all the contributors who worked on this release!
v6.0.0-RC4
β New Features
- Introduce DataFieldMaxValueIncrementer for SQL Server sequences #29447
- Introduce findAllAnnotationsOnBean variant on ListableBeanFactory #29446
- Introduce support for Jakarta WebSocket 2.1 #29436
- Allow
@ControllerAdvice
in WebFlux to handle exceptions before a handler is selected #22991
π Bug Fixes
- Bean with unresolved generics do not use fallback algorithms with AOT #29454
- TomcatRequestUpgradeStrategy is not compatible with Tomcat 10.1 #29434
- Autowiring of a generic type produced by a factory bean fails after AOT processing #29385
π Documentation
- Reference PDF containing full docs not available #28451
π¨ Dependency Upgrades
- Revisit Servlet API baseline: Servlet 6.0 in the build, Servlet 5.0 compatibility at runtime #29435
- Upgrade to Context Propagation 1.0.0 #29442
- Upgrade to Jackson 2.14.0 #29351
- Upgrade to Micrometer 1.10.0 #29441
β€οΈ Contributors
Thank you to all the contributors who worked on this release:
@divcon, @fmbenhassine, @imkulwant, @izeye, and @wilkinsona
v6.0.0-RC3
β New Features
- Support
@RequestPart
arguments for@HttpExchange
methods #29420 - Processing of charset in Content-Type Header not case-insensitive #29416
- Allow for external customization and i8n of the "title" of an RFC 7807 response #29407
- Automatically register directories for registered resource hints #29403
- Allow registration of resource hint for root directory #29402
- Load
ApplicationContextFailureProcessor
implementations fromspring.factories
#29387 - Simplify mapping of custom exception to an RFC 7807 response in ResponseEntityExceptionHandler #29384
- Introduce SimpleValueStyler for use with ToStringCreator #29381
- Make DefaultValueStyler extensible #29380
- Introduce DataFieldMaxValueIncrementer for MariaDB #29379
- Handle case where
ResponseEntity
andProblemDetail
don't agree on the HTTP status to use #29378 - Provide AOT support for
HttpServiceProxyFactory
clients #29271 - Revise logging in the TestContext framework #29229
π Bug Fixes
- Align server observation contextual names with OTel semantic conventions #29424
- Matching path pattern is not set in reactive ServerRequestObservationContext #29422
- PartEvent upload fails with JdkClientHttpConnector #29400
- Native image FileSystem should not be closed after classpath scanning #29397
- AOT processing loses bean aliases #29391
- WebClient and WebFlux Observation do not propagate context #29388
- HttpServiceProxyFactory raises IllegalStateException if created through the builder and declared as a bean #29376
- Multiple
@ImportRuntimeHints
in the type hierarchy should be supported #29361
π¨ Dependency Upgrades
- Upgrade to Jackson 2.14.0-rc3 #29405
β€οΈ Contributors
Thank you to all the contributors who worked on this release:
v6.0.0-RC2
β New Features
- Ensure classpath checks can be evaluated at build-time #29352
- Register reflection hints for JPA persistence callbacks #29348
- Check
@RegisterReflectionForBinding
specifies at least one class #29346 - Introduce builder API for AOT processor Settings #29341
- Allow in-progress AOT processing to be detected #29340
- Reorganize HTTP Observation types #29334
- Perform basic property determination without java.beans.Introspector #29320
- Add Kotlin data class components support to
BindingReflectionHintsRegistrar
#29316 - Switch HttpServiceFactory and RSocketServiceProxyFactory to builder model for programmatic configuration first #29296
- Introduce
PreComputeFieldFeature
based on GraalVMFieldValueTransformer
API #29081 - Introduce SPI for processing ApplicationContext failures in the TestContext framework #28826
- SimpleEvaluationContext should disable array allocation #28808
- DateTimeFormatterRegistrar should fall back to ISO parsing by default #26985
π Bug Fixes
- Avoid NPEs in DefaultServerRequestObservationConvention #29359
- ServerHttpObservationFilter can throw ClassCastException when NoopObservation used #29356
- ServerHttpObservationFilter should not overwrite response status #29353
- Possible regression in PathMatchingResourcePatternResolver #29333
- Jackson
Decoder
ignores method parameter information when resolving media types for customObjectMapper
registration #29307 - Deprecation warning for composed Bean Validation constraint annotation #29206
- Code generation no longer supports a list of inner BeanDefinitions #29075
- NamedParameterUtils has broken square brackets handling #27925
π Documentation
- Refine
@RegisterReflectionForBinding
Javadoc #29345 - Mention
@ImportRuntimeHints
inRuntimeHintsRegistrar
Javadoc #29337 - Add Javadoc since for SimpleInstantiationStrategy.setCurrentlyInvokedFactoryMethod() #29326
- Use correct RFC number for ProblemDetail support in Javadoc #29302
π¨ Dependency Upgrades
β€οΈ Contributors
We'd like to thank all the contributors who worked on this release!
v6.0.0-RC1
β New Features
- Add native support for ExceptionHandler and ProblemDetail #29297
- Refine SQLErrorCodesFactory reachability on native images #29294
- Refine
BindingReflectionHintsRegistrar
infrastructure #29279 - Normalize URIs returned from FileSystemResource.getURI() #29275
- Redesign AOT Processors #29266
- Simplify TestRuntimeHintsRegistrar API #29264
- UrlResource#getFilename() should return unencoded file name #29261
- Add reflection hints for EmbeddedDatabaseFactory$EmbeddedDataSourceProxy#shutdown #29259
- Change keyvalue name to http.url in server observations #29254
- Code generator should not use reflection for protected artifacts #29253
- Use MethodArgumentNotValidException for model attribute arguments #29251
- Allow TestCompiler SourceFile to work with records #29236
- Generate matching inner class for inner class configuration #29213
- Kotlin functional config DSL should prevent beans to be registered twice in AOT-optimized contexts #29211
- Allow BeanRegistration target to be any arbitrary class name #29207
- Add support for
Charset
to value code generator #29186 - Enable HTTP and HTTPS on native in spring-web module #29185
- Optimize native footprint by avoiding using
ModuleFinder.ofSystem()
at runtime #29183 - Introduce AotProcessor to invoke the AOT engine on an application #29181
- Move TestCompiler to dedicated package #29175
- Use java.nio and FileSystems to resolve files in PathMatchingResourcePatternResolver #29163
- Replace ApplicationContextAotInitializer with an AotApplicationContextInitializer interface #29157
- Enable default TestExecutionListeners in JUnit 4 and TestNG base test classes #29149
- Support cglib generated classes with TestCompiler #29141
- Infer AOT proxies created by ProxyFactoryBean #29097
- HTTP interface client ignores
@DateTimeFormat
on path variable #29095 - Integrate the Micrometer Context Propagation library #29056
- Upgrade RestTemplate to HttpClient 5 #28925
- Improve resource handling for empty files contained in jars #28850
- Allow for external customization and i8n of the "detail" of an RFC 7807 response #28814
- Revise
CookieLocaleResolver
to useResponseCookie
#28779 - Optimize SpEL and property placeholder support for
@Async
qualifiers #28549 - Customization for ObjectReader and ObjectWriter #28401
- Improve exception message if MultipartParser can not find end of body #28067
- Revisit AOT constructor and factory method resolution #27920
- Support CBOR and Protobuf with Kotlin Serialization #27628
- CGLIB does not allow packages to start with "java" #27622
- Support comma-delimited list of origin patterns in
@CrossOrigin
#27606 - Improve the fluency of the ResponseCreator API #27280
- Support for problem details based on RFC 7807 #27052
- Add fast-path for no-args constructor in BeanUtils.instantiateClass #24104
- Resolve generic type in more complex scenarios #23418
π Bug Fixes
- Hints for CGLIB proxies are not consistently registered #29295
- Ensure context caching works properly during AOT runtime in the TestContext framework #29289
AbstractJackson2Encoder
encodes empty Flux to invalid JSON #29274- RuntimeHints accessors have inconsistent naming #29269
- ClassPathResources with same absolute path and same ClassLoader should be equal #29263
- HTTP URL KeyValue should provide entire request URL as a value #29257
- Hints for cglib configuration classes are not registered with a valid name #29252
- Add
ConstantReadableJavaField
caching inConstantFieldSubstitutionProcessor
#29250 - StringUtils should parse locale strings without country but with variant #29248
- Generated code does not take visibility of method if it is defined in a parent class #29245
- RestTemplate Observation is started without a complete tracing context #29234
- Fix Outcome KeyValues in HTTP observations #29232
- HTTP ObservationConvention implementations miss contextualName #29231
- Refine
ConstantFieldSubstitutionProcessor
error handling #29219 - Align RuntimeHintsAgent behavior with GraalVM reflection changes #29205
- Class meta-annotated with
@Reflective
and annotated with@RegisterReflectionForBinding
is only processed by SimpleReflectiveProcessor #29193 - Spring Web 6.0.0-M6 breaks Kotlin support for (De-)Serialization in some edge-cases #29192
- BeanDefinitionMethodGenerator should not generate code in the javax package name #29123
- CGLIB proxies are not used at runtime on
@Configuration
classes in AOT mode #29107 - Remove call to requestCompleted in RequestMappingHandlerAdapter #29002
π Documentation
- Document
PartEvent
API #29170 - Switch to spring-asciidoctor-backends #29162
- Improve Javadoc of BeanRegistrationAotProcessor to describe the "runtime replacement use case" #29126
- Improve Javadoc of GeneratedMethods#add to describe naming conventions #28997
π¨ Dependency Upgrades
v6.0.0-M6
β New Features
- Add HandshakeWebSocketService runtime hints #29146
- Add className variants in ReflectionHintsPredicates for checking fields and methods #29143
- Set
hibernate.bytecode.provider
tonone
on native image #29140 - Add proxy hints for org.hibernate.SessionFactory & org.hibernate.Session #29138
- DefaultPersistenceUnitManager.determineDefaultPersistenceUnitRootUrl is unable to resolve root url in native image #29137
- Adapt FieldHint to recent GraalVM versions #29130
- Deprecate StreamUtils.emptyInput() #29125
- Improve exception message when the code for a value could not be generated #29118
- Deprecate support for theme #29114
- Add resource hints for
HtmlCharacterEntityReferences.properties
#29112 - Introduce AotTestAttributes mechanism in the TestContext framework #29100
- Return absolute path without leading slash from ClassPathResource#getPath #29099
- Register runtime hints for types exposed via PersistenceManagedTypes #29096
- Remove deprecated SynthesizedAnnotation interface #29092
- Add support for providing JNI runtime hints #29085
- Introduce registerResource(Resource) in ResourceHints #29083
- Introduce AotTestExecutionListener API in the TestContext framework #29070
- Introduce TestRuntimeHintsRegistrar in the TestContext framework #29069
- Use
serializerOrNull
in Kotlin Serialization support #29068 - Align RuntimeHintsPredicates with new FieldMode #29063
- Remove support for setting default CacheAwareContextLoaderDelegate via system property #29061
- Avoid shipping AWT classes in native images #29060
- Stop using RuntimeHintsUtils to register SynthesizedAnnotation proxies #29059
- Remove obsolete RuntimeHintsUtils #29058
- Deprecate SynthesizedAnnotation and related methods #29053
- Stop implementing SynthesizedAnnotation in annotation proxies #29041
- Introduce logging for ContextCustomizer[Factory] to improve diagnostics #29036
- Avoid reflection for instantiating MockServerContainerContextCustomizer #29035
- Skip ContextCustomizerFactory that cannot be loaded #29034
- Register runtime hints for TestContext framework classes #29028
- Register runtime hints for
@Sql
scripts #29027 - Register runtime hints for
@WebAppConfiguration
attributes #29026 - Register runtime hints for
@TestPropertySource
attributes #29025 - Register runtime hints for
@TestExecutionListeners
attributes #29024 - Register runtime hints for
@BootstrapWith
attributes #29023 - Register runtime hints for ActiveProfilesResolver #29022
- Register runtime hints for
@ContextConfiguration
attributes #29021 - Remove remaining native build-time class initializations #29018
- Introduce TypeHint.Builder#onReachableType(Class<?>) #29017
- Harmonize registration of reflection hints #29011
- Revisit resource cleanup in RestTemplate and ClientHttpRequestFactory #29010
- Allow MethodReference to support a more flexible signature #29005
- Refine
JacksonModulesRuntimeHints
#29001 - Add hint for use of
@Qualifier
as a meta-annotation #29000 - Lazy Validator resolution in MethodValidationPostProcessor #28990
- Infer JDK dynamic proxies for Spring beans #28980
- Contribute
@PropertySource
declarations in AOT optimized contexts #28976 - Expose registrar for
@Reflective
#28975 - Revisit our annotation support now that annotations are available in a native image without a dedicated hint #28967
- Increase StreamUtils.BUFFER_SIZE to 8192 #28965
- Update StreamUtils drain and emptyInput to use JDK builtins #28961
- Integrate class proxy generation in AOT processing #28954
- RuntimeHintsUtils.registerAnnotation should not register SynthesizedAnnotation proxy for
@AliasFor
#28953 - Allow null argument for
ResponseEntity.DefaultBuilder.eTag(String etag)
#28947 - Remove the need for reflection for OptionalValidatorFactoryBean #28939
- Rename generateApplicationContext() in ApplicationContextAotGenerator #28927
- Remove deprecated GenericPropertiesContextLoader from the TestContext framework #28911
- Introduce AotContextLoader SPI in the TestContext framework #28906
- Deprecate methods in ContextLoader API in the TestContext framework #28905
- Make BootstrapUtils.resolveTestContextBootstrapper() public #28891
- Introduce RuntimeHintsUtils#registerComposableAnnotation #28887
- Instrument MVC and WebFlux for Observability #28880
- Introduce TestGenerationContext #28877
- Support Netty 5's Buffer API #28874
- Support for Netty 5 #28847
- Harmonize visibility of RuntimeHints builders #28835
- Introduce command-line application for triggering AOT test context processing #28825
- Introduce TestClassScanner to locate Spring test classes for AOT processing #28824
- Allow empty path in MockMvc #28823
- AOT-generated code for a FactoryBean should have a better location #28812
- Add support for SchedulerFactoryBean in native-image #28725
- EnableAsync doesn't work in native-image #28710
- Improve test coverage of RdbmsOperation #28472
- Treat MariaDB as an independent database type [#28...
v5.3.23
β New Features
- Introduce AnnotationUtils.isSynthesizedAnnotation(Annotation) #29054
- Introduce createContext() factory method in AbstractGenericWebContextLoader #28983
- Support TreeSet collection type in CollectionFactory.createCollection() without using reflection #28949
- Document when RequestEntity.getUrl() throws an UnsupportedOperationException #28930
- Deprecate NestedIOException #28929
- Make isConnected() in WebSocketConnectionManager public #28785
- Expose headers from STOMP RECEIPT frame to registered callbacks #28715
- Make WebClientException serializable #28321
π Bug Fixes
- Ordering inconsistency with beans defined in parent context #29105
- RelativeRedirectResponseWrapper does not commit response in sendRedirect #29050
- MockServerContainerContextCustomizerFactory does not support
@Nested
tests #29037 - Request to improve KotlinSerializationJsonHttpMessageConverter logic in RestTemplate #29008
- WebFlux: multipart requests hang sometimes #28963
- DataBufferUtils.write(Publisher, Path) loses context #28933
- connectionTimeOut and readTimeout not working on UrlResource #28909
- SockJsServiceRegistration#setSupressCors has a typo and should be deprecated #28853
- RenderingResponse does not set status code on redirect views #28839
- Avoid IllegalArgumentException when setting WebSocket error status #28836
- Loss of context path after using ServerRequest.from #28820
- ResponseCookie does not declare nullability annotations consistently for domain and path #28780
π Documentation
- Fix typo in data-access section #29048
- Correct description of
@RequestParam
with WebFlux #28944 - Fix broken kdoc-api links in kotlin.adoc #28908
- Fix typos in Javadoc of class AbstractEncoder #28885
- Fix links in Javadoc and reference docs #28876
- Add missing closing parenthesis in reference doc #28867
- Fix typos in Javadoc, reference docs, and code #28822
- Replace use of the
<tt>
HTML tag in Javadoc #28819 - Fix broken link in rsocket documentation #28817
- Clarify docs on JNDI properties in Servlet environment #28488
- Improve documentation of Caching annotations #28183
π¨ Dependency Upgrades
- Upgrade to Reactor 2020.0.23 #29129
β€οΈ Contributors
We'd like to thank all the contributors who worked on this release!