Commit 17328f96 authored by Peter van 't Hof's avatar Peter van 't Hof

Adding pipe executables again

parent d76d8c9c
......@@ -166,15 +166,21 @@ class WriteSummary(val parent: SummaryQScript) extends InProcessFunction with Co
db.createOrUpdateSetting(qscript.summaryRunId, pipelineId, None, None, None, ConfigUtils.mapToJson(q.summarySettings).nospaces)
}
(for (f <- qscript.functions.par) yield f match {
case f: BiopetJavaCommandLineFunction with Version =>
Some(db.createOrUpdateExecutable(qscript.summaryRunId, f.configNamespace, f.getVersion, f.getJavaVersion,
javaMd5 = BiopetCommandLineFunction.executableMd5Cache.get(f.executable), jarPath = Option(f.jarFile).map(_.getAbsolutePath)))
case f: BiopetCommandLineFunction with Version =>
Some(db.createOrUpdateExecutable(qscript.summaryRunId, f.configNamespace, f.getVersion, Option(f.executable)))
case f: Configurable with Version =>
Some(db.createOrUpdateExecutable(qscript.summaryRunId, f.configNamespace, f.getVersion))
case _ => None
val pipeFunctions = (for (f <- qscript.functions) yield f match {
case f: BiopetCommandLineFunction => f.pipesJobs
case _ => Nil
}).flatten
(for (f <- qscript.functions ++ pipeFunctions) yield {
f match {
case f: BiopetJavaCommandLineFunction with Version =>
List(db.createOrUpdateExecutable(qscript.summaryRunId, f.configNamespace, f.getVersion, f.getJavaVersion,
javaMd5 = BiopetCommandLineFunction.executableMd5Cache.get(f.executable), jarPath = Option(f.jarFile).map(_.getAbsolutePath)))
case f: BiopetCommandLineFunction with Version =>
List(db.createOrUpdateExecutable(qscript.summaryRunId, f.configNamespace, f.getVersion, Option(f.executable)))
case f: Configurable with Version =>
List(db.createOrUpdateExecutable(qscript.summaryRunId, f.configNamespace, f.getVersion))
case _ => List()
}
}).flatten.foreach(Await.ready(_, Duration.Inf))
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment