rickchengx commented on PR #12118: URL: https://github.com/apache/dolphinscheduler/pull/12118#issuecomment-1296502744
Hi, @caishunfeng @SbloodyS @DarkAssassinator **It seems that we need to discuss how to check the status of the server, `pid-file` or `grep <conditions>`.** 1. Now `dolphinscheduler-daemon.sh` uses `pid-file` to kill the process rather than getting the process pid through `grep <conditions>` and then killing it. This is a common approach on linux. 2. I think that checking the server status should be consistent with killing the process. So maybe it's better to check the server status through `pid-file`. 3. And also `grep <conditions>` method has no complete guarantee that other processes do not meet the filter criteria. For example, some non-ds process that may also contains the "java" & "$DOLPHINSCHEDULER_HOME" & "$CLASS". This will cause the script to misjudge the status of the server. 4. And $CLASS is now hardcoded, the class name maybe changed. And using the `pid-file` can avoid this hardcoded problem. <img width="741" alt="image" src="https://user-images.githubusercontent.com/38122586/198926803-70c111c5-1dc7-4e13-ad58-bf9fdd387b69.png"> -- 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]
