Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Single Keyspace or Multiple Keyspace in cassandra datamodel

Which one is best for managing data by using single keyspace or Multiple Keyspace , Suppose one application having more number of clients. Each client will send large set of data and we are storing data in time series column If i go for individual keyspace for every client, Will it be good in Cassandra for managing data? what are the advantages and disadvantages if i use one keyspace for one client in my application?

like image 585
kannadhasan Avatar asked Jan 12 '23 20:01

kannadhasan


1 Answers

The main reason for having multiple keyspaces is because some settings are per keyspace, whereas some are per column family.

The most important per keyspace settings are for replication - replication strategy (single or multi DC) and replication factor (overall or per DC). All column families within a keyspace have the same replication settings. Different applications may have different replication requirements - maybe not today but may in the future. So for this reason it is a good idea to use different keyspaces for different applications.

In terms of performance or resource usage, it makes very little difference whether column families are in the same keyspace.

like image 173
Richard Avatar answered Jan 31 '23 10:01

Richard