Update Jira Data Center setenv.sh to respect system environment variables if set.

XMLWordPrintable

    • Type: Suggestion
    • Resolution: Unresolved
    • None
    • Component/s: Environment - Java
    • None

      Currently Jira Data Center does not consider if the server the application is hosted on already has certain JVM options such as JVM_MINIMUM_MEMORY, JVM_MAXIMUM_MEMORY, and  JVM_SUPPORT_RECOMMENDED_ARGS are already set. Instead it uses the static values defined in the setenv.sh/bat or windows service configuration.

      # The following 2 settings control the minimum and maximum given to the JIRA Java virtual machine.  In larger JIRA instances, the maximum amount will need to be increased.
      #
      JVM_MINIMUM_MEMORY="384m"
      JVM_MAXIMUM_MEMORY="2048m" 

       

      This same functionality is already implemented in Bitbucket Data Center in the _start-webapp.sh file as shown below:

       # The following 2 settings control the minimum and maximum memory allocated to the Java virtual machine.# For larger instances, the maximum amount will need to be increased.
      #
      if [ -z "${JVM_MINIMUM_MEMORY}" ]; then    JVM_MINIMUM_MEMORY=512m
      fi
      if [ -z "${JVM_MAXIMUM_MEMORY}" ]; then    JVM_MAXIMUM_MEMORY=1g
      fi 

       

      This request is to integrate the logic below into the setenv.sh file In Jira Data Center by default:

      if [ -z "$JVM_MINIMUM_MEMORY" ]; then
        JVM_MINIMUM_MEMORY="4096m"
      fi
      if [ -z "$JVM_MAXIMUM_MEMORY" ]; then
        JVM_MAXIMUM_MEMORY="4096m"
      fi
      if [ -z "$JVM_SUPPORT_RECOMMENDED_ARGS" ]; then
        JVM_SUPPORT_RECOMMENDED_ARGS="-XX:+UseG1GC" 

            Assignee:
            Unassigned
            Reporter:
            David McCoy
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: