Skip to content

Commit 42b5186

Browse files
committed
CI fix
1 parent 668fa0e commit 42b5186

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

presto-native-execution/src/test/java/com/facebook/presto/nativeworker/ContainerQueryRunner.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -197,7 +197,7 @@ protected GenericContainer<?> createFunctionServer()
197197
.withNetworkAliases("presto-function-server")
198198
.withCopyFileToContainer(MountableFile.forHostPath(BASE_DIR + "/testcontainers/function-server/etc"), "/opt/function-server/etc")
199199
.withCopyFileToContainer(MountableFile.forHostPath(BASE_DIR + "/testcontainers/function-server/entrypoint.sh"), "/opt/entrypoint.sh")
200-
.waitingFor(Wait.forLogMessage(".* STARTED .*", 1))
200+
.waitingFor(Wait.forLogMessage(".*======== REMOTE FUNCTION SERVER STARTED at: .*", 1))
201201
.withStartupTimeout(Duration.ofSeconds(Long.parseLong(CONTAINER_TIMEOUT)))
202202
.withExposedPorts(functionServerPort);
203203
}

presto-native-execution/src/test/java/com/facebook/presto/nativeworker/ContainerQueryRunnerUtils.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,10 @@ public static void createCoordinatorEntryPointScript()
193193
{
194194
String scriptContent = "#!/bin/sh\n" +
195195
"set -e\n" +
196-
"$PRESTO_HOME/bin/launcher run\n";
196+
"trap 'kill -TERM $app 2>/dev/null' TERM\n" +
197+
"$PRESTO_HOME/bin/launcher run &\n" +
198+
"app=$!\n" +
199+
"wait $app";
197200
createScriptFile("testcontainers/coordinator/entrypoint.sh", scriptContent);
198201
}
199202

@@ -203,11 +206,8 @@ public static void createFunctionServerEntryPointScript()
203206
String scriptContent = "#!/bin/sh\n" +
204207
"set -e\n" +
205208
"trap 'kill -TERM $app 2>/dev/null' TERM\n\n" +
206-
"# Start Function Server\n" +
207209
"java -Dconfig=/opt/function-server/etc/config.properties " +
208210
"-jar /opt/presto-function-server-executable.jar &\n" +
209-
"app=$!\n\n" +
210-
"# Wait for Function Server process to exit\n" +
211211
"wait $app\n";
212212

213213
createScriptFile("testcontainers/function-server/entrypoint.sh", scriptContent);

0 commit comments

Comments
 (0)