Fixes GemFire client/server integratione tests issue when setting JAVA_TOOL_OPTIONS env var
Fixes gh-727
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
apply from: JAVA_GRADLE
|
||||
apply from: SAMPLE_GRADLE
|
||||
apply from: TOMCAT_7_GRADLE
|
||||
apply plugin: "application"
|
||||
apply from: SAMPLE_GRADLE
|
||||
|
||||
dependencies {
|
||||
compile project(':spring-session-data-gemfire'),
|
||||
@@ -37,7 +37,10 @@ task availablePort() {
|
||||
|
||||
task runGemFireServer(dependsOn: availablePort) {
|
||||
doLast {
|
||||
println 'STARTING GEMFIRE SERVER...'
|
||||
println "Starting GemFire Server on port [$port]..."
|
||||
|
||||
def out = new StringBuilder()
|
||||
def err = new StringBuilder()
|
||||
|
||||
String classpath = sourceSets.main.runtimeClasspath.collect { it }.join(File.pathSeparator)
|
||||
|
||||
@@ -50,14 +53,16 @@ task runGemFireServer(dependsOn: availablePort) {
|
||||
//println commandLine
|
||||
|
||||
process = commandLine.execute()
|
||||
process.in.close()
|
||||
process.out.close()
|
||||
process.err.close()
|
||||
|
||||
process.consumeProcessOutput(out, err)
|
||||
|
||||
//println 'OUT: ' + out
|
||||
//println 'ERR: ' + err
|
||||
}
|
||||
}
|
||||
|
||||
integrationTest.doLast {
|
||||
println 'STOPPING GEMFIRE SERVER...'
|
||||
println 'Stopping GemFire Server...'
|
||||
process?.destroyForcibly()
|
||||
}
|
||||
|
||||
|
||||
@@ -27,8 +27,7 @@ import org.springframework.context.annotation.ImportResource;
|
||||
public class Application {
|
||||
|
||||
public static void main(final String[] args) {
|
||||
new AnnotationConfigApplicationContext(Application.class)
|
||||
.registerShutdownHook();
|
||||
new AnnotationConfigApplicationContext(Application.class).registerShutdownHook();
|
||||
}
|
||||
}
|
||||
// tag::end[]
|
||||
|
||||
Reference in New Issue
Block a user