Return-Path: Delivered-To: apmail-hadoop-hive-user-archive@minotaur.apache.org Received: (qmail 35834 invoked from network); 21 Oct 2009 05:19:10 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 21 Oct 2009 05:19:10 -0000 Received: (qmail 36636 invoked by uid 500); 21 Oct 2009 05:19:10 -0000 Delivered-To: apmail-hadoop-hive-user-archive@hadoop.apache.org Received: (qmail 36573 invoked by uid 500); 21 Oct 2009 05:19:09 -0000 Mailing-List: contact hive-user-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: hive-user@hadoop.apache.org Delivered-To: mailing list hive-user@hadoop.apache.org Received: (qmail 36558 invoked by uid 99); 21 Oct 2009 05:19:09 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 21 Oct 2009 05:19:09 +0000 X-ASF-Spam-Status: No, hits=-2.6 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of arijit72@gmail.com designates 209.85.216.204 as permitted sender) Received: from [209.85.216.204] (HELO mail-px0-f204.google.com) (209.85.216.204) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 21 Oct 2009 05:19:06 +0000 Received: by pxi42 with SMTP id 42so4803194pxi.5 for ; Tue, 20 Oct 2009 22:18:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type :content-transfer-encoding; bh=WDBw5rfv7dDplfUn80lQX+443cV9ja3HxCEFW5JtHjo=; b=gwPcvJXRMbeg8JgBEYUqw8I0Iakm0n9xjd1FU/lR7u4SkRzMNVxhuObRddxqQGi5ll jESaX8yTB906sLlxoyyyZ9id/4PDZDPqtVJujxhG6Pwo729gZLUrisk79y7jff2reTaK zT0AZZYxdoa6L+ngJicmTJQhguFpXJk5/tYQ0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; b=WzdrKVGHo21WJyDlz2JJHp+WDdAdJ55DZg/iQWrz9+4SUmi1LsaLbOXhkAoSRvaiGH vGzFXAeMZIjCMkLp64n45Br53CCdiUW3MCqtUcPuIh/lfZM7sYX8Yp5ydxt0tVo+sQw4 z+q8gKlsmE23GzDmjfvZ+tpNiMzogfo4BDeOQ= MIME-Version: 1.0 Received: by 10.142.9.31 with SMTP id 31mr540386wfi.96.1256102326560; Tue, 20 Oct 2009 22:18:46 -0700 (PDT) In-Reply-To: <4cfc4d490910202135j406ff959n8a7ce06192024a2d@mail.gmail.com> References: <4cfc4d490910200154i3b58415bsfdaf95af406fcb07@mail.gmail.com> <4cfc4d490910200210p37f0df79lbfd3738ff6ed7165@mail.gmail.com> <4cfc4d490910200414n5524e805s43eb849708e4cd25@mail.gmail.com> <449b48760910200927w5cf423e6qe49d03a54b721d55@mail.gmail.com> <4cfc4d490910202135j406ff959n8a7ce06192024a2d@mail.gmail.com> Date: Wed, 21 Oct 2009 10:48:46 +0530 Message-ID: <4cfc4d490910202218i6c07e2eew437489d93419f239@mail.gmail.com> Subject: Re: Hive query web service From: Arijit Mukherjee To: hive-user@hadoop.apache.org, billgraham@gmail.com Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Update: I did a clean/build/deploy - the config files are within the Web Service WEB-INF/classes folder, and the libraries (including the jpox ones) are inside WEB-INF/lib - which are standard for any web application. But the config related exception is still there:-(( Arijit 2009/10/21 Arijit Mukherjee : > Thanx Bill. I copied the jpox jars from the 0.3.0 distribution and > added them to the web service archive, and they are in the classpath, > but the config related exception is still there. Let me do a clean > build/deploy and I'll get back again. > > Arijit > > 2009/10/20 Bill Graham : >> The Hive JDBC client can run in two different modes: standalone and >> embedded. >> >> Standalone mode is where the client connects to a separate standalone >> HiveServer by specifying the host:port of the server in the jdbc URL lik= e >> this: jdbc:hive://localhost:10000/default. In this case the hive configs= are >> not needed by the client, since the client is making thrift requests to = the >> server which has the Hive configs. the Hive Server knows how to resolve = the >> metastore. >> >> Embedded mode is where the JDBC client "connects to itself" so to speak >> using a JDBC url like this: jdbc:hive://. It's as if the client is runni= ng >> an embedded server that only it communicates with. In this case the clie= nt >> needs the Hive configs since it needs to resolve the metastore, amongst >> other things. The metastore dependency in this case is what will cause y= ou >> to see jpox errors appear if those jars aren't found. >> >> HTH, >> Bill >> >> On Tue, Oct 20, 2009 at 4:14 AM, Arijit Mukherjee >> wrote: >>> >>> BTW - the service is working though, in spite of those exceptions. I'm >>> able to run queries and get results. >>> >>> Arijit >>> >>> 2009/10/20 Arijit Mukherjee : >>> > I created a hive-site.xml using the outline given in the Hive Web >>> > Interface tutorial - now that file is in the classpath of the Web >>> > Service - and the service can find the file. But, now there's another >>> > exception - >>> > >>> > 2009-10-20 14:27:30,914 DEBUG [httpSSLWorkerThread-14854-0] >>> > HiveQueryService - connecting to Hive using URL: >>> > jdbc:hive://localhost:10000/default >>> > 2009-10-20 14:27:30,969 DEBUG [httpSSLWorkerThread-14854-0] >>> > Configuration - java.io.IOException: config() >>> > =A0 =A0 =A0 =A0at >>> > org.apache.hadoop.conf.Configuration.(Configuration.java:176) >>> > =A0 =A0 =A0 =A0at >>> > org.apache.hadoop.conf.Configuration.(Configuration.java:164) >>> > =A0 =A0 =A0 =A0at org.apache.hadoop.hive.conf.HiveConf.(HiveCon= f.java:287) >>> > =A0 =A0 =A0 =A0at >>> > org.apache.hadoop.hive.jdbc.HiveConnection.(HiveConnection.java= :63) >>> > =A0 =A0 =A0 =A0at >>> > org.apache.hadoop.hive.jdbc.HiveDriver.connect(HiveDriver.java:109) >>> > =A0 =A0 =A0 =A0at java.sql.DriverManager.getConnection(DriverManager.= java:582) >>> > =A0 =A0 =A0 =A0at java.sql.DriverManager.getConnection(DriverManager.= java:185) >>> > =A0 =A0 =A0 =A0at >>> > com.ctva.poc.hive.service.HiveQueryService.getConnection(HiveQuerySer= vice.java:134) >>> > =A0 =A0 =A0 =A0at >>> > com.ctva.poc.hive.service.HiveQueryService.connectDB(HiveQueryService= .java:43) >>> > >>> > Apparently, something goes wrong during the config routine. Do I need >>> > something more within the service? >>> > >>> > Regards >>> > Arijit >>> > >>> > 2009/10/20 Arijit Mukherjee : >>> >> Hi >>> >> >>> >> I'm trying to create a Web Service which will access Hive (0.4.0 >>> >> release) using JDBC. I used to sample JDBC code from the wiki >>> >> >>> >> (http://wiki.apache.org/hadoop/Hive/HiveClient#head-fd2d8ae9e17fdc3d= 9b7048d088b2c23a53a6857d), >>> >> but when I'm trying to connect the the DB using the DriverManager, >>> >> there's an exception which seems to relate to hive-site.xml (HiveCon= f >>> >> - hive-site.xml not found.). But I could not find any hive-site.xml = in >>> >> $HIVE_HOME/conf - there's only hive-default.xml. The wiki page also >>> >> speaks about couple of jpox JAR files, which aren't in the lib folde= r >>> >> either. >>> >> >>> >> Am I missing something here? >>> >> >>> >> Regards >>> >> Arijit >>> >> >>> >> -- >>> >> "And when the night is cloudy, >>> >> There is still a light that shines on me, >>> >> Shine on until tomorrow, let it be." >>> >> >>> > >>> > >>> > >>> > -- >>> > "And when the night is cloudy, >>> > There is still a light that shines on me, >>> > Shine on until tomorrow, let it be." >>> > >>> >>> >>> >>> -- >>> "And when the night is cloudy, >>> There is still a light that shines on me, >>> Shine on until tomorrow, let it be." >> >> > > > > -- > "And when the night is cloudy, > There is still a light that shines on me, > Shine on until tomorrow, let it be." > --=20 "And when the night is cloudy, There is still a light that shines on me, Shine on until tomorrow, let it be."