zhc00 commented on code in PR #3976:
URL: https://github.com/apache/shenyu/pull/3976#discussion_r977144458


##########
shenyu-dist/shenyu-admin-dist/entrypoint.sh:
##########
@@ -18,4 +18,18 @@
 
 [[ -d ./conf-ext ]] && cp -f ./conf-ext/* ./conf
 
-/bin/sh ${LOCAL_PATH}/bin/start.sh && tail -f 
${LOCAL_PATH}/logs/shenyu-admin.log
\ No newline at end of file
+DEPLOY_DIR=$(pwd)
+EXT_LIB=${DEPLOY_DIR}/ext-lib
+
+CLASS_PATH=.:${DEPLOY_DIR}/conf:${DEPLOY_DIR}/lib/*:${EXT_LIB}/*
+if [ -z "${ADMIN_JVM}" ]; then
+    JAVA_OPTS=" -server -Xmx2g -Xms2g -Xmn1g -Xss256k -XX:+DisableExplicitGC  
-XX:LargePageSizeInBytes=128m"
+    JAVA_OPTS="${JAVA_OPTS} -XX:+UseFastAccessorMethods  
-XX:+UseConcMarkSweepGC -XX:+CMSParallelRemarkEnabled 
-XX:+UseCMSInitiatingOccupancyOnly  -XX:CMSInitiatingOccupancyFraction=70"
+    echo "Use default jvm options: $JAVA_OPTS"
+else
+    JAVA_OPTS=${ADMIN_JVM}
+    echo "Start with the environment variable JAVA_OPTS set: $JAVA_OPTS"
+fi
+
+echo "Starting the Apache ShenYu Admin ..."
+${JAVA_HOME}/bin/java ${JAVA_OPTS} -classpath ${CLASS_PATH} 
org.apache.shenyu.admin.ShenyuAdminBootstrap

Review Comment:
   first, `start.sh` will log to the file system.
   then, this is simpler. Because we pinned the jre version.
   



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to