TOP Apache Cassandra Interview Questions and Answers pdf

1: How many types of NoSQL databases are there?
There are four types of NoSQL databases, namely:
Document Stores (MongoDB, Couchbase)
Key-Value Stores (Redis, Volgemort)
Column Stores (Cassandra)
Graph Stores (Neo4j, Giraph)

2: What do you understand by Commit log in Cassandra?
Commit log is a crash-recovery mechanism in Cassandra. Every write operation is written to the commit log.

3: Define Mem-table in Cassandra.
It is a memory-resident data structure. After commit log, the data will be written to the mem-table. Mem-table is in-memory/write-back cache space consisting of content in key and column format. The data in mem- table is sorted by key, and each column family consists of a distinct mem-table that retrieves column data via key. It stores the writes until it is full, and then flushed out.

4: What is SSTable?
SSTable or ‘Sorted String Table,’ refers to an important data file in Cassandra. It accepts regular written memtables which are stored on disk and exist for each Cassandra table. Being immutable, SStables do not allow any further addition and removal of data items once written. For each SSTable, Cassandra creates three separate files like partition index, partition summary and a bloom filter.

5: What is bloom filter?
Bloom filter is an off-heap data structure to check whether there is any data available in the SSTable before performing any I/O disk operation.

6: Establish the difference between a node, cluster & data centres in Cassandra.
Node is a single machine running Cassandra.
Cluster is a collection of nodes that have similar type of data grouped together.
Data centres are useful components when serving customers in different geographical areas. Different nodes of a cluster are grouped into different data centres.

7: Define composite type in Cassandra?
In Cassandra, composite type allows to define a key or a column name with a concatenation of data of different type. You can use two types of Composite Types:
Row Key
Column Name

8: What is Cassandra Data Model?
Cassandra Data Model consists of four main components, namely:
Cluster: These are made up of multiple nodes and keyspaces.
Keyspace: It is a namespace to group multiple column families, especially one per partition.
Column: It consists of a column name, value and timestamp
Column family: This refers to multiple columns with row key reference.

9: Explain what is a keyspace in Cassandra?
In Cassandra, a keyspace is a namespace that determines data replication on nodes. A cluster consists of one keyspace per node.

10: Elaborate on CQL?
A user can access Cassandra through its nodes using Cassandra Query Language (CQL). CQL treats the database (Keyspace) as a container of tables. Programmers use cqlsh: a prompt to work with CQL or separate application language drivers.

Read More Questions:
Apache Cassandra Interview Questions Part1
Apache Cassandra Interview Questions Part2
Apache Cassandra Interview Questions Part3
Apache Cassandra Interview Questions Part4
Apache Cassandra Interview Questions Part5

0 comments: