Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SemanticException Cannot find class "com.lucidworks.hadoop.hive.LWStorageHandler" #26

Open
deepdoradla opened this issue May 4, 2017 · 5 comments
Labels
information needed More information is needed to answer question

Comments

@deepdoradla
Copy link

I am trying to do the following and I am getting "FAILED: SemanticException Cannot find class 'com.lucidworks.hadoop.hive.LWStorageHandler'"

create external table IF NOT EXISTS movies_solr2(movieId INT, title STRING, genres STRING) STORED BY 'com.lucidworks.hadoop.hive.LWStorageHandler' LOCATION '/user/deep4u/solr/movielens_movies/' TBLPROPERTIES('solr.zkhost' = 'data1.cloudwick.com:2181,data2.cloudwick.com.com:2181,data3.cloudwick.com:2181/solr','solr.collection' = 'movies','solr.query' = '*:*');

The jar I am using is solr-hive-serde-3.0.0.jar. Is this a known problem with 3.0.0 jars?

Any help would be greatly appreciated.

@ctargett
Copy link
Contributor

ctargett commented May 4, 2017

@deepdoradla Did you add the jar? From the hive prompt: ADD JAR solr-hive-serde-3.0.0.jar;.

Also, I don't believe we've ever tested this with IF NOT EXISTS, but I would think it would give a better error than it can't find the class if that was the problem.

@JAYMIN1991
Copy link

Hello, i tried below command for solr external table data. its return same error "FAILED: SemanticException Cannot find class 'com.lucidworks.hadoop.hive.LWStorageHandler'".

Command of Hive:

CREATE EXTERNAL TABLE solr_coldemo (id STRING, cat_s STRING, title_s STRING, price_f FLOAT, in_stock_b BOOLEAN, author_s STRING, series_s STRING, seq_i INT, genre_s STRING) STORED BY 'com.lucidworks.hadoop.hive.LWStorageHandler' LOCATION '/tmp/solr' TBLPROPERTIES('solr.server.url' = 'http://192.168.1.72:8984/solr','solr.collection' = 'collection1','solr.query' = ':');

Help me for same.

Thanks in advance!

@acesar
Copy link
Contributor

acesar commented Nov 13, 2017

@deepdoradla @Jaymin009 Please share the build commands that you follow.

The command: ./gradlew clean shadowJar --info creates a uber jar with all dependencies needed.

The exception:

 "FAILED: SemanticException Cannot find class 'com.lucidworks.hadoop.hive.LWStorageHandler'"

Usually means that the uber jar is missing some dependencies (build issues)

@ctargett ctargett added the information needed More information is needed to answer label May 3, 2018
@udossa
Copy link

udossa commented Aug 23, 2018

Hello I have the same issue, here are the commands I follow to build the Jar:
git clone --recursive https://github.com/lucidworks/hive-solr
gradlew clean shadowJar --info

@raviceg
Copy link

raviceg commented Jul 5, 2019

Hi All, Is this issue solved or any alternate solution?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
information needed More information is needed to answer question
Projects
None yet
Development

No branches or pull requests

6 participants