-
Notifications
You must be signed in to change notification settings - Fork 25.6k
Description
Awhile ago, we stopped honoring generic environment variables. That is environment variables that have some convention in the community (but are not actually built in to the JVM). For example, we honor our own ES_JAVA_OPTS over JAVA_OPTS. A primary reason that we do this is to avoid conflicts where a user has set some values in JAVA_OPTS that they wouldn't want applying to Elasticsearch. Having a dedicated environment variable avoids surprises and actually simplifies administration (since it's rare to expect there to be a common JVM flag to apply to every JVM that might execute on a system).
Yet, we still honor JAVA_HOME which has the same pitfalls, where the system could have JAVA_HOME configured despite a user not necessarily wanting to use the system Java with Elasticsearch.
Should we drop honoring JAVA_HOME to give the user explicit control over which Java is used via a dedicated environment variable ES_JAVA_HOME (or, the bundled JDK if it is not set)?