Skip to content

Commit a24f0dd

Browse files
authored
Update runtime (ibm-functions#146)
* Update credentials used for test. * Update local db2 tests. - Add some more messages to the output. - Increase wait time until database instance is up. - Use fixed ibmcom/db2 image tag instead of latest (latest can cause build breaks due to changes).
1 parent a550783 commit a24f0dd

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

tests/credentials.json.enc

96 Bytes
Binary file not shown.

tests/src/test/scala/actionContainers/IBMPythonActionDB2Tests.scala

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ class IBMPythonActionDB2Tests extends TestHelpers with WskTestHelpers with Befor
6868
6969
*/
7070
def sleepUntilContainerRunning() {
71-
var counter = 48; // 48*5s=240s -> 4 minutes
71+
var counter = 48; // 48*10s=480s -> 8 minutes
7272
var running = false;
7373
do {
7474
counter = counter - 1
@@ -87,9 +87,11 @@ class IBMPythonActionDB2Tests extends TestHelpers with WskTestHelpers with Befor
8787
". /database/config/db2inst1/.bashrc && db2 list active databases")
8888

8989
if ((isdb2Running.exitCode != 0) && (isdb2Running.exitCode != 2)) {
90-
Thread.sleep(5000)
90+
println("Wait some more time...")
91+
Thread.sleep(10000)
9192
} else {
9293
running = true;
94+
println("Database seems to be up, now.")
9395
}
9496
} while (counter > 0 && running == false);
9597
}
@@ -99,6 +101,7 @@ class IBMPythonActionDB2Tests extends TestHelpers with WskTestHelpers with Befor
99101

100102
TestUtils.runCmd(TestUtils.DONTCARE_EXIT, new File("."), "docker", "kill", db2containerName)
101103
TestUtils.runCmd(TestUtils.DONTCARE_EXIT, new File("."), "docker", "rm", db2containerName)
104+
println("Creating local db2 instance, might take up to 5 minutes...")
102105
TestUtils.runCmd(
103106
0,
104107
new File("."),
@@ -119,7 +122,7 @@ class IBMPythonActionDB2Tests extends TestHelpers with WskTestHelpers with Befor
119122
"LICENSE=accept",
120123
"--name",
121124
db2containerName,
122-
"ibmcom/db2")
125+
"ibmcom/db2:11.5.5.1")
123126

124127
sleepUntilContainerRunning()
125128

@@ -131,7 +134,7 @@ class IBMPythonActionDB2Tests extends TestHelpers with WskTestHelpers with Befor
131134
"cp",
132135
db2dir + "setup.sql",
133136
db2containerName + ":/database/config/db2inst1/setup.sql")
134-
println("Creating db2 database, might take up to 5 minutes")
137+
println("Creating db2 database, might take up to 5 minutes.")
135138
TestUtils.runCmd(
136139
0,
137140
new File("."),

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy