Return-Path: X-Original-To: apmail-hadoop-hdfs-user-archive@minotaur.apache.org Delivered-To: apmail-hadoop-hdfs-user-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 66E87D6D7 for ; Thu, 30 Aug 2012 10:36:20 +0000 (UTC) Received: (qmail 91888 invoked by uid 500); 30 Aug 2012 10:36:15 -0000 Delivered-To: apmail-hadoop-hdfs-user-archive@hadoop.apache.org Received: (qmail 91771 invoked by uid 500); 30 Aug 2012 10:36:15 -0000 Mailing-List: contact user-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@hadoop.apache.org Delivered-To: mailing list user@hadoop.apache.org Received: (qmail 91678 invoked by uid 99); 30 Aug 2012 10:36:14 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 30 Aug 2012 10:36:14 +0000 X-ASF-Spam-Status: No, hits=3.2 required=5.0 tests=FREEMAIL_REPLY,FSL_RCVD_USER,HTML_IMAGE_ONLY_28,HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of yhemanth@gmail.com designates 74.125.82.48 as permitted sender) Received: from [74.125.82.48] (HELO mail-wg0-f48.google.com) (74.125.82.48) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 30 Aug 2012 10:36:08 +0000 Received: by wgbdq11 with SMTP id dq11so1177114wgb.29 for ; Thu, 30 Aug 2012 03:35:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:x-goomoji-body:date:message-id :subject:from:to:content-type; bh=EpS7Asm2Z04HI3i2VzfMOOPzXwXrUKMLr/cq7NPu50Q=; b=LwFDXOZSblJhUNubVIO0xW/FSb7X+B33NHY7SIKYK+3EjcV81Eg+HOI/I2if/dNh6T n1O4tTq6oxz7O6mn+n9Ehe86mlx5iP0JhcmZP82qoYPq74RgV148MWH6LWezKWHxkfpf vlyX62+9RyaOeZjkZF06HKMHj1ANibBkjKDshSh3hgaoqWF1KMQIr7TgRJcNjIXy4Xkl /viViZE5ftjcssD5f+Dvm1X0WpqS565T5fDSbWmG5u5aBDXBRfbMDK/FZ5gqz+rP4VaW 6ecq/G7u/4bET/shxrubZQqjecGuxBvf7Yez4fqeHHCI1ygbrGEr8zwxMIAqQa+TS3tz PmAQ== MIME-Version: 1.0 Received: by 10.216.68.2 with SMTP id k2mr2601736wed.69.1346322946961; Thu, 30 Aug 2012 03:35:46 -0700 (PDT) Received: by 10.223.76.20 with HTTP; Thu, 30 Aug 2012 03:35:46 -0700 (PDT) In-Reply-To: References: X-Goomoji-Body: true Date: Thu, 30 Aug 2012 16:05:46 +0530 Message-ID: Subject: Re: Integrating hadoop with java UI application deployed on tomcat From: Hemanth Yamijala To: user@hadoop.apache.org Content-Type: multipart/related; boundary=000e0ce0d04801b09704c8793d0e X-Virus-Checked: Checked by ClamAV on apache.org --000e0ce0d04801b09704c8793d0e Content-Type: multipart/alternative; boundary=000e0ce0d04801b09304c8793d0d --000e0ce0d04801b09304c8793d0d Content-Type: text/plain; charset=ISO-8859-1 Hi, The error is talking about hadoop configuration. So probably you need to put the hadoop core jar in the lib folder. That said, there might be other dependencies you might need as well. But you can try it out once. Thanks hemanth On Thu, Aug 30, 2012 at 3:53 PM, Visioner Sadak wrote: > Tried puttin it still same error [?] > > > On Thu, Aug 30, 2012 at 3:06 PM, John Hancock wrote: > >> You might need to put the apache commons configuration library jar in >> web-inf/lib to clear this error. >> >> >> On Thu, Aug 30, 2012 at 4:32 AM, Visioner Sadak > > wrote: >> >>> Hi, >>> >>> I have a WAR which is deployed on tomcat server the WAR contains some >>> java classes which uploads files, will i be able to upload directly in to >>> hadoop iam using the below code in one of my java class >>> >>> Configuration hadoopConf=new Configuration(); >>> //get the default associated file system >>> FileSystem fileSystem=FileSystem.get(hadoopConf); >>> // HarFileSystem harFileSystem= new HarFileSystem(fileSystem); >>> //copy from lfs to hdfs >>> fileSystem.copyFromLocalFile(new Path("E:/test/GANI.jpg"),new >>> Path("/user/TestDir/")); >>> >>> but its throwing up this error >>> >>> java.lang.NoClassDefFoundError: org/apache/hadoop/conf/Configuration >>> >>> when this code is run independtly using a single jar deployed in hadoop >>> bin it wrks fine >>> >>> >>> >> >> > --000e0ce0d04801b09304c8793d0d Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hi,

The error is talking about hadoop configuration. So = probably you need to put the hadoop core jar in the lib folder. That said, = there might be other dependencies you might need as well. But you can try i= t out once.

Thanks
hemanth

On Thu, Aug 30, 2012 at 3:53 PM, Visioner Sadak <<= a href=3D"mailto:visioner.sadak@gmail.com" target=3D"_blank">visioner.sadak= @gmail.com> wrote:
Tried puttin it still same error


On Thu, Aug 30, 2012 at 3:06 PM, John Hancock <jhancock1975@gmail.com> wrote:
You might need to put the apache comm= ons configuration library jar in web-inf/lib to clear this error.=20


On Thu, Aug 30, 2012 at 4:32 AM, Visioner Sadak = <visioner.sadak@gmail.com> wrote:
Hi,
=A0
=A0 I have a WAR which is deployed on tomcat server the WAR contains s= ome java classes which uploads files, will i be able to upload directly in = to hadoop iam using the below code in one of my java class
=A0
=A0=A0=A0=A0=A0=A0 Configuration hadoopConf=3Dnew Configuration();
= =A0=A0=A0=A0=A0=A0=A0 //get the default associated file system
=A0=A0=A0= =A0=A0=A0 FileSystem fileSystem=3DFileSystem.get(hadoopConf);=A0=A0=A0=A0= =A0=A0=A0
=A0=A0=A0=A0=A0=A0 // HarFileSystem harFileSystem=3D new HarF= ileSystem(fileSystem);
=A0=A0=A0=A0=A0=A0=A0 //copy from lfs to hdfs
=A0=A0=A0=A0=A0=A0 fileSys= tem.copyFromLocalFile(new Path("E:/test/GANI.jpg"),new Path("= ;/user/TestDir/"));
=A0
but its throwing up this error

java.lang.NoClassDefFoundError: org/apache/hadoop/conf/Configuration

when this code is run independtly using a single jar deployed in hadoop = bin it wrks fine

=A0




--000e0ce0d04801b09304c8793d0d-- --000e0ce0d04801b09704c8793d0e Content-Type: image/gif; name="33F.gif" Content-Transfer-Encoding: base64 X-Attachment-Id: 33F@goomoji.gmail Content-ID: <33F@goomoji.gmail> R0lGODlhDAAMAKIFAABGdPT7/wAAAFuw7MPj9////wAAAAAAACH5BAEAAAUALAAAAAAMAAwAAAMp WLPcGjDKFYi9l+KtCbCfpQGCJYSaUBKqOFRb9l5A6MKh3cXEoDTAQgIAOw== --000e0ce0d04801b09704c8793d0e--