Return-Path: X-Original-To: apmail-hadoop-common-dev-archive@www.apache.org Delivered-To: apmail-hadoop-common-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 84BCF8FBC for ; Wed, 10 Aug 2011 18:11:53 +0000 (UTC) Received: (qmail 41771 invoked by uid 500); 10 Aug 2011 18:11:50 -0000 Delivered-To: apmail-hadoop-common-dev-archive@hadoop.apache.org Received: (qmail 41038 invoked by uid 500); 10 Aug 2011 18:11:49 -0000 Mailing-List: contact common-dev-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: common-dev@hadoop.apache.org Delivered-To: mailing list common-dev@hadoop.apache.org Received: (qmail 40975 invoked by uid 500); 10 Aug 2011 18:11:49 -0000 Delivered-To: apmail-hadoop-core-dev@hadoop.apache.org Received: (qmail 40970 invoked by uid 99); 10 Aug 2011 18:11:48 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 10 Aug 2011 18:11:48 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of tucu@cloudera.com designates 209.85.214.48 as permitted sender) Received: from [209.85.214.48] (HELO mail-bw0-f48.google.com) (209.85.214.48) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 10 Aug 2011 18:11:42 +0000 Received: by bkat2 with SMTP id t2so692634bka.35 for ; Wed, 10 Aug 2011 11:11:16 -0700 (PDT) Received: by 10.204.129.9 with SMTP id m9mr2106401bks.346.1312999876504; Wed, 10 Aug 2011 11:11:16 -0700 (PDT) MIME-Version: 1.0 Received: by 10.204.143.3 with HTTP; Wed, 10 Aug 2011 11:10:46 -0700 (PDT) In-Reply-To: <2104E79E-2610-48AD-A9D8-78E6D181622B@gmail.com> References: <167864ED-EBEE-4C37-8626-86859ED10599@gmail.com> <2104E79E-2610-48AD-A9D8-78E6D181622B@gmail.com> From: Alejandro Abdelnur Date: Wed, 10 Aug 2011 11:10:46 -0700 Message-ID: Subject: Re: hadoop JARs not in lib/ directory of layout To: core-dev , common-dev@hadoop.apache.org Content-Type: multipart/alternative; boundary=0015173fed823aab1404aa2a9b5c --0015173fed823aab1404aa2a9b5c Content-Type: text/plain; charset=ISO-8859-1 Eric, I'd argue that including the JAR as you suggest will most likely break because of required dependencies of the Hadoop JAR that may not be part of HBase (ie the jackson JARs). But if you want to still do that you can always include the jar from the lib directory, for example: $HBASE_PREFIX/share/hbase/hbase*.jar:$HBASE_PREFIX/share/hbase/lib/*.jar:$HADOOP_PREFIX/share/hadoop/ *lib/*hadoop-*.jar Thoughts? Thanks. Alejandro On Thu, Aug 4, 2011 at 3:47 PM, Eric Yang wrote: > It is easier to write shell script to import jar files by directory instead > of explicitly reference to a few jars with specific versions. > > The common use case is: > > HBase needs to use hadoop jar files, but HBase depends on more recent > version of log4j. The construction of the class path would be: > > > $HBASE_PREFIX/share/hbase/hbase*.jar:$HBASE_PREFIX/share/hbase/lib/*.jar:$HADOOP_PREFIX/share/hadoop/*.jar > > This provides a way to segment the library loading with least amount of > scripting and loosely coupled. > > regards, > Eric > > On Aug 4, 2011, at 2:40 PM, Alejandro Abdelnur wrote: > > > [moving to core-dev@, general@ BCCed] > > > > Eric, > > > > Even if the JAR is in lib/ you could import/use that JAR only. > > > > How would you use Hadoop JARs without its dependencies? Many things will > > break unless you add the dependency JARs. > > > > Granted, there are JARs that are used by Hadoop server side only > > (JT/NN/TT/DN/SNN), but that is a different thing. Having a client side > set > > of JARs would help handle this (MAPREDUCE-1638). > > > > Thoughts? > > > > Thanks. > > > > Alejandro > > > > On Thu, Aug 4, 2011 at 1:14 PM, Eric Yang wrote: > > > >> The jar files placement outside of lib directory is to ensure the > project > >> generated jar files are not mixed with it's dependencies. > >> Hence, if another project tries to import current project's jar files > >> without dependencies, it is possible to do so. > >> > >> regards, > >> Eric > >> > >> On Aug 4, 2011, at 11:03 AM, Alejandro Abdelnur wrote: > >> > >>> What is the rationale for having the hadoop JARs outside of the lib/ > >>> directory? > >>> > >>> It would definitely simplify packaging configuration if they are under > >> lib/ > >>> as well. > >>> > >>> Any objection to it? > >>> > >>> Thanks. > >>> > >>> Alejandro > >> > >> > > --0015173fed823aab1404aa2a9b5c--