0

I have installed Data-Sax Cassandra community edition(2.2.3) on my machine and I want to use full text Search. I have downloaded the Stratio lucene index 2.2.3 and copied it to the Cassandra lib folder but when I execute the command to create index as below

   CREATE CUSTOM INDEX tweets_index ON tweets (lucene)
   USING 'com.stratio.cassandra.lucene.Index'
   WITH OPTIONS = {
  'refresh_seconds' : '1',
  'schema' : '{
    fields : {
        id    : {type : "integer"},
        user  : {type : "string"},
        body  : {type : "text", analyzer : "english"},
        time  : {type : "date", pattern : "yyyy/MM/dd", sorted : true},
        place : {type : "geo_point", latitude:"latitude",    longitude:"longitude"}
    }
}'
};

I get exception ServerError:

    ErrorMessage code=0000 [Server error] message="java.lang.RuntimeEx
   ception: java.lang.ClassNotFoundException:    
    com.stratio.cassandra.lucene.Index"

I also tried to build it using maven and update the installation , but no success. Also I copied the jar files to my JDK ext folder and tried again without any success.

Cheers, jereesh

gasparms
  • 3,336
  • 22
  • 26
jereesh thomas
  • 113
  • 1
  • 13
  • Is there any specific reason to use version 2.2.3? if not switch to latest version and you can create a Solr node which uses underlying CFS to store indexes and is much faster. – mbaxi Dec 07 '15 at 07:46
  • @mbaxi , 2.2.3 is the stable version right?. – jereesh thomas Dec 07 '15 at 08:33
  • Yeh sorry I got confused with enterprise edition(v4.8) which provides inbuilt integration with Solr. – mbaxi Dec 07 '15 at 09:45

1 Answers1

3

Are you sure you have copied the proper index JAR file into Cassandra's lib path?

You can download, build and patch your Cassandra installation this way:

git clone https://github.com/Stratio/cassandra-lucene-index.git
cd cassandra-lucene-index
git checkout 2.2.3.2
cd mvn clean package -Ppatch -Dcassandra_home=<PATH_TO_CASSANDRA>

Please ensure that <PATH_TO_CASSANDRA> contains the following:

CHANGES.txt     
lib
LICENSE.txt
conf
logs
NEWS.txt
data
pylib
NOTICE.txt
interface
switch_snappy
bin
javadoc
tools

Otherwise, you can download DSC community 2.2.3 from http://downloads.datastax.com/community/dsc-cassandra-2.2.3-bin.tar.gz

I hope it helps.

  • Yes I did It seems to be working when the Cassandra is being started from the batch file . But seems to be not picking if I start the Datasax Cassandra Community Server Service – jereesh thomas Dec 15 '15 at 04:02