[ 
https://issues.apache.org/jira/browse/ZOOKEEPER-3766?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

ASF GitHub Bot updated ZOOKEEPER-3766:
--------------------------------------
    Labels: pull-request-available  (was: )

> zkServer and other scripts should export CLASSPATH rather than use -cp
> ----------------------------------------------------------------------
>
>                 Key: ZOOKEEPER-3766
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-3766
>             Project: ZooKeeper
>          Issue Type: Improvement
>          Components: scripts
>    Affects Versions: 3.5.7
>            Reporter: Christopher Tubbs
>            Priority: Critical
>              Labels: pull-request-available
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> ZooKeeper's launch scripts use `-cp` to pass the class path to Java when 
> launching. This creates insanely large command-lines which are completely 
> unnecessary.
> Java respects the CLASSPATH environment variable, and this is how the class 
> path should be passed to Java when the process launches.
> So, instead of doing {{java -cp $CLASSPATH ...}}, the scripts should be doing 
> {{export CLASSPATH; java ...}}.
> The long command-lines make it difficult to troubleshoot, or view running 
> process lists in tools like top, htop, ps, but also make it impossible to 
> search and manage using tools like pgrep and pkill, which can only search for 
> the first 4096 characters in the command-line. (See 
> https://github.com/apache/fluo-uno/issues/243#issuecomment-601553260 for a 
> specific issue involving this limit caused by ZK's scripts.)



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to