hive-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Manuel Vellon <>
Subject Problem with Hive JDBC + HBase
Date Fri, 27 Sep 2013 22:04:16 GMT
I am getting an error when using the Hive JDBC driver:

	java.lang.NoSuchMethodError:  org.apache.thrift.EncodingUtils.setBit(BIZ)B

I've seen several messages suggesting that this is a problem due to different thrift jars
in hbase and hive. To avoid this problem, I copied the Hive thrift jar (libthrift-0.9.0.jar)
into the hbase/lib directory (and verified, with ps, that it's being picked up in the class
path.)  Alas, I still get the error.

Individually, Hadoop, HBase and Hive all run fine.

The ps output does not show any other java process using any other =
version of libthrift.

Here are the versions that I'm using:

hadoop: 1.2.1
hbase: 0.94.12
hive: 0.10.0

The code that triggers the problem is simple:

			Connection con = DriverManager.getConnection("jdbc:hive://", "",
			Statement stmt = con.createStatement();
			ResultSet res = stmt.executeQuery("show tables");
			// code blows up on next statement
				String str = res.getString(0);

The abbreviated stack trace looks like:

java.lang.NoSuchMethodError: org.apache.thrift.EncodingUtils.setBit(BIZ)B
	at org.apache.hadoop.hive.service.ThriftHive$fetchN_args.setNumRowsIsSet(
	at org.apache.hadoop.hive.service.ThriftHive$fetchN_args.setNumRows(
	at org.apache.hadoop.hive.service.ThriftHive$Client.send_fetchN(
	at org.apache.hadoop.hive.service.ThriftHive$Client.fetchN(

Any clues as to what I should try next would be appreciated.
View raw message