Stephane Nicoll
f931a3fb59
Improve DataSize to support negative values
...
Issue: SPR-17154
2018-08-10 18:21:09 +02:00
Juergen Hoeller
aebb2d52e0
Logging refinements for transaction and cache processing (debug/trace)
...
Issue: SPR-16946
2018-08-10 15:45:46 +02:00
Stephane Nicoll
282a4ad2f6
Fix checkstyle violations
2018-08-10 14:43:16 +02:00
Stephane Nicoll
8a1588ae29
Add support for DataSize
...
This commit provides a data type to represents a size in bytes and other
standard unit.
Issue: SPR-17154
2018-08-10 14:28:46 +02:00
Sam Brannen
8ea913392c
Link to Eclipse bug for annotations on bridge methods
2018-08-09 18:49:24 +02:00
Juergen Hoeller
65f29a39ca
AbstractAspectJAdvisorFactory uses AnnotationUtils.getValue
2018-08-09 02:26:28 +02:00
Juergen Hoeller
4521a79b2d
Find annotations on implemented generic superclass methods as well
...
Includes Java 8 getDeclaredAnnotation shortcut for lookup on Class.
Issue: SPR-17146
2018-08-08 23:52:47 +02:00
Sergey Chupov
a06e63f619
Polishing javadocs: IllegalStateException no longer thrown
...
The dependency to Apache Commons has been removed in 51252ebbca (diff-95dc9d8756aa91afb2ac28454f1b634c)
, but the javadoc still mentions it.
2018-08-08 15:51:05 +02:00
Sam Brannen
7b608ab995
Ensure AnnotationUtilsTests pass in Eclipse again
2018-08-08 13:23:51 +02:00
Kazuhiro Sera
be211ceead
Fix typos detected by github.com/client9/misspell
2018-08-08 12:50:46 +02:00
Juergen Hoeller
b325c74216
Pruning of outdated JDK 6/7 references (plus related polishing)
2018-08-07 20:36:47 +02:00
Juergen Hoeller
2b051b8b32
Deprecate support classes for Sun's JDK HTTP server
...
Issue: SPR-17143
2018-08-07 20:35:53 +02:00
Juergen Hoeller
2d05f2ed47
SerializableTypeWrapper detects Graal through system property as well
...
Issue: SPR-17136
2018-08-07 11:15:43 +02:00
Juergen Hoeller
6b82a6c38c
Polishing
2018-08-07 02:47:00 +02:00
Juergen Hoeller
d72d376f03
Avoid unnecessary annotation introspection on framework methods
...
Issue: SPR-16933
2018-08-07 01:35:32 +02:00
Juergen Hoeller
8a9d042320
Javadoc fix from ASM master (6.2.1)
...
Issue: SPR-16398
2018-08-06 18:33:41 +02:00
Juergen Hoeller
69c6a40c50
Consistent nullability for array/collection input parameters
...
Includes pre-sizing of LinkedHashSet for conversion from array.
Issue: SPR-17123
Issue: SPR-17074
2018-08-06 14:11:59 +02:00
Rossen Stoyanchev
5095ec40b5
takeUntilByteCount actually uses takeUntil
...
Issue: SPR-17188
2018-08-02 21:19:22 +03:00
Rossen Stoyanchev
542ed81d5c
Polish
2018-08-02 21:19:22 +03:00
Juergen Hoeller
0001f87d59
Polishing
2018-08-01 12:52:50 +02:00
Juergen Hoeller
589b7048ec
Avoid synthesizable annotation creation for @Bean/@Scope processing
...
Includes consistent (non-)use of AnnotationUtils/AnnotatedElementUtils.
Issue: SPR-16933
2018-08-01 11:43:28 +02:00
Juergen Hoeller
9b671f8408
Polishing
2018-07-31 23:57:19 +02:00
Juergen Hoeller
6cd9060183
Avoid synthesizable check for common annotation types
...
This revision considers any java/javax and org.springframework.lang annotations as not synthesizable upfront, checking not only in isSynthesizable but also at synthesizeAnnotation(Array) level.
Issue: SPR-16933
2018-07-31 20:54:10 +02:00
Juergen Hoeller
4a147d26fc
Initialize pre-filled HashMaps with large enough capacity
...
Empty Maps are preferably initialized without capacity (not initializing them at all or lazily initializing with default capacity when needed).
Issue: SPR-17105
2018-07-30 22:07:31 +02:00
Juergen Hoeller
c037e75f26
Improve debug logging at BeanDefinitionReader and BeanFactory level
...
Issue: SPR-17090
2018-07-27 17:46:05 +02:00
Juergen Hoeller
e82efbc7e3
Declare ASM7_EXPERIMENTAL for full compatibility with JDK 11 bytecode
...
Issue: SPR-17096
2018-07-26 23:11:54 +02:00
Juergen Hoeller
9ab63b8494
ListBasedXMLEventReader uses defensive modifiable copy of given List
2018-07-25 19:03:13 +02:00
Juergen Hoeller
3881a4aded
Polishing
2018-07-25 14:16:02 +02:00
Juergen Hoeller
fd8e4abe5d
Introduce ResolvableType.toClass() shortcut
...
Issue: SPR-17086
2018-07-25 14:15:19 +02:00
Juergen Hoeller
fac2e35f96
Refactor util.log.LogUtils into core.log.LogDelegateFactory
...
Issue: SPR-17012
2018-07-24 14:44:34 +02:00
Sebastien Deleuze
f8f8d28f08
Support running Kotlin apps without kotlin-reflect
...
This commit includes an optimization of BeansUtils#instantiateClass
that favors Java reflection for default constructors before leveraging
Kotlin one for finding primary constructors and avoids Kotlin related
conditions when running in Java.
Issue: SPR-17069
2018-07-23 09:54:48 +02:00
Juergen Hoeller
bccff73e2b
AspectJExpressionPointcut leniently ignores non-composable interfaces
...
Issue: SPR-17003
2018-07-22 22:28:48 +02:00
Juergen Hoeller
cfbacfd89b
Revise ResolvableType.as for introspection performance
...
This revision limits serializability of derived interfaces, superclasses and type parameters, optimizing for introspection performance instead.
Issue: SPR-17070
2018-07-22 17:49:53 +02:00
stsypanov
5051850fa9
SPR-17074 Replace iteration over Map::ketSet with Map::entrySet
2018-07-21 13:12:43 +02:00
Juergen Hoeller
9a43d2ec20
Revised log levels: less WARN and INFO, fine-tuned DEBUG vs TRACE
...
Issue: SPR-16946
2018-07-20 15:05:16 +02:00
Juergen Hoeller
c4df335a1d
ReflectiveMethodExecutor invokes interface method if possible
...
Issue: SPR-16845
2018-07-19 16:35:59 +02:00
Juergen Hoeller
d0bbbf4cae
OrderUtils caches order values (for AnnotationAwareOrderComparator)
...
Issue: SPR-17064
2018-07-19 11:58:42 +02:00
Rossen Stoyanchev
4d6f2df3cb
Add LogUtils and HttpLogging
...
SPR-17012
2018-07-18 15:32:50 -04:00
Juergen Hoeller
23d4862017
Find annotations on implemented generic interface methods as well
...
Issue: SPR-16060
2018-07-18 19:44:30 +02:00
Sebastien Deleuze
e8034f2f96
Adapt DefaultParameterNameDiscoverer to Graal constraints
...
When compiling or running as a Graal native image, no
ParameterNameDiscoverer is used.
Issue: SPR-17005
2018-07-18 17:17:47 +02:00
Juergen Hoeller
cab35aa788
StringUtils.parseLocaleString detects variant without country
...
Includes tests for parsing all available locales on the JVM, checking toString/toLanguageTag equality between parsed and original locale.
Issue: SPR-7598
Issue: SPR-16651
2018-07-18 11:10:26 +02:00
Juergen Hoeller
88e4006790
CookieLocaleResolver is RFC6265 and language tag compliant by default
...
Like CookieLocaleResolver, LocaleChangeInterceptor parses both locale formats by default now. Since it does not need to render the locale, its languageTagCompliant property is not relevant anymore at all.
The parseLocale method in StringUtils validates the locale value now and turns an empty locale into null, compatible with parseLocaleString behavior and in particular aligned with web locale parsing needs.
Issue: SPR-16700
Issue: SPR-16651
2018-07-17 17:57:59 +02:00
Juergen Hoeller
cacd14c805
Never return null from AnnotationMetadata.getMetaAnnotationTypes
...
Issue: SPR-17046
2018-07-16 18:05:10 +02:00
Juergen Hoeller
f6fdffd663
Lazily retrieve delegate beans in AsyncConfigurer and CachingConfigurer
...
Introduces a configure method pattern for Supplier-style configuration and a common SingletonSupplier decorator for method reference suppliers. Also declares jcache.config and jcache.interceptor for non-null conventions.
Issue: SPR-17021
2018-07-14 19:29:32 +02:00
Rossen Stoyanchev
1b1bc7f5b5
Switch defaults and model for logging sensitive data
...
Issue: SPR-17029
2018-07-11 11:10:03 -04:00
Juergen Hoeller
6887802526
Fallback to ClassLoader.defineClass for Lookup.defineClass LinkageError
...
Issue: SPR-16902
2018-07-10 22:13:57 +02:00
Juergen Hoeller
a1d209726c
Upgrade to ASM master (6.2+) and CGLIB 3.2.7
...
Issue: SPR-16398
2018-07-10 18:51:01 +02:00
Juergen Hoeller
833343f17c
Specifically rethrow IllegalAccessError in isPresent/resolveClassName
...
Issue: SPR-17018
2018-07-09 14:31:45 +02:00
Juergen Hoeller
fd0220b85c
Suppress rawtypes warning for createReferenceArray
2018-07-09 14:28:15 +02:00
stsypanov
6d6aa72e8f
improve performance of projection instantiation
2018-07-09 13:39:23 +02:00
Rossen Stoyanchev
4bd22eeb13
Fallback logger for logging in http and codec packages
...
Issue: SPR-17012
2018-07-07 10:54:03 -04:00
Rossen Stoyanchev
bca9f51092
Polish hint for suppressing logging at Encoder/Decoder
2018-07-06 20:32:08 -04:00
Juergen Hoeller
d8c7270c00
Consistent Iterator/Stream support in PropertySources and PropertyValues
...
Issue: SPR-16894
2018-07-05 23:59:56 +02:00
Rossen Stoyanchev
82310660fd
Correlated encoding/decoding log messages via hints
...
Issue: SPR-16966
2018-07-05 08:28:15 -04:00
Juergen Hoeller
5dc8b5de6d
Polishing
2018-07-04 15:07:17 +02:00
Sebastien Deleuze
9b7a492bc9
Test RxReactiveStreams presence in ReactiveAdapterRegistry
...
Issue: SPR-17000
2018-07-03 18:00:47 +02:00
Sebastien Deleuze
dcbaecea2a
Perform explicit class checks in ReactiveAdapterRegistry
...
In order to allow Spring Framework applications running as GraalVM
native images, ReactiveAdapterRegistry should perform explicit class
checks instead of catching Throwable in order to avoid
UnsupportedFeatureError errors.
Issue: SPR-17000
2018-07-03 13:35:11 +02:00
Juergen Hoeller
779cf8d240
ConcurrentReferenceHashMap caches EntrySet in volatile field
...
Includes an efficient implementation of isEmpty(), not relying on a full entry count but rather backing out once a non-empty hash segment has been found.
Issue: SPR-16994
2018-07-02 22:32:57 +02:00
Juergen Hoeller
06f9fb9aeb
Refine Class serializability check for actual Graal compatibility
...
Issue: SPR-16992
2018-07-02 22:32:29 +02:00
Juergen Hoeller
e5a6711d29
Consistent final declaration for static delegate classes
...
Issue: SPR-16968
2018-07-02 13:55:18 +02:00
Juergen Hoeller
2ade122543
Bypass serializable type wrapping if java.lang.Class not serializable
...
Issue: SPR-16992
2018-07-02 13:55:03 +02:00
Juergen Hoeller
4ff1e3e74b
Consistent abstract declaration for utility classes (plus polishing)
...
Issue: SPR-16968
2018-07-01 02:31:20 +02:00
Rossen Stoyanchev
907a306ee2
Fix locally failing test in FlushingIntegrationTests
2018-06-29 18:15:52 -03:00
Juergen Hoeller
40efcc933c
Polishing
2018-06-28 14:51:33 +02:00
Juergen Hoeller
b68e692854
Conventions lazily retrieves shared ReactiveAdapterRegistry
...
Issue: SPR-16981
2018-06-28 14:47:52 +02:00
Juergen Hoeller
7a02e438e7
StringUtils.cleanPath retains plain pointer to current directory
...
Issue: SPR-16908
2018-06-28 14:15:16 +02:00
Phillip Webb
a89e716cc7
Use tabs rather than spaces in tests
...
Update tests to ensure that tabs are used instead of spaces. Also
consistently apply a new line at the end of each file.
Issue: SPR-16968
2018-06-28 10:28:44 +02:00
Phillip Webb
1c25cec44f
Polish test code
...
Polish a few issue identified when adding checkstyle to the
build. Although checkstyle is not enforcing rules on tests,
these are a few minor changes that are still worth making.
Issue: SPR-16968
2018-06-28 10:28:44 +02:00
Phillip Webb
81451aa800
Organize imports
...
Reorganize imports to ensure consistent ordering. This commit also
expands any `.*` static imports in favor of using fully-qualified
method references.
Issue: SPR-16968
2018-06-28 10:28:44 +02:00
Phillip Webb
b220d94cc2
Never use parenthesis for single lambda arguments
...
Update all lambdas that take a single argument so that parenthesis
are never used.
Issue: SPR-16968
2018-06-28 10:28:44 +02:00
Phillip Webb
5cedd0d5d4
Consistently use tabs rather than spaces
...
Update code that has accidentally used spaces instead of tabs.
Also remove all trailing whitespace.
Issue: SPR-16968
2018-06-28 10:28:44 +02:00
Phillip Webb
ad6d183a06
Remove unneeded conditional logic
...
Update `ConversionUtils` to remove conditional logic that isn't
necessary.
Issue: SPR-16968
2018-06-28 10:28:44 +02:00
Phillip Webb
9de3689f63
Never use 'this.' when accessing loggers
...
Ensure that `this.` is never used when accessing loggers.
Issue: SPR-16968
2018-06-28 10:28:44 +02:00
Phillip Webb
0b53c1096a
Always use 'this.' when accessing fields
...
Ensure that `this.` is used consistently when accessing class
fields.
Issue: SPR-16968
2018-06-28 10:28:44 +02:00
Phillip Webb
eeebd51f57
Use consistent class design
...
Update all classes so that inner classes are always last. Also
ensure that utility classes are always final and have a private
constructor and make exceptions final whenever possible.
Issue: SPR-16968
2018-06-28 10:28:44 +02:00
Phillip Webb
e9d1b39aff
Apply consistent copyright header
...
Add copyright header to `package-info.java` files and fix a few
malformed headers on existing java files.
Issue: SPR-16968
2018-06-28 10:28:44 +02:00
Phillip Webb
c3a17dfd47
Ensure all files end with a newline
...
Update all files to ensure that they always end with a new line.
Issue: SPR-16968
2018-06-28 10:28:44 +02:00
Phillip Webb
e0480f75ac
Fix javadoc checkstyle issues
...
Fix checkstyle violations for javadoc.
Issue: SPR-16968
2018-06-28 10:28:44 +02:00
Juergen Hoeller
847202c8f8
MimeTypeUtils lazily initializes SecureRandom for multipart boundary
...
Issue: SPR-16974
2018-06-25 18:12:43 +02:00
Rossen Stoyanchev
900bc8a2e3
Logging improvements for WebFlux
...
Issue: SPR-16898
2018-06-22 22:44:24 -04:00
Sam Brannen
cafb5033e2
Polishing
2018-06-19 13:50:13 +03:00
Sam Brannen
bea0e399b8
Polish profile expression support
...
Issue: SPR-12458
2018-06-17 00:15:18 +03:00
Sam Brannen
4184ebe799
Polish profile expression support
...
Issue: SPR-12458
2018-06-16 21:40:22 +03:00
Juergen Hoeller
38f9a7b072
FileSystemResource supports java.nio.file.Path based setup
...
Issue: SPR-16833
2018-06-15 22:12:14 +02:00
Juergen Hoeller
bb6ab5dc91
OS-independent alphabetical sorting of directory content
...
Issue: SPR-16838
2018-06-15 22:09:29 +02:00
Stephane Nicoll
1f3b4f1863
Polish "Add profile expression support"
...
Issue: SPR-12458
2018-06-15 16:01:16 +02:00
Phillip Webb
e2623b7d35
Add profile expression support
...
Allow the `Environment` to accept a generic `Profiles` interface which
can support more complex matching rules. The previous
`acceptsProfiles(String...)` method now uses `Profiles.of` which
supports basic profile expressions such as "(a | b) & !c"
Issue: SPR-12458
2018-06-15 16:01:16 +02:00
Juergen Hoeller
c38cb43527
MethodParameter strictly asserts parameter index -1 for return type
...
Issue: SPR-16889
2018-06-14 00:42:19 +02:00
Rossen Stoyanchev
0078f46779
Use reflection for JdkFlowAdapter
...
To avoid compiler issues on Eclipse.
2018-06-13 09:38:54 -04:00
Juergen Hoeller
0777a80efe
Polishing
...
(cherry picked from commit a2765c0
)
2018-06-11 19:17:57 +02:00
Brian Clozel
417354da8a
Remove dependency management noise from POMs
...
Prior to this commit, the generated POMs for Spring Framework modules
would contain unneeded/harmful information from the Spring Framework
build:
1. The BOM imports applied to each module by the dependency
management plugin, for example for Netty or Reactor Netty.
Spring should not export that opinion to its POMs.
2. The exclusion of "org.slf4:jcl-over-slf4j" from *all* dependencies,
which made the POMs much larger than necessary and suggested to
developers that they should exclude it as well when using all those
listed dependencies. In fact, only Apache Tiles currently brings that
transitively.
This commit removes that information from the POMs.
The dependencyManagement Gradle plugin is disabled for POM generation
and we manually resolve the dependency versions during the generation
phase.
The Gradle build is streamlined to exclude "org.slf4:jcl-over-slf4j"
only when necessary.
Issue: SPR-16893
2018-06-11 15:57:54 +02:00
Juergen Hoeller
b790bd1fd6
LinkedCaseInsensitiveMap explicitly implements put/computeIfAbsent
...
Issue: SPR-16926
2018-06-11 14:10:12 +02:00
Yun
28e402bc76
Prevent instantiation of AnnotatedElementUtils
...
Closes gh-1848
2018-06-11 08:32:03 +02:00
Rossen Stoyanchev
010352163b
Eliminate the need for Encoder#getContentLength
...
Issue: SPR-16892
2018-06-04 15:48:47 -04:00
Sebastien Deleuze
a7a29a8226
Revisit PropertyResolver Kotlin extensions
...
Issue: SPR-16883
2018-05-31 12:20:37 +02:00
Juergen Hoeller
616a40adb6
ClassPathResource.isReadable() returns false for content length 0
...
Issue: SPR-16832
2018-05-29 22:31:47 +02:00
Juergen Hoeller
74fcdea2d9
SimpleAliasRegistry logs info message for alias overriding
...
Issue: SPR-16871
2018-05-29 21:51:33 +02:00
Juergen Hoeller
46a89d9534
Restore lenient null return value for ConditionContext.getBeanFactory()
...
Includes nullable return value for getClassLoader() with corresponding notes in applicable javadoc.
Issue: SPR-16866
2018-05-29 21:51:06 +02:00
Juergen Hoeller
69f14a2038
ClassPathResource.isReadable() checks InputStream (for jar directories)
...
Resource.isReadable() is defined to semantically imply exists() now.
Issue: SPR-16832
2018-05-29 21:47:33 +02:00
Sebastien Deleuze
406f6ec74d
Fix PropertyResolverExtensions.kt location
2018-05-28 15:51:22 +02:00