Return-Path: X-Original-To: apmail-hive-user-archive@www.apache.org Delivered-To: apmail-hive-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 3BEB818B4B for ; Mon, 9 Nov 2015 09:55:27 +0000 (UTC) Received: (qmail 39676 invoked by uid 500); 9 Nov 2015 09:55:26 -0000 Delivered-To: apmail-hive-user-archive@hive.apache.org Received: (qmail 39614 invoked by uid 500); 9 Nov 2015 09:55:26 -0000 Mailing-List: contact user-help@hive.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@hive.apache.org Delivered-To: mailing list user@hive.apache.org Received: (qmail 39604 invoked by uid 99); 9 Nov 2015 09:55:25 -0000 Received: from Unknown (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 09 Nov 2015 09:55:25 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id 863C8C070B for ; Mon, 9 Nov 2015 09:55:25 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 2.898 X-Spam-Level: ** X-Spam-Status: No, score=2.898 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=3, RCVD_IN_MSPIKE_H2=-0.001, SPF_PASS=-0.001] autolearn=disabled Authentication-Results: spamd4-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-eu-west.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id alG-CahsZBSF for ; Mon, 9 Nov 2015 09:55:24 +0000 (UTC) Received: from mail-ig0-f172.google.com (mail-ig0-f172.google.com [209.85.213.172]) by mx1-eu-west.apache.org (ASF Mail Server at mx1-eu-west.apache.org) with ESMTPS id CA54020C18 for ; Mon, 9 Nov 2015 09:55:23 +0000 (UTC) Received: by igvg19 with SMTP id g19so23003172igv.1 for ; Mon, 09 Nov 2015 01:55:22 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=3sP7idrEXbi1DlQmnVdn587IrFMVp27Y8f6rC7Czhyk=; b=gT0AwZSU+/MMJxIcruQ240+U0FchwXwxVmvhfzns6n7be6DKSzt44K5O7jnaugVLZz BfJeC5KXxx6Fsv+O7FdKQvnr3q+0c1wo2WjZMNd78k2jxTnDC1aDB1iISCrfl0/YcDG6 ZWf4ndYr4/lrl1cqkouZGRpPmkpbWcpbBU0R7kbW9y2WvMgY6rG1IlFSvcBqrE8Zp3dF 1/9v4HQ/SbK2r7RhNHm/6oQo7LksxohO5jcl31aCTEBrPEMsia3eI2mzMau+LeRCRf3T +KpsVCNfU1z23owqwTmK77QVSr0vYVhbDuHXopjqVLQ0+6Rq7g7/BKhTH2lx39qnRAm7 0G7w== MIME-Version: 1.0 X-Received: by 10.50.142.73 with SMTP id ru9mr18508947igb.51.1447062922726; Mon, 09 Nov 2015 01:55:22 -0800 (PST) Received: by 10.107.20.66 with HTTP; Mon, 9 Nov 2015 01:55:22 -0800 (PST) Date: Mon, 9 Nov 2015 15:25:22 +0530 Message-ID: Subject: thrift.TApplicationException: Invalid method name: 'execute' From: Rajkumar Singh To: user@hive.apache.org Content-Type: multipart/alternative; boundary=001a11c3db707a122f0524189773 --001a11c3db707a122f0524189773 Content-Type: text/plain; charset=UTF-8 I am trying to get the query result from thrift api using a java program which use thrifthive client to execute a query but I am getting exception org.apache.thrift.TApplicationException: Invalid method name: 'execute' at org.apache.thrift.TApplicationException.read(TApplicationException.java:111) at org.apache.thrift.TServiceClient.receiveBase(TServiceClient.java:71) at org.apache.hadoop.hive.service.ThriftHive$Client.recv_execute(ThriftHive.java:116) at org.apache.hadoop.hive.service.ThriftHive$Client.execute(ThriftHive.java:103) at com.rajkrrsingh.thrift.test.HiveThriftClientExample.main(HiveThriftClientExample.java:23) this is the snippet of the program TSocket tSocket = new TSocket("hostname",10000); TProtocol tProtocol = new TBinaryProtocol(tSocket); Client client = new Client(tProtocol); try { tSocket.open(); System.out.println(tSocket.isOpen()); client.execute("use default"); client.execute("show tables"); List rs = client.fetchAll(); Any Idea what going wrong here --001a11c3db707a122f0524189773 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
I am trying to get the query result from thrift api using = a java program which use thrifthive client to execute a query but I am gett= ing exception

org.apache.thrift.TApplicationExcepti= on: Invalid method name: 'execute'
at org.apache.thrift.TApplicationException.rea= d(TApplicationException.java:111)
at org.apache.thrift.TServiceClient.receiveBase(TServic= eClient.java:71)
at org.apache.hadoop.hive.service.ThriftHive$Client.recv_execute(ThriftH= ive.java:116)
= at org.apache.hadoop.hive.service.ThriftHive$Client.execute(ThriftHive.java= :103)
at com.r= ajkrrsingh.thrift.test.HiveThriftClientExample.main(HiveThriftClientExample= .java:23)

this is the snippet of the program=

=C2=A0 =C2=A0 =C2=A0 TSocket tSocket =3D new= TSocket("hostname",10000);
TProtocol tProtocol =3D new TBinaryProtocol(tSocke= t);
Client cl= ient =3D new Client(tProtocol);
= try {
tSocket.open();
System.out.println(tSocket.isOpen());
client.execute("use default");
client.execute(= "show tables");
List<String> rs =3D client.fetchAll();
=
Any Idea what going wrong here
--001a11c3db707a122f0524189773--