Commit Graph

3372 Commits (a6f357c2fd634c94528d92553ad0da3ee661c697)

Author SHA1 Message Date
Johnny Lim bc7fc90550 Replace Base64Utils with JDK's Base64
See gh-33967
2 years ago
Krzysztof Krason f4af93fb03 Use for loop rather than iterator
See gh-33987
2 years ago
Krzysztof Krason 55a50d565c Use Comparator.comparing
See gh-33987
2 years ago
Krzysztof Krason d3efd7e091 Use try with close
See gh-33987
2 years ago
Krzysztof Krason 0e68cae57f Use instanceof patterns
See gh-33987
2 years ago
Krzysztof Krason 6e46423983 Use diamond operators
See gh-33987
2 years ago
Phillip Webb 0a50b83c75 Add DataSourceBuilderRuntimeHints
Add hints for DataSourceBuilderRuntime.

Closes gh-33692
2 years ago
Moritz Halbritter ae79c60619 Remove instance suppliers in bean definitions
Remove instance suppliers in bean definitions and depend instead
on reflection. This allows the AOT engine to correctly process
the definitions.

Fixes gh-33763
2 years ago
Phillip Webb 71efc55bf9 Merge branch '2.7.x' 2 years ago
Phillip Webb 7c508fa324 Update copyright year of changed files 2 years ago
Moritz Halbritter 94f4a4396c Merge branch '2.7.x'
Closes gh-33880
2 years ago
Moritz Halbritter e8d809fe65 Replace 'via' with 'over' or 'through' in the documentation
Closes gh-33878
2 years ago
Andy Wilkinson a2f593c15f Merge branch '2.7.x'
Closes gh-33876
2 years ago
Andy Wilkinson b5cebed120 Improve failure description when bean def has no resource description
Closes gh-33765
2 years ago
Moritz Halbritter c939e27925 Only set AWT headless property if not already set
Closes gh-28803
2 years ago
Phillip Webb fad88232b9 Update copyright year of changed files 2 years ago
Phillip Webb a889c539ab Merge branch '2.7.x' 2 years ago
Phillip Webb a0fe8241a7 Update copyright year of changed files 2 years ago
Moritz Halbritter 47c1aa2724 Merge branch '2.7.x'
Closes gh-33771
2 years ago
Moritz Halbritter d6f682da7e Polish JavaBeanBinder
Closes gh-33762
2 years ago
Moritz Halbritter e45b47565c Use Threadlocal.remove instead of .set(null)
See https://github.com/spring-cloud/spring-cloud-sleuth/issues/27 for
reference.
2 years ago
Phillip Webb 84b13f0748 Refine constructor detection logic when binding to existing values
Update `DefaultBindConstructorProvider` so that deduced constructors
are not used if there is an existing value.

Prior to this commit, constructor detection logic was not compatible
with earlier versions of Spring Boot. With Spring Boot 3.0.1, given
a class of the following form:

	@ConfigurationProperties(prefix = "example")
	public class ExampleProperties {

	    @NestedConfigurationProperty
	    private final NestedProperty nested = new NestedProperty(
	    		"Default", "default");

	    public NestedProperty getNested() {
	        return nested;
	    }

	}

If `NestedProperty` has a single constructor with arguments, constructor
binding would be used. In Spring Boot 2.x, setter injection would have
been used.

The updated code now only uses constructor injection if an explicit
`@ConstructorBinding` annotation is present, or if there is no existing
value.

Fixes gh-33409
See gh-33710
2 years ago
Phillip Webb a2ac38e203 Update copyright year of changed files 2 years ago
Phillip Webb 80cfcb71ec Update copyright year of changed files 2 years ago
Krzysztof Krason cf6493f65c Simplify AssertJ assertions and also make them more readable
See gh-33653
2 years ago
Kaveh Shamsi 2d95e4a31e Fix JavaDoc typo in LocalServerPort
See gh-33683
2 years ago
Phillip Webb 2e90b71c30 Do not attempt constructor binding for items with an existing value
Update `DefaultBindConstructorProvider` so that it no longer detects
constructors when the `Bindable` has an existing value. This update
allows us change `ConfigurationPropertiesBindingPostProcessor` and
related classes so that all instances created from `@Bean` methods
are treated as `JAVA_BEAN` bindings and will not be accidentally
re-created using constructor binding.

Fixes gh-33710
2 years ago
Phillip Webb f588793445 Update copyright year of changed files 2 years ago
Phillip Webb 0254619782 Merge branch '2.7.x' 2 years ago
Phillip Webb e4772cf3b7 Update copyright year of changed files 2 years ago
Phillip Webb 2e7ca6f82d Warning if <springProfile> is used in phase 2 model elements
Add `SpringProfileIfNestedWithinSecondPhaseElementSanityChecker` which
will provide a warning if `<springProfile>` is used within a phase 2
model element. This is similar to Logback's own `<if>` warnings.

The `LogbackLoggingSystem` has also been updated so that warning are
printed when present.

Fixes gh-33610
2 years ago
Phillip Webb 2ed512ddb5 Use model.deepMarkAsSkipped in SpringProfileModelHandler
Switch `model.markAsSkipped` to `model.deepMarkAsSkipped` in
`SpringProfileModelHandler`.

Although the current call doesn't appear to be causing issues,
it seems best to align our <springProfile> support with the way
that Logback implements its own `<if>` support.

Closes gh-33618
2 years ago
Phillip Webb c257f2b1d2 Merge branch '2.7.x' 2 years ago
Phillip Webb bc6fc33498 Polish 2 years ago
Moritz Halbritter 08659baeba Polish away public modifier on tests 2 years ago
Moritz Halbritter f36e2ecb7b Use AutoClosables with try-with-resources
Closes gh-33538
2 years ago
Moritz Halbritter 725337f976 Make fields final
Closes gh-33537
2 years ago
Moritz Halbritter 47eb3b11b9 Upgrade Tomcat to 10.1.4
Closes gh-33167
Closes gh-33071
2 years ago
Moritz Halbritter a4779b7859 Merge branch '2.7.x'
Closes gh-33433
2 years ago
Moritz Halbritter 16569099ba Polish "Fix bug in webserver start when loading PKCS#11 KeyStore"
See gh-32179
2 years ago
cdanger 716a839d54 Fix bug in webserver start when loading PKCS#11 KeyStore
See gh-32179
2 years ago
Andy Wilkinson 276b288891 Prevent repeat configuration of DB init bean dependencies
Fixes gh-33374
2 years ago
Moritz Halbritter b3878e84ae Fix bug where using a YAML with anchors couldn't be loaded
Closes gh-33404
2 years ago
Andy Wilkinson c1dab0f9e6 Fix AOT processing of add method with array parameter in Logback model
Fixes gh-33387
2 years ago
Andy Wilkinson b9e57c73b5 Consider Kotlin when checking if parameter names are available
See gh-33182
2 years ago
Phillip Webb a50d1f0bd6 Switch to use BeanUtils.getPropertyDescriptors
Update `BindableRuntimeHintsRegistrar` to use
`BeanUtils.getPropertyDescriptors` rather than `BeanInfoFactory`.

Closes gh-33232
2 years ago
Phillip Webb 2e8d766889 Fix BindableRuntimeHintsRegistrarTests inner class to be static 2 years ago
Phillip Webb d6151858f2 Merge pull request #32851 from tumit
* pr/32851:
  Polish 'Add test for BindableRuntimeHintsRegistrar'
  Add tests for BindableRuntimeHintsRegistrar

Closes gh-32851
2 years ago
Phillip Webb 13a4902018 Polish 'Add test for BindableRuntimeHintsRegistrar'
See gh-32851
2 years ago
tumit 7e424bdf0c Add tests for BindableRuntimeHintsRegistrar
See gh-32851
2 years ago