[
https://issues.apache.org/jira/browse/HADOOP-1114?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12487817
]
Doug Cutting commented on HADOOP-1114:
--------------------------------------
Sorry. I'm coming to this rather late. But, for what it's worth, the prior
behavior was intentional. The CLASSPATH environment variable is fragile to
use. Folks can end up with lots of crazy stuff on it (e.g., conflicting
versions of libraries) that can break things in confusing ways. Thus it's
generally better to not rely on it.
Sun subtly discourages using the CLASSPATH environment variable:
http://java.sun.com/j2se/1.5.0/docs/tooldocs/windows/classpath.html#env%20var
Tomcat's startup scripts erase any pre-existing CLASSPATH values:
http://svn.apache.org/repos/asf/tomcat/container/tc5.5.x/catalina/src/bin/setclasspath.sh
However, Ant does respect it:
http://svn.apache.org/viewvc/ant/core/trunk/src/script/ant?view=markup
To add things to Hadoop's classpath one can simply add files to Hadoop's lib
directory (as folks typically add junit's jar to ant's lib). If that's
insufficient, I'd rather we add a HADOOP_CLASSPATH environment variable than
use the fragile, global CLASSPATH.
What do others think?
> bin/hadoop script clobbers CLASSPATH
> ------------------------------------
>
> Key: HADOOP-1114
> URL: https://issues.apache.org/jira/browse/HADOOP-1114
> Project: Hadoop
> Issue Type: Bug
> Components: scripts
> Affects Versions: 0.12.0
> Reporter: Michael Bieniosek
> Priority: Minor
> Fix For: 0.13.0
>
> Attachments: hadoop-no-clobber-classpath.patch
>
>
> The bin/hadoop script distributed with hadoop clobbers the user's CLASSPATH.
> This prevents ad-hoc appending to the CLASSPATH.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.