majialoong opened a new issue, #10171: URL: https://github.com/apache/rocketmq/issues/10171
### Before Creating the Enhancement Request - [x] I have confirmed that this should be classified as an enhancement rather than a bug/feature. ### Summary `runbroker.sh` and `runserver.sh` ignore user set `JAVA_HOME` on Linux, always overriding it with `which javac `result. This was already fixed in `tools.sh` (https://github.com/apache/rocketmq/issues/7786), but these two scripts were not updated. ### Motivation This issue was already fixed in `tools.sh` (https://github.com/apache/rocketmq/issues/7786), but `runbroker.sh` and `runserver.sh` were not updated. Users deploying on Linux with a custom `JAVA_HOME` may silently get the wrong JDK. ### Describe the Solution You'd Like Move the `JAVA_HOME` check before the case statement in `find_java_home()`, consistent with `tools.sh`. ### Describe Alternatives You've Considered No. The proposed fix aligns with the existing approach already adopted in `tools.sh`. ### Additional Context _No response_ -- 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]
