Timoney, Dan (dt5972) | 5877477 | 2019-08-21 16:50:54 -0400 | [diff] [blame] | 1 | #!/bin/sh |
| 2 | # |
| 3 | # Licensed to the Apache Software Foundation (ASF) under one or more |
| 4 | # contributor license agreements. See the NOTICE file distributed with |
| 5 | # this work for additional information regarding copyright ownership. |
| 6 | # The ASF licenses this file to You under the Apache License, Version 2.0 |
| 7 | # (the "License"); you may not use this file except in compliance with |
| 8 | # the License. You may obtain a copy of the License at |
| 9 | # |
| 10 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 11 | # |
| 12 | # Unless required by applicable law or agreed to in writing, software |
| 13 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 14 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 15 | # See the License for the specific language governing permissions and |
| 16 | # limitations under the License. |
| 17 | # |
| 18 | |
| 19 | # |
| 20 | # handle specific scripts; the SCRIPT_NAME is exactly the name of the Karaf |
| 21 | # script: client, instance, shell, start, status, stop, karaf |
| 22 | # |
| 23 | # if [ "${KARAF_SCRIPT}" == "SCRIPT_NAME" ]; then |
| 24 | # Actions go here... |
| 25 | # fi |
| 26 | |
| 27 | # |
| 28 | # general settings which should be applied for all scripts go here; please keep |
| 29 | # in mind that it is possible that scripts might be executed more than once, e.g. |
| 30 | # in example of the start script where the start script is executed first and the |
| 31 | # karaf script afterwards. |
| 32 | # |
| 33 | |
| 34 | # |
| 35 | # The following section shows the possible configuration options for the default |
| 36 | # karaf scripts |
| 37 | # |
| 38 | # export JAVA_HOME # Location of Java installation |
| 39 | # export JAVA_MIN_MEM # Minimum memory for the JVM |
| 40 | # export JAVA_MAX_MEM # Maximum memory for the JVM |
| 41 | # export JAVA_PERM_MEM # Minimum perm memory for the JVM |
| 42 | # export JAVA_MAX_PERM_MEM # Maximum perm memory for the JVM |
| 43 | # export EXTRA_JAVA_OPTS # Additional JVM options |
| 44 | # export KARAF_HOME # Karaf home folder |
| 45 | # export KARAF_DATA # Karaf data folder |
| 46 | # export KARAF_BASE # Karaf base folder |
| 47 | # export KARAF_ETC # Karaf etc folder |
| 48 | # export KARAF_SYSTEM_OPTS # First citizen Karaf options |
| 49 | # export KARAF_OPTS # Additional available Karaf options |
| 50 | # export KARAF_DEBUG # Enable debug mode |
| 51 | # export KARAF_REDIRECT # Enable/set the std/err redirection when using bin/start |
| 52 | # export KARAF_NOROOT # Prevent execution as root if set to true |
| 53 | if [ "x$JAVA_MAX_MEM" = "x" ]; then |
| 54 | export JAVA_MAX_MEM="2048m" |
| 55 | fi |
| 56 | |
| 57 | EXTRA_JAVA_OPTS: "-XX:+UseG1GC -XX:MaxGCPauseMillis={{.Values.config.odl.javaOptions.maxGCPauseMillis}} \ |
| 58 | -XX:ParallelGCThreads={{.Values.config.odl.javaOptions.parallelGCThreads}} -XX:+ParallelRefProcEnabled \ |
| 59 | -XX:+UseStringDeduplication -XX:+PrintGC -XX:+PrintGCDateStamps -XX:+PrintGCDetails \ |
| 60 | -XX:+PrintGCTimeStamps -XX:+UseGCLogFileRotation \ |
| 61 | -XX:NumberOfGCLogFiles={{.Values.config.odl.javaOptions.numberGGLogFiles}} -Xloggc:/var/log/onap/sdnc/gc-%t.log" |