Resolves https://github.com/spring-projects/spring-integration/issues/8668
**cherry-pick to all supported branches**
(cherry picked from commit fc3c8d2c8d)
Resolves https://github.com/spring-projects/spring-integration/issues/8668
**cherry-pick to all supported branches**
(cherry picked from commit fc3c8d2c8d)