Search This Blog

Monday, May 10, 2021

Q26-Q30(Kafka)

Q26. Offset is set by us or does it set by kafka?
Q27. What are the benefits of using Kafka?
Q28. Difference between Kafka and Web API?





==============================================================================
Q26. Offset is set by us or does it set by kafka?

Answer:
Kafka stores offset commits.
==============================================================================
Q27. What are the benefits of using Kafka?

Answer:
Kafka is a distributed public subscribe messaging service. 

Distributed - 
Highly scalable
Low latency
Enormous messaging streaming
Durability - , durability refers to the persistence of data/messages on disk. Also, messages replication is one of the reasons behind durability, hence messages are never lost.
Real-Time Handling
Kafka can handle real-time data pipeline. Since we need to find a technology piece to handle real-time messages from applications, it is one of the core reasons for Kafka as our choice.

Kafka doesn’t try to track which message was actually read by what consumer and just hold on to unread messages. Instead, it holds all of the messages for a pre-specified amount of time, and consumers are charged with tracking their location within each log

  1. Kafka is highly scalable. Kafka is a distributed system, which is able to be scaled quickly and easily without incurring any downtime. Apache Kafka is able to handle many terabytes of data without incurring much at all in the way of overhead.
  2. Kafka is highly durable. Kafka persists the messages on the disks, which provides intra-cluster replication. This makes for a highly durable messaging system.
  3. Kafka is Highly Reliable. Kafka replicates data and is able to support multiple subscribers. Additionally, it automatically balances consumers in the event of failure. That means that it’s more reliable than similar messaging services available.
  4. Kafka Offers High Performance. Kafka delivers high throughput for both publishing and subscribing, utilizing disk structures that are capable of offering constant levels of performance, even when dealing with many terabytes of stored messages.

==============================================================================
Q28. Difference between Kafka and Web API?

Answer:
WebApi:
1. Request/ Response model.


Kafka:
1. Publish/ Subscribe model. 


==============================================================================



==============================================================================

No comments:

Post a Comment

Q46-Q50

Q46.  If we have 3 types of constructor in code static, default, parametrized. In which order they will be called.  Q47. What is GAC? Q48.  ...