Skip to content

Commit 7676678

Browse files
committed
Fixes bug when resuming a pipeline that didn't complete any task
When a pipeline finishes without completing any task, the resume of this pipeline reised an exception related to uninitialized resolver. This commit fixes this bug by forcing a save operation of the redo log just after the pipeline is started.
1 parent 5293252 commit 7676678

File tree

8 files changed

+8
-6
lines changed

8 files changed

+8
-6
lines changed

cli/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
<parent>
1010
<groupId>org.sing_group</groupId>
1111
<artifactId>compi</artifactId>
12-
<version>1.4.1</version>
12+
<version>1.4.2</version>
1313
<!--
1414
WARNING: change version using (in the parent project):
1515
mvn versions:set -DnewVersion=[new_version]

cli/src/main/java/org/sing_group/compi/cli/commands/RunSpecificPipelineCommand.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,7 @@ public Set<String> getVariableNames() {
147147
}
148148

149149
public void setResolver(VariableResolver resolver) {
150+
System.out.println("setting resolver " + resolver);
150151
this.resolver = resolver;
151152
}
152153
}

core/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
<parent>
1111
<groupId>org.sing_group</groupId>
1212
<artifactId>compi</artifactId>
13-
<version>1.4.1</version>
13+
<version>1.4.2</version>
1414
<!--
1515
WARNING: change version using (in the parent project):
1616
mvn versions:set -DnewVersion=[new_version]

core/src/main/java/org/sing_group/compi/core/CompiApp.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -201,6 +201,7 @@ public CompiRunConfiguration getConfig() {
201201
*/
202202
public void run()
203203
throws IllegalArgumentException, ParserConfigurationException, SAXException, IOException, InterruptedException {
204+
this.executionLog.save();
204205
synchronized (syncMonitor) {
205206
while (!taskManager.getTasksLeft().isEmpty() && !this.stopRequested) {
206207

core/src/main/java/org/sing_group/compi/core/CompiExecutionLog.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ private static CompiExecutionLog load(final File pipelineFile, final File logFil
157157
}
158158
}
159159

160-
private void save() throws IOException {
160+
public void save() throws IOException {
161161
try (ObjectOutputStream oos = new ObjectOutputStream(new FileOutputStream(this.logFile))) {
162162
Pipeline p = this.config.getPipeline();
163163
this.config.setPipeline(null);

dk/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
<parent>
1010
<groupId>org.sing_group</groupId>
1111
<artifactId>compi</artifactId>
12-
<version>1.4.1</version>
12+
<version>1.4.2</version>
1313
<!--
1414
WARNING: change version using (in the parent project):
1515
mvn versions:set -DnewVersion=[new_version]

e2e-tests/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
<parent>
1010
<groupId>org.sing_group</groupId>
1111
<artifactId>compi</artifactId>
12-
<version>1.4.1</version>
12+
<version>1.4.2</version>
1313
<!--
1414
WARNING: change version using (in the parent project):
1515
mvn versions:set -DnewVersion=[new_version]

pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
<groupId>org.sing_group</groupId>
77
<artifactId>compi</artifactId>
88
<packaging>pom</packaging>
9-
<version>1.4.1</version>
9+
<version>1.4.2</version>
1010
<!-- WARNING: change version using (in the parent project): mvn versions:set -DnewVersion=[new_version] mvn versions:commit This will change the version
1111
in all modules at-once -->
1212

0 commit comments

Comments
 (0)