Start 5.2 version; upgrade dependencies; fixes
This commit is contained in:
@@ -60,7 +60,7 @@
|
||||
<bean id="replySource" class="org.springframework.integration.jdbc.ExpressionEvaluatingSqlParameterSourceFactory">
|
||||
<property name="parameterExpressions">
|
||||
<map>
|
||||
<entry key="id" value="#this['SCOPE_IDENTITY()']"/>
|
||||
<entry key="id" value="#this.ID"/>
|
||||
</map>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2017 the original author or authors.
|
||||
* Copyright 2014-2019 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -71,8 +71,8 @@ public class EmbeddedSftpServer implements InitializingBean, SmartLifecycle {
|
||||
final PublicKey allowedKey = decodePublicKey();
|
||||
this.server.setPublickeyAuthenticator((username, key, session) -> key.equals(allowedKey));
|
||||
this.server.setPort(this.port);
|
||||
this.server.setKeyPairProvider(new SimpleGeneratorHostKeyProvider(new File("hostkey.ser")));
|
||||
this.server.setSubsystemFactories(Collections.singletonList(new SftpSubsystemFactory()));
|
||||
this.server.setKeyPairProvider(new SimpleGeneratorHostKeyProvider(new File("hostkey.ser").toPath()));
|
||||
server.setSubsystemFactories(Collections.singletonList(new SftpSubsystemFactory()));
|
||||
final String pathname = System.getProperty("java.io.tmpdir") + File.separator + "sftptest" + File.separator;
|
||||
new File(pathname).mkdirs();
|
||||
server.setFileSystemFactory(new VirtualFileSystemFactory(Paths.get(pathname)));
|
||||
|
||||
41
build.gradle
41
build.gradle
@@ -9,7 +9,7 @@ buildscript {
|
||||
}
|
||||
}
|
||||
plugins {
|
||||
id "org.sonarqube" version "2.6.1"
|
||||
id "org.sonarqube" version "2.7"
|
||||
}
|
||||
|
||||
description = 'Spring Integration Samples'
|
||||
@@ -169,30 +169,28 @@ subprojects { subproject ->
|
||||
}
|
||||
|
||||
ext {
|
||||
activeMqVersion = '5.15.3'
|
||||
apacheSshdVersion = '1.6.0'
|
||||
aspectjVersion = '1.9.0'
|
||||
activeMqVersion = '5.15.8'
|
||||
apacheSshdVersion = '2.2.0'
|
||||
aspectjVersion = '1.9.2'
|
||||
commonsDigesterVersion = '2.0'
|
||||
commonsDbcpVersion = '1.2.2'
|
||||
commonsFileUploadVersion = '1.4'
|
||||
commonsIoVersion = '2.4'
|
||||
commonsIoVersion = '2.6'
|
||||
commonsLangVersion = '2.6'
|
||||
commonsPoolVersion = '1.5.4'
|
||||
c3p0Version = '0.9.1.2'
|
||||
derbyVersion = '10.10.1.1'
|
||||
eclipseLinkVersion = '2.6.4'
|
||||
derbyVersion = '10.14.2.0'
|
||||
hamcrestVersion = '1.3'
|
||||
hibernateVersion = '5.2.10.Final'
|
||||
hibernateVersion = '5.4.1.Final'
|
||||
hibernateValidatorVersion = '5.4.1.Final'
|
||||
ftpServerVersion = '1.1.1'
|
||||
flexjsonVersion = '2.0'
|
||||
guavaVersion = '16.0.1'
|
||||
groovyVersion = '2.3.0'
|
||||
hsqldbVersion = '2.3.2'
|
||||
h2Version = '1.4.194'
|
||||
groovyVersion = '2.5.6'
|
||||
hsqldbVersion = '2.4.1'
|
||||
h2Version = '1.4.197'
|
||||
jacksonVersion = '2.9.8'
|
||||
javaxInjectVersion = '1'
|
||||
javaxMailVersion = '1.5.5'
|
||||
javaxMailVersion = '1.6.2'
|
||||
jodaTimeVersion = '1.6'
|
||||
jtaVersion = '1.1'
|
||||
jtdsVersion = '1.2.6'
|
||||
@@ -202,20 +200,20 @@ subprojects { subproject ->
|
||||
jpaApiVersion = '2.0.0'
|
||||
jstlVersion = '1.2'
|
||||
junitVersion = '4.12'
|
||||
jythonVersion = '2.5.3'
|
||||
jythonVersion = '2.7.0'
|
||||
log4jVersion = '2.7'
|
||||
mockitoVersion = '2.18.0'
|
||||
mockitoVersion = '2.24.0'
|
||||
openJpaVersion = '2.4.0'
|
||||
oracleDriverVersion = '11.2.0.3'
|
||||
postgresVersion = '42.0.0'
|
||||
postgresVersion = '42.2.5'
|
||||
subethasmtpVersion = '1.2'
|
||||
slf4jVersion = '1.7.25'
|
||||
springIntegrationVersion = '5.1.3.RELEASE'
|
||||
springIntegrationKafkaVersion = '3.1.1.RELEASE'
|
||||
springIntegrationVersion = '5.2.0.BUILD-SNAPSHOT'
|
||||
springIntegrationKafkaVersion = '3.2.0.BUILD-SNAPSHOT'
|
||||
springIntegrationSocialTwiterVersion = '1.0.0.RELEASE'
|
||||
springIntegrationSplunkVersion = '1.1.0.RELEASE'
|
||||
springKafkaVersion = '2.2.3.RELEASE'
|
||||
springVersion = '5.1.5.RELEASE'
|
||||
springKafkaVersion = '2.3.0.BUILD-SNAPSHOT'
|
||||
springVersion = '5.2.0.BUILD-SNAPSHOT'
|
||||
springSecurityVersion = '5.1.4.RELEASE'
|
||||
springWebFlowVersion = '2.3.3.RELEASE'
|
||||
tilesJspVersion = '2.2.1'
|
||||
@@ -718,7 +716,6 @@ project('cafe-dsl') {
|
||||
compile project(":cafe-si")
|
||||
compile 'org.springframework.boot:spring-boot-starter-integration'
|
||||
compile "org.springframework.integration:spring-integration-core"
|
||||
compile "com.google.guava:guava:$guavaVersion"
|
||||
|
||||
testCompile 'org.springframework.boot:spring-boot-starter-test'
|
||||
}
|
||||
@@ -881,8 +878,8 @@ project('sftp') {
|
||||
|
||||
dependencies {
|
||||
compile "org.springframework.integration:spring-integration-sftp"
|
||||
compile "org.apache.sshd:sshd-core:$apacheSshdVersion"
|
||||
compile "org.apache.logging.log4j:log4j-core:$log4jVersion"
|
||||
testCompile "org.apache.sshd:sshd-sftp:$apacheSshdVersion"
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -37,8 +37,6 @@ import org.springframework.integration.samples.cafe.OrderItem;
|
||||
import org.springframework.integration.scheduling.PollerMetadata;
|
||||
import org.springframework.integration.stream.CharacterStreamWritingMessageHandler;
|
||||
|
||||
import com.google.common.util.concurrent.Uninterruptibles;
|
||||
|
||||
/**
|
||||
* @author Artem Bilan
|
||||
* @since 3.0
|
||||
@@ -88,22 +86,24 @@ public class Application {
|
||||
.subFlowMapping(true, sf -> sf
|
||||
.channel(c -> c.queue(10))
|
||||
.publishSubscribeChannel(c -> c
|
||||
.subscribe(s -> s.handle(m -> Uninterruptibles.sleepUninterruptibly(1, TimeUnit.SECONDS)))
|
||||
.subscribe(s -> s.handle(m -> sleepUninterruptibly(1, TimeUnit.SECONDS)))
|
||||
.subscribe(sub -> sub
|
||||
.<OrderItem, String>transform(p ->
|
||||
Thread.currentThread().getName()
|
||||
+ " prepared cold drink #" + this.coldDrinkCounter.incrementAndGet()
|
||||
+ " for order #" + p.getOrderNumber() + ": " + p)
|
||||
Thread.currentThread().getName() +
|
||||
" prepared cold drink #" +
|
||||
this.coldDrinkCounter.incrementAndGet() +
|
||||
" for order #" + p.getOrderNumber() + ": " + p)
|
||||
.handle(m -> System.out.println(m.getPayload())))))
|
||||
.subFlowMapping(false, sf -> sf
|
||||
.channel(c -> c.queue(10))
|
||||
.publishSubscribeChannel(c -> c
|
||||
.subscribe(s -> s.handle(m -> Uninterruptibles.sleepUninterruptibly(5, TimeUnit.SECONDS)))
|
||||
.subscribe(s -> s.handle(m -> sleepUninterruptibly(5, TimeUnit.SECONDS)))
|
||||
.subscribe(sub -> sub
|
||||
.<OrderItem, String>transform(p ->
|
||||
Thread.currentThread().getName()
|
||||
+ " prepared hot drink #" + this.hotDrinkCounter.incrementAndGet()
|
||||
+ " for order #" + p.getOrderNumber() + ": " + p)
|
||||
Thread.currentThread().getName() +
|
||||
" prepared hot drink #" +
|
||||
this.hotDrinkCounter.incrementAndGet() +
|
||||
" for order #" + p.getOrderNumber() + ": " + p)
|
||||
.handle(m -> System.out.println(m.getPayload())))))
|
||||
.defaultOutputToParentFlow())
|
||||
.<OrderItem, Drink>transform(orderItem ->
|
||||
@@ -121,4 +121,19 @@ public class Application {
|
||||
.handle(CharacterStreamWritingMessageHandler.stdout());
|
||||
}
|
||||
|
||||
private static void sleepUninterruptibly(long sleepFor, TimeUnit unit) {
|
||||
boolean interrupted = false;
|
||||
try {
|
||||
unit.sleep(sleepFor);
|
||||
}
|
||||
catch (InterruptedException e) {
|
||||
interrupted = true;
|
||||
}
|
||||
finally {
|
||||
if (interrupted) {
|
||||
Thread.currentThread().interrupt();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -1,2 +1,3 @@
|
||||
version=5.1.1.BUILD-SNAPSHOT
|
||||
springBootVersion=2.1.3.RELEASE
|
||||
version=5.2.0.BUILD-SNAPSHOT
|
||||
springBootVersion=2.2.0.BUILD-SNAPSHOT
|
||||
org.gradle.jvmargs=-Xmx1536m
|
||||
|
||||
BIN
gradle/wrapper/gradle-wrapper.jar
vendored
BIN
gradle/wrapper/gradle-wrapper.jar
vendored
Binary file not shown.
2
gradle/wrapper/gradle-wrapper.properties
vendored
2
gradle/wrapper/gradle-wrapper.properties
vendored
@@ -1,5 +1,5 @@
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-4.9-bin.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-5.3-bin.zip
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
zipStorePath=wrapper/dists
|
||||
|
||||
18
gradlew
vendored
18
gradlew
vendored
@@ -1,5 +1,21 @@
|
||||
#!/usr/bin/env sh
|
||||
|
||||
#
|
||||
# Copyright 2015 the original author or authors.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
|
||||
##############################################################################
|
||||
##
|
||||
## Gradle start up script for UN*X
|
||||
@@ -28,7 +44,7 @@ APP_NAME="Gradle"
|
||||
APP_BASE_NAME=`basename "$0"`
|
||||
|
||||
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
|
||||
DEFAULT_JVM_OPTS=""
|
||||
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
|
||||
|
||||
# Use the maximum available, or set MAX_FD != -1 to use that value.
|
||||
MAX_FD="maximum"
|
||||
|
||||
18
gradlew.bat
vendored
18
gradlew.bat
vendored
@@ -1,3 +1,19 @@
|
||||
@rem
|
||||
@rem Copyright 2015 the original author or authors.
|
||||
@rem
|
||||
@rem Licensed under the Apache License, Version 2.0 (the "License");
|
||||
@rem you may not use this file except in compliance with the License.
|
||||
@rem You may obtain a copy of the License at
|
||||
@rem
|
||||
@rem http://www.apache.org/licenses/LICENSE-2.0
|
||||
@rem
|
||||
@rem Unless required by applicable law or agreed to in writing, software
|
||||
@rem distributed under the License is distributed on an "AS IS" BASIS,
|
||||
@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
@rem See the License for the specific language governing permissions and
|
||||
@rem limitations under the License.
|
||||
@rem
|
||||
|
||||
@if "%DEBUG%" == "" @echo off
|
||||
@rem ##########################################################################
|
||||
@rem
|
||||
@@ -14,7 +30,7 @@ set APP_BASE_NAME=%~n0
|
||||
set APP_HOME=%DIRNAME%
|
||||
|
||||
@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
|
||||
set DEFAULT_JVM_OPTS=
|
||||
set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m"
|
||||
|
||||
@rem Find java.exe
|
||||
if defined JAVA_HOME goto findJavaFromJavaHome
|
||||
|
||||
Reference in New Issue
Block a user