You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by cp...@apache.org on 2021/03/19 18:16:19 UTC

[lucene-solr] branch branch_8x updated: SOLR-11233: Add optional JAVA8_GC_LOG_FILE_OPTS for bin/solr. (#2284)

This is an automated email from the ASF dual-hosted git repository.

cpoerschke pushed a commit to branch branch_8x
in repository https://gitbox.apache.org/repos/asf/lucene-solr.git


The following commit(s) were added to refs/heads/branch_8x by this push:
     new 5d75fad  SOLR-11233: Add optional JAVA8_GC_LOG_FILE_OPTS for bin/solr. (#2284)
5d75fad is described below

commit 5d75fad1682fec418c00577fa37a8f7fd30524e0
Author: Christine Poerschke <cp...@apache.org>
AuthorDate: Fri Mar 19 18:15:57 2021 +0000

    SOLR-11233: Add optional JAVA8_GC_LOG_FILE_OPTS for bin/solr. (#2284)
---
 solr/CHANGES.txt | 2 ++
 solr/bin/solr    | 6 +++++-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/solr/CHANGES.txt b/solr/CHANGES.txt
index 7d80887..9d791cb 100644
--- a/solr/CHANGES.txt
+++ b/solr/CHANGES.txt
@@ -44,6 +44,8 @@ Improvements
 
 * SOLR-15154: Let Http2SolrClient pass Basic Auth credentials to all requests (Tomás Fernández Löbbe)
 
+* SOLR-11233: Add optional JAVA8_GC_LOG_FILE_OPTS for bin/solr. (Pranav Murugappan, Christine Poerschke)
+
 Optimizations
 ---------------------
 * SOLR-15079: Block Collapse - Faster collapse code when groups are co-located via Block Join style nested doc indexing.
diff --git a/solr/bin/solr b/solr/bin/solr
index 77886fe..32c5e60 100755
--- a/solr/bin/solr
+++ b/solr/bin/solr
@@ -2026,7 +2026,11 @@ if [ "$GC_LOG_OPTS" != "" ]; then
     if [ "$JAVA_VENDOR" == "IBM J9" ]; then
       gc_log_flag="-Xverbosegclog"
     fi
-    GC_LOG_OPTS+=("$gc_log_flag:$SOLR_LOGS_DIR/solr_gc.log" '-XX:+UseGCLogFileRotation' '-XX:NumberOfGCLogFiles=9' '-XX:GCLogFileSize=20M')
+    if [ -z ${JAVA8_GC_LOG_FILE_OPTS+x} ]; then
+      GC_LOG_OPTS+=("$gc_log_flag:$SOLR_LOGS_DIR/solr_gc.log" '-XX:+UseGCLogFileRotation' '-XX:NumberOfGCLogFiles=9' '-XX:GCLogFileSize=20M')
+    else
+      GC_LOG_OPTS+=($JAVA8_GC_LOG_FILE_OPTS)
+    fi
   else
     # http://openjdk.java.net/jeps/158
     for i in "${!GC_LOG_OPTS[@]}";