Deprecate Properties as bean for int global props
Having a bean as a `java.util.Properties` is not confusing and may lead to some conflicts in the real application. Plus it is not so easy to configure: need to know all the possible integration properties - bad end-user experience * Make an `IntegrationProperties` as a public POJO for easy configuration of global properties * Deprecate a presence of the `java.util.Properties` * Leave framework-created `integrationGlobalProperties` as a `Properties` instance for backward compatibility * Fix tests to expose an `IntegrationProperties` bean instead of deprecated `Properties` * Fix docs according the change and current recommendations
This commit is contained in:
committed by
Gary Russell
parent
aeb43f3069
commit
281d8d5bf6
@@ -154,8 +154,7 @@ The next section describes what happens if exceptions occur within the asynchron
|
||||
|
||||
Certain global framework properties can be overridden by providing a properties file on the classpath.
|
||||
|
||||
The default properties can be found in `/META-INF/spring.integration.default.properties` in the `spring-integration-core` jar.
|
||||
You can see them on GitHub https://github.com/spring-projects/spring-integration/blob/master/spring-integration-core/src/main/resources/META-INF/spring.integration.default.properties[here].
|
||||
The default properties can be found in `org.springframework.integration.context.IntegrationProperties` class.
|
||||
The following listing shows the default values:
|
||||
|
||||
====
|
||||
@@ -205,7 +204,7 @@ See <<./error-handling.adoc#error-handling,Error Handling>> for more information
|
||||
Since version 5.5.
|
||||
====
|
||||
|
||||
These properties can be overridden by adding a `/META-INF/spring.integration.properties` file to the classpath.
|
||||
These properties can be overridden by adding a `/META-INF/spring.integration.properties` file to the classpath or an `IntegrationContextUtils.INTEGRATION_GLOBAL_PROPERTIES_BEAN_NAME` bean for the `org.springframework.integration.context.IntegrationProperties` instance.
|
||||
You need not provide all the properties -- only those that you want to override.
|
||||
|
||||
Starting with version 5.1, all the merged global properties are printed in the logs after application context startup when a `DEBUG` logic level is turned on for the `org.springframework.integration` category.
|
||||
|
||||
@@ -21,6 +21,7 @@ If you are interested in more details, see the Issue Tracker tickets that were r
|
||||
All the persistent `MessageGroupStore` implementation provide a `streamMessagesForGroup(Object groupId)` contract based on the target database streaming API.
|
||||
See <<./message-store.adoc#message-store,Message Store>> for more information.
|
||||
|
||||
The `integrationGlobalProperties` bean (if declared) must be now an instance of `org.springframework.integration.context.IntegrationProperties` instead of `java.util.Properties`, which support is deprecated for backward compatibility.
|
||||
The `spring.integration.channels.error.requireSubscribers=true` global property is added to indicate that the global default `errorChannel` must be configured with the `requireSubscribers` option (or not).
|
||||
The `spring.integration.channels.error.ignoreFailures=true` global property is added to indicate that the global default `errorChannel` must ignore (or not) dispatching errors and pass the message to the next handler.
|
||||
See <<./configuration.adoc#global-properties,Global Properties>> for more information.
|
||||
|
||||
Reference in New Issue
Block a user