From cfd8881289390c347fca257e6aa16568ec4a00ac Mon Sep 17 00:00:00 2001
From: Peter van 't Hof <p.j.van_t_hof@lumc.nl>
Date: Sun, 21 Aug 2016 21:18:14 +0200
Subject: [PATCH] Raised default residental memory for java jobs

---
 .../lumc/sasc/biopet/core/BiopetJavaCommandLineFunction.scala  | 1 +
 .../scala/nl/lumc/sasc/biopet/core/CommandLineResources.scala  | 3 ++-
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/biopet-core/src/main/scala/nl/lumc/sasc/biopet/core/BiopetJavaCommandLineFunction.scala b/biopet-core/src/main/scala/nl/lumc/sasc/biopet/core/BiopetJavaCommandLineFunction.scala
index 070056c6e..b6544969b 100644
--- a/biopet-core/src/main/scala/nl/lumc/sasc/biopet/core/BiopetJavaCommandLineFunction.scala
+++ b/biopet-core/src/main/scala/nl/lumc/sasc/biopet/core/BiopetJavaCommandLineFunction.scala
@@ -24,6 +24,7 @@ trait BiopetJavaCommandLineFunction extends JavaCommandLineFunction with BiopetC
   javaGCHeapFreeLimit = config("java_gc_heap_freelimit", default = 10)
   javaGCTimeLimit = config("java_gc_timelimit", default = 50)
 
+  override def defaultResidentFactor: Double = 1.5
   override def defaultVmemFactor: Double = 2.0
 
   /** Constructs java opts, this adds scala threads */
diff --git a/biopet-core/src/main/scala/nl/lumc/sasc/biopet/core/CommandLineResources.scala b/biopet-core/src/main/scala/nl/lumc/sasc/biopet/core/CommandLineResources.scala
index 92626a859..25374b435 100644
--- a/biopet-core/src/main/scala/nl/lumc/sasc/biopet/core/CommandLineResources.scala
+++ b/biopet-core/src/main/scala/nl/lumc/sasc/biopet/core/CommandLineResources.scala
@@ -37,9 +37,10 @@ trait CommandLineResources extends CommandLineFunction with Configurable {
   var vmem: Option[String] = config("vmem")
   def defaultCoreMemory: Double = 2.0
   def defaultVmemFactor: Double = 1.4
+  def defaultResidentFactor: Double = 1.2
   var vmemFactor: Double = config("vmem_factor", default = defaultVmemFactor)
 
-  var residentFactor: Double = config("resident_factor", default = 1.2)
+  var residentFactor: Double = config("resident_factor", default = defaultResidentFactor)
 
   private var _coreMemory: Double = 2.0
   def coreMemory = _coreMemory
-- 
GitLab