4

This seems to be a mystery in cassandra, According to official documentation, one can create index on a column by using a custom indexer class

CREATE CUSTOM INDEX ON users (email) USING 'path.to.the.IndexClass';

But I could not find any documentation regarding the interface/class to be implemented/extended to do this and how to configure cassandra to find the class?

I wanted to write a custom indexer which could skip indexing rows based on conditions/options.

FUD
  • 5,114
  • 7
  • 39
  • 61

3 Answers3

2

Here what I've found https://issues.apache.org/jira/browse/CASSANDRA-6480 So you have to implement a subclass of org.apache.cassandra.db.index.SecondaryIndex and make sure that class is on the classpath for your Cassandra

Mikhail Stepura
  • 3,374
  • 20
  • 16
1

Here you can find example of implementation:

http://tuplejump.github.io/stargate/

https://github.com/tuplejump/stargate-core

zaletniy
  • 549
  • 4
  • 12
1

Stratio's Cassandra Lucene Index is a plugin which supports custom indexes in cassandra, you can find the required documentation on how to work with custom indexes.

  • Hi, welcome to SO. Please don't post links as answers, they become useless if the link changes or goes offline. Use the info on the site to build your answer and post the link as reference only. Thanks. – Cthulhu Mar 14 '16 at 14:14