RIPE-NCC / rpki-validator

Other
64 stars 20 forks source link

I added GC_OPTIONS="-XX:-UseGCOverheadLimit" and it was happier in docker #46

Open ggm-at-apnic opened 5 years ago

ggm-at-apnic commented 5 years ago

I found that running Docker on my OSX, and in Kubernetes I survived better if I made the GC run a bit differently. This patch seemed to help.

This is horrible, pragmatic patching: I don't understand what the implications are for this java tuning variable, so I think this needs more thought.

-George

--- rpki-validator.sh.orig      2019-04-17 08:23:15.000000000 +1000
+++ rpki-validator.sh   2019-04-17 15:54:49.000000000 +1000
@@ -191,8 +191,9 @@

     CLASSPATH=:"$LIB_DIR/*"
     MEM_OPTIONS="-Xms$JVM_XMS -Xmx$JVM_XMX"
+    GC_OPTIONS="-XX:-UseGCOverheadLimit"

-    CMDLINE="${JAVA_CMD} ${JVM_OPTIONS} ${MEM_OPTIONS} ${JAVA_OPTS} \
+    CMDLINE="${JAVA_CMD} ${JVM_OPTIONS} ${MEM_OPTIONS} ${GC_OPTIONS} ${JAVA_OPTS} \
              -Dapp.name=${APP_NAME} -Dconfig.file=${CONFIG_FILE} \
              -classpath ${CLASSPATH} net.ripe.rpki.validator.config.Main"
wibisono commented 5 years ago

Thank you for sharing this, we are working to find a cleaner solution to reduce required garbage collection (less unintended object retention), so we can avoid to have to use this patch.

-- sorry was not paying attention that this is version 2. My previous comment was for version 3.