Skip to content

Commit a77dac5

Browse files
committed
Fix new Sonar smells; revert to BUILD-SNAPSHOTs
1 parent 6285925 commit a77dac5

File tree

3 files changed

+18
-17
lines changed

3 files changed

+18
-17
lines changed

build.gradle

+10-10
Original file line numberDiff line numberDiff line change
@@ -139,21 +139,21 @@ subprojects { subproject ->
139139
mysqlVersion = '8.0.16'
140140
pahoMqttClientVersion = '1.2.0'
141141
postgresVersion = '42.2.5'
142-
reactorNettyVersion = '0.9.0.M2'
143-
reactorVersion = '3.3.0.M2'
142+
reactorNettyVersion = '0.9.0.BUILD-SNAPSHOT'
143+
reactorVersion = '3.3.0.BUILD-SNAPSHOT'
144144
resilience4jVersion = '0.14.1'
145145
romeToolsVersion = '1.12.0'
146-
rsocketVersion = '0.12.2-RC4'
146+
rsocketVersion = '1.0.0-RC1-SNAPSHOT'
147147
servletApiVersion = '4.0.1'
148148
smackVersion = '4.3.3'
149-
springAmqpVersion = project.hasProperty('springAmqpVersion') ? project.springAmqpVersion : '2.2.0.M3'
150-
springDataJpaVersion = '2.2.0.RC1'
151-
springDataMongoVersion = '2.2.0.RC1'
152-
springDataRedisVersion = '2.2.0.RC1'
153-
springGemfireVersion = '2.2.0.RC1'
154-
springSecurityVersion = '5.2.0.M3'
149+
springAmqpVersion = project.hasProperty('springAmqpVersion') ? project.springAmqpVersion : '2.2.0.BUILD-SNAPSHOT'
150+
springDataJpaVersion = '2.2.0.BUILD-SNAPSHOT'
151+
springDataMongoVersion = '2.2.0.BUILD-SNAPSHOT'
152+
springDataRedisVersion = '2.2.0.BUILD-SNAPSHOT'
153+
springGemfireVersion = '2.2.0.BUILD-SNAPSHOT'
154+
springSecurityVersion = '5.2.0.BUILD-SNAPSHOT'
155155
springRetryVersion = '1.2.4.RELEASE'
156-
springVersion = project.hasProperty('springVersion') ? project.springVersion : '5.2.0.M3'
156+
springVersion = project.hasProperty('springVersion') ? project.springVersion : '5.2.0.BUILD-SNAPSHOT'
157157
springWsVersion = '3.0.7.RELEASE'
158158
tomcatVersion = "9.0.19"
159159
xstreamVersion = '1.4.11.1'

spring-integration-core/src/main/java/org/springframework/integration/config/DefaultConfiguringBeanFactoryPostProcessor.java

+6-7
Original file line numberDiff line numberDiff line change
@@ -175,23 +175,22 @@ private void registerMessagePublishingErrorHandler() {
175175
private void registerNullChannel() {
176176
if (this.beanFactory.containsBean(IntegrationContextUtils.NULL_CHANNEL_BEAN_NAME)) {
177177
BeanDefinition nullChannelDefinition = null;
178-
BeanFactory beanFactory = this.beanFactory;
178+
BeanFactory beanFactoryToUse = this.beanFactory;
179179
do {
180-
if (beanFactory instanceof ConfigurableListableBeanFactory) {
181-
ConfigurableListableBeanFactory listable = (ConfigurableListableBeanFactory) beanFactory;
180+
if (beanFactoryToUse instanceof ConfigurableListableBeanFactory) {
181+
ConfigurableListableBeanFactory listable = (ConfigurableListableBeanFactory) beanFactoryToUse;
182182
if (listable.containsBeanDefinition(IntegrationContextUtils.NULL_CHANNEL_BEAN_NAME)) {
183183
nullChannelDefinition = listable
184184
.getBeanDefinition(IntegrationContextUtils.NULL_CHANNEL_BEAN_NAME);
185185
}
186186
}
187-
if (beanFactory instanceof HierarchicalBeanFactory) {
188-
beanFactory = ((HierarchicalBeanFactory) beanFactory).getParentBeanFactory();
187+
if (beanFactoryToUse instanceof HierarchicalBeanFactory) {
188+
beanFactoryToUse = ((HierarchicalBeanFactory) beanFactoryToUse).getParentBeanFactory();
189189
}
190190
}
191191
while (nullChannelDefinition == null);
192192

193-
if (nullChannelDefinition != null &&
194-
!NullChannel.class.getName().equals(nullChannelDefinition.getBeanClassName())) {
193+
if (!NullChannel.class.getName().equals(nullChannelDefinition.getBeanClassName())) {
195194
throw new IllegalStateException("The bean name '" + IntegrationContextUtils.NULL_CHANNEL_BEAN_NAME
196195
+ "' is reserved.");
197196
}

spring-integration-rsocket/src/test/java/org/springframework/integration/rsocket/outbound/RSocketOutboundGatewayIntegrationTests.java

+2
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@
4343
import org.springframework.integration.expression.FunctionExpression;
4444
import org.springframework.integration.rsocket.ClientRSocketConnector;
4545
import org.springframework.integration.support.MessageBuilder;
46+
import org.springframework.lang.Nullable;
4647
import org.springframework.messaging.Message;
4748
import org.springframework.messaging.MessageChannel;
4849
import org.springframework.messaging.MessageHandlingException;
@@ -528,6 +529,7 @@ public MessageHandlerAcceptor clientAcceptor() {
528529
}
529530

530531
@Bean(destroyMethod = "dispose")
532+
@Nullable
531533
public RSocket rsocketForServerRequests() {
532534
return RSocketFactory.connect()
533535
.setupPayload(DefaultPayload.create("", "clientConnect"))

0 commit comments

Comments
 (0)