]
Tomaz Cerar reassigned WFCORE-2925:
-----------------------------------
Assignee: James Perkins (was: Tomaz Cerar)
Separate heap settings in standalone.conf and domain.conf from rest
of JAVA_OPTS
--------------------------------------------------------------------------------
Key: WFCORE-2925
URL:
https://issues.jboss.org/browse/WFCORE-2925
Project: WildFly Core
Issue Type: Enhancement
Components: Scripts
Reporter: Brian Stansberry
Assignee: James Perkins
Let's do this:
{code}
if [ "x$JBOSS_JAVA_SIZING" = "x" ]; then
JBOSS_JAVA_SIZING="-Xms64m -Xmx512m -XX:MetaspaceSize=96M
-XX:MaxMetaspaceSize=256m"
fi
if [ "x$JAVA_OPTS" = "x" ]; then
JAVA_OPTS="$JBOSS_JAVA_SIZING -Djava.net.preferIPv4Stack=true"
JAVA_OPTS="$JAVA_OPTS -Djboss.modules.system.pkgs=$JBOSS_MODULES_SYSTEM_PKGS
-Djava.awt.headless=true"
else
echo "JAVA_OPTS already set in environment; overriding default settings with
values: $JAVA_OPTS"
fi
{code}
That will allow users to easily control memory sizing by setting that specific env var
externally while still relying on our defaults for all the other fussy stuff in
JAVA_OPTS.
The JBOSS_JAVA_SIZING name was 20 secs of thought on my part.