Browse Source

Use version-specific documentation link in jvm.options file (#76323)

Mark Vieira 4 years ago
parent
commit
81616c2fb6
2 changed files with 5 additions and 4 deletions
  1. 2 1
      distribution/build.gradle
  2. 3 3
      distribution/src/config/jvm.options

+ 2 - 1
distribution/build.gradle

@@ -9,10 +9,10 @@
 
 import org.apache.tools.ant.filters.FixCrLfFilter
 import org.apache.tools.ant.filters.ReplaceTokens
+import org.elasticsearch.gradle.VersionProperties
 import org.elasticsearch.gradle.internal.ConcatFilesTask
 import org.elasticsearch.gradle.internal.DependenciesInfoTask
 import org.elasticsearch.gradle.internal.NoticeTask
-import org.elasticsearch.gradle.VersionProperties
 import org.elasticsearch.gradle.internal.info.BuildParams
 
 import java.nio.file.Files
@@ -486,6 +486,7 @@ subprojects {
     Map<String, Object> expansions = [
       'project.name': project.name,
       'project.version': version,
+      'project.minor.version': "${VersionProperties.elasticsearchVersion.major}.${VersionProperties.elasticsearchVersion.minor}",
 
       'path.conf': [
         'deb': '/etc/elasticsearch',

+ 3 - 3
distribution/src/config/jvm.options

@@ -9,7 +9,7 @@
 ## should create one or more files in the jvm.options.d
 ## directory containing your adjustments.
 ##
-## See https://www.elastic.co/guide/en/elasticsearch/reference/current/jvm-options.html
+## See https://www.elastic.co/guide/en/elasticsearch/reference/@project.minor.version@/jvm-options.html
 ## for more information.
 ##
 ################################################################
@@ -26,13 +26,13 @@
 ## required, it should be done through a file in jvm.options.d,
 ## which should be named with .options suffix, and the min and
 ## max should be set to the same value. For example, to set the
-## heap to 4 GB, create a new file in the jvm.options.d 
+## heap to 4 GB, create a new file in the jvm.options.d
 ## directory containing these lines:
 ##
 ## -Xms4g
 ## -Xmx4g
 ##
-## See https://www.elastic.co/guide/en/elasticsearch/reference/current/heap-size.html
+## See https://www.elastic.co/guide/en/elasticsearch/reference/@project.minor.version@/heap-size.html
 ## for more information
 ##
 ################################################################