What makes Kafka special? | System Design

  Рет қаралды 15,643

Interview Pen

Interview Pen

Күн бұрын

Visit Our Website: interviewpen.com/?...
Join Our Discord (24/7 help): / discord
Like & Subscribe: / @interviewpen
You've probably heard about Kafka, but you really know why everyone is so excited about it? This video dives into the low-level details of what makes Kafka fundamentally different from other message queue systems, and when you should use it over other solutions.
If you liked this video and want to learn more about fundamental systems and how they can be used to solve problems, check out our full course on interviewpen.com/?... !
Table of Contents:
0:00 - Introduction
0:13 - Message Queues
1:32 - Message Routing
2:03 - Kafka Behavior
2:37 - Consumer Offsets
3:25 - Sequential Disk Access
4:51 - Use Cases
6:02 - interviewpen.com
Socials:
Twitter: / interviewpen
LinkedIn: / interviewpen
Website: interviewpen.com/?...

Пікірлер: 39
@prashantkumardhotre5695
@prashantkumardhotre5695 Ай бұрын
What I like most about your videos is that they are short, crisp, to the point, great visuals and no BS
@interviewpen
@interviewpen Ай бұрын
Thank you, glad you like them!
@harisridhar1668
@harisridhar1668 4 ай бұрын
Thanks for really going over the differences between Kafka versus TMQs - Traditional Message Queues - in this video. It helps to understand Kafka for its benefits with retention, replay, and fanout delivery pattern to multiple consumer nodes/services. Also I like your presentation style and the use of multiple colors to highlight the many components and network passing going.
@interviewpen
@interviewpen 4 ай бұрын
Thank you!
@shaikhmubin02
@shaikhmubin02 4 ай бұрын
Bro you are doing a great job, keep it up💪🏻
@interviewpen
@interviewpen 4 ай бұрын
Thanks!
@mertbozkir
@mertbozkir 4 ай бұрын
I appreciate you, awesome channel!
@interviewpen
@interviewpen 4 ай бұрын
Thanks!
@48_subhambanerjee22
@48_subhambanerjee22 4 ай бұрын
Bro... This is like OS... Semaphoring with producer consumer... There also you send process PCB into queue and when queue is full producer sleeps and when empty reciever sleeps
@sanketagarwal8570
@sanketagarwal8570 4 ай бұрын
The content is just too good!
@interviewpen
@interviewpen 4 ай бұрын
Thank you!
@Labandusette
@Labandusette 4 ай бұрын
thank you very much !
@interviewpen
@interviewpen 4 ай бұрын
Of course!
@pieter5466
@pieter5466 4 ай бұрын
Another great video. A great follow up might be Samza. [edit: Samza as a example of stream processing between queues]
@interviewpen
@interviewpen 4 ай бұрын
We'll add it to the backlog! Thanks for watching.
@AshrafMMA
@AshrafMMA 4 ай бұрын
Wow.. now I get why it so much more scalable . How do you determine size of queue, and will you cover usages of multiple queues in kafka?
@interviewpen
@interviewpen 4 ай бұрын
We have a full video about using queues in large scale systems on interviewpen.com :)
@rustix3
@rustix3 4 ай бұрын
4:08 Wow the page cache of the operating system need another video on its own. How does it caches, what strategy it uses? What happens if the consumer becomes available and Kafka need to re-read all previous messages? Do OS cache stores anough of messages, should or even can it be twicked?
@interviewpen
@interviewpen 4 ай бұрын
Yes--tons of OS level enhancements can be made to optimize for specific usage patterns. This is an advanced topic, but we're working on expanding our coverage of these sorts of things in our course at interviewpen.com . Thanks for watching!
@quachhengtony7651
@quachhengtony7651 5 күн бұрын
Can you name some of these traditional message queues?
@martyallen3801
@martyallen3801 4 ай бұрын
RabbitMQ also provides exchanges and fanout, right? What's the big difference between them in that case?
@interviewpen
@interviewpen 4 ай бұрын
Yep--Rabbit would be classified as a traditional MQ involving exchanges and messages delivered to one consumer.
@elstp2
@elstp2 4 ай бұрын
please an review of account system
@interviewpen
@interviewpen 4 ай бұрын
Is this what you're looking for? kzfaq.info/get/bejne/q9CPZ9mp0p_ZaWQ.htmlsi=eaD-ZVsmh2Ha2q3N
@69k_gold
@69k_gold 4 ай бұрын
So because we have the event dequeueing in traditional MQ we are losing the throughput capabilities?
@interviewpen
@interviewpen 4 ай бұрын
It's really more about messages being removed from the queue once consumed--this results in different consumer semantics but makes it harder to optimize for throughput at an OS level. Hope that helps!
@rustix3
@rustix3 4 ай бұрын
3:01 What just happened? Did the offset below(which is the offset for Consumer below) just went directly through 1 and 2? Or was it going through 1 at the same time as the Offset above was going through 1? I mean the offsets and consumers work in parallel, right?
@ygormartinsr
@ygormartinsr 4 ай бұрын
The second consumer hadn't pulled data from the queue yet, so its offset was still at 0. Once it did it received the two events that were sitting there
@interviewpen
@interviewpen 4 ай бұрын
Messages can be received by consumers in batch, so when the second consumer polled, it received both messages.
@santoshpinisetty7796
@santoshpinisetty7796 4 ай бұрын
But wouldn't saving all msg waste memory how does it handle the it
@abhishek_ar97
@abhishek_ar97 4 ай бұрын
Default time is 7 days, after which the message gets deleted. You can find them in the kafka-config file
@interviewpen
@interviewpen 4 ай бұрын
Kafka will automatically delete old messages when it runs out of space :)
@imnormal-sl8mj
@imnormal-sl8mj 4 ай бұрын
Hi, I still don't get why Kafka can get much higher throughput than to traditional MQ, is it because of its scalability? If so, why isn't traditional MQ more scalable?
@interviewpen
@interviewpen 4 ай бұрын
Kafka efficiently uses optimizations built into the operating system, such as sequential disk access and the page cache. For reference, this is covered at 3:25 in the video--thanks for watching!
@yuzhao5268
@yuzhao5268 Ай бұрын
helpful but shallow. there's gotta be more details. what if the machines running the queues crash? What if publisher publishes faster than consumer consumes? what protocol is used to communicate? if multiple producers are producing, what orders are enforced?
@interviewpen
@interviewpen Ай бұрын
If you want an in-depth video on how queues are used in fault-tolerant systems, check out interviewpen.com :)
@quentin7343
@quentin7343 4 ай бұрын
How old are you? :O
@siux94
@siux94 4 ай бұрын
You misrepresented "traditional" MQs.
@interviewpen
@interviewpen 4 ай бұрын
Could you elaborate?
Design an ML Recommendation Engine | System Design
8:46
Interview Pen
Рет қаралды 9 М.
What is RabbitMQ?
10:10
IBM Technology
Рет қаралды 314 М.
Pool Bed Prank By My Grandpa 😂 #funny
00:47
SKITS
Рет қаралды 7 МЛН
Fast and Furious: New Zealand 🚗
00:29
How Ridiculous
Рет қаралды 46 МЛН
路飞太过分了,自己游泳。#海贼王#路飞
00:28
路飞与唐舞桐
Рет қаралды 40 МЛН
Basic System Design for Uber or Lyft | System Design Interview Prep
16:18
Event-Driven Architecture (EDA) vs Request/Response (RR)
12:00
Confluent
Рет қаралды 132 М.
Design a Simple Authentication System | System Design Interview Prep
17:22
20 System Design Concepts Explained in 10 Minutes
11:41
NeetCode
Рет қаралды 948 М.
Design a Data Warehouse | System Design
14:08
Interview Pen
Рет қаралды 20 М.
3 Important Use Cases Why The Industry Is Using Kafka
7:52
Anthony GG
Рет қаралды 13 М.
Apache Kafka in 6 minutes
6:48
James Cutajar
Рет қаралды 992 М.
Pool Bed Prank By My Grandpa 😂 #funny
00:47
SKITS
Рет қаралды 7 МЛН