Skip to content
This repository has been archived by the owner on Mar 1, 2023. It is now read-only.

how i can find count of 'lucene index' ? #30

Open
leesangboo opened this issue May 24, 2015 · 2 comments
Open

how i can find count of 'lucene index' ? #30

leesangboo opened this issue May 24, 2015 · 2 comments

Comments

@leesangboo
Copy link

how i can find count of 'lucene index' ?

@adelapena
Copy link
Contributor

What do you mean by count?
If you mean count queries, they can be done in the same way as it is done in regular CQL queries:

SELECT COUNT(*) FROM tweets WHERE lucene='{
    query : {type:"phrase", field:"body", values:["big","data","gives","organizations"]}
}';

If you want to get the total number of documents in the index, this can not currently be done with Stratio Cassandra. This feature will be available through JMX in the incoming pluggable version of Stratio Cassandra (see CASSANDRA-8717), as soon as Apache Cassandra 2.1.6 is released.

@philmes
Copy link

philmes commented Aug 3, 2015

This seems to be a very expensive operation though, as it loads all matching rows from the underlying store. Is there a way to this more cheaply?

edit: I know this is a limitation of the underlying C* model (where it needs to pull everything back to the co-ordinator node), but there seems to be an opportunity here to at least estimate a number?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants