DO we need to rebuild index time to time if there is many insert and deletes happen in the tables which has custom indexes
@debasis.tcs_69445, can you elaborate by updating your question about what index are you using in here and the version of DSE/OSS C*? In general indexes are built automatically and you don't have to do anything in particular. See this documentation for additional details. Thanks!
We have few custom indexes on the cassandra tables. Developers are telling that these custom indexes get fragmented as data is being purged and inserted in regular interval.
Is it possible that custom indexes gets fragmented in that scenario and we need to manually rebuild the index to make select query faster?
@debasis.tcs_69445, again you have not given additional details as to which version DSE/C* and what type of index(es) you're using. Please refer to this documentation to understand what are the problems using an index on a frequently updated or deleted column.
Here is index details:-
CREATE INDEX idx_jobs_by_urn_jobcreationtimestamp ON m2mdm_jobs.jobs_by_urn (jobcreationtimestamp);
CREATE INDEX idx_jobs_by_urn_status ON m2mdm_jobs.jobs_by_urn (status);
CREATE INDEX idx_jobs_by_urn_v470_owner_app_node ON m2mdm_jobs.jobs_by_urn (v470_owner_app_node);
CREATE INDEX idx_jobs_by_urn_jobmode ON m2mdm_jobs.jobs_by_urn (jobmode);
CREATE INDEX idx_jobs_by_urn_v470_trigger_type ON m2mdm_jobs.jobs_by_urn (v470_trigger_type);
CREATE INDEX idx_jobs_by_urn_v470_scheduled_execution_time ON m2mdm_jobs.jobs_by_urn (v470_scheduled_execution_time);
Cassandra version is:- 3.11.0
Please let me know any thing more needed.
The quick answer is no. Cassandra automatically indexes all mutations coming into the database. Cheers!
6 People are following this question.
What does cardinality mean in Cassandra?
Why is the number of keys an estimate in the nodetool tablestats output?
TOKEN() query returning "no viable alternative at input 'TOKEN()'"
How can I minimise the impact of a full table scan running Spark against Cassandra?
Cassandra LOCAL_QUORUM is waiting for remote datacenter responses
DataStax Enterprise is powered by the best distribution of Apache Cassandra ™
© 2023 DataStax, Titan, and TitanDB are registered trademarks of DataStax, Inc. and its subsidiaries in the United States and/or other countries.
Apache, Apache Cassandra, Cassandra, Apache Tomcat, Tomcat, Apache Lucene, Lucene, Apache Solr, Apache Hadoop, Hadoop, Apache Spark, Spark, Apache TinkerPop, TinkerPop, Apache Kafka and Kafka are either registered trademarks or trademarks of the Apache Software Foundation or its subsidiaries in Canada, the United States and/or other countries.
Privacy Policy Terms of Use