WEBVTT 00:04.650 --> 00:10.490 We have just successfully created the new topic in our last hour, and topic name is Month Replication 00:10.500 --> 00:15.050 Factor was said to three and wanted it is equal to seven. 00:15.360 --> 00:20.940 And now let's quickly open up blogs for those where our messages will be stored on our computer and 00:20.940 --> 00:24.660 observe which partitions were created on which broadcast. 00:24.870 --> 00:31.150 And now in our set up for this topic, we should see the same politicians on different broadcasts. 00:31.530 --> 00:38.340 Thus, due to the replication factor equal to three, you'll remember that if there are replicas, then 00:38.340 --> 00:45.120 one of the broadcasts is leader for specific partition and all the remaining brokers are full of words 00:45.120 --> 00:50.630 and they simply accept the right request from leader and they don't. 00:51.060 --> 00:55.890 Producers and consumers for particular partition where they are not leaders. 00:56.010 --> 01:01.920 So let's observe this in our example and see what happened actually on average of the broadcast. 01:02.310 --> 01:05.440 OK, let's see to before them. 01:05.520 --> 01:10.470 So let's drop them and let's open this folder in finder. 01:10.470 --> 01:16.860 In my case, and as in a previous example, I see here separate the folders for logs of every brolga. 01:17.040 --> 01:22.920 And thus because we have configured so in the configuration files where every broker and let's not expand, 01:22.920 --> 01:26.030 for example, this folder with logs for Breuker or Zero. 01:26.310 --> 01:34.440 And now I see that this broker has created seven sub folders for different partitions for topic month 01:34.860 --> 01:36.740 from a zero deal six. 01:37.710 --> 01:44.010 Let's expand the also subfolder of the next Borkur with add one and same picture here. 01:44.310 --> 01:52.860 It has created seven folders for every partition of the month and you may guess that same actually happened 01:52.860 --> 01:54.740 for Breuker with added two. 01:54.930 --> 02:01.010 Yes, here it is also seven partitions for topic month and that's fully correct. 02:01.410 --> 02:07.380 In total we have set up seven partitions and obligation factor is three. 02:07.770 --> 02:15.480 And that means that for every partition there should be in total three different replicas, including 02:15.480 --> 02:18.510 leader, of course, and that's what we see here. 02:18.900 --> 02:25.110 Every partition was created on each of our brokers in the Gloster grade. 02:25.410 --> 02:32.640 But it's important to understand that for every partition, only a single broker is selected as leader 02:32.910 --> 02:39.780 and only a single broker serros, producers and consumers that want to interact with this particular 02:39.780 --> 02:40.530 partition. 02:40.890 --> 02:47.070 And all the remaining brokers are just of and they simply synchronize messages with leader in order 02:47.070 --> 02:47.670 to prove that. 02:47.760 --> 02:50.380 Let's try to read the details about this topic. 02:50.700 --> 02:56.780 For that, let's go to our file with commands and find a command that will list for all topics. 02:56.790 --> 02:58.710 This one, let's go up it. 02:59.010 --> 03:00.960 Go to a folder again. 03:00.960 --> 03:04.440 Sidiq Afkham clear terminal based command. 03:04.440 --> 03:05.730 Let's list all topics. 03:06.060 --> 03:10.620 And at the moment I see only a single topic Mom recounted in examples before. 03:10.620 --> 03:15.030 We have seen all the consumer of s topic, but for now it is absent. 03:15.540 --> 03:16.500 My question to you. 03:16.650 --> 03:17.940 Why is it absent? 03:19.170 --> 03:19.800 You are right. 03:20.070 --> 03:26.100 Consumer offsets topic is automatically created after first connection of consumer to the Gloster. 03:26.460 --> 03:30.880 We haven't yet connected to the glass to intimate, yet produced and consumed any messages. 03:31.110 --> 03:34.500 That's why this consumer of this topic is absent at the moment. 03:34.740 --> 03:37.420 OK, now let's read the tales about this topic. 03:37.740 --> 03:41.030 Let's go back to our final magic file was All Commands. 03:41.340 --> 03:46.650 Let me open this comment and show that here our topic is math and based command here. 03:48.420 --> 03:50.310 Let me make it a bit smaller. 03:52.070 --> 03:59.240 And here we are, we see details about Dobek month partition count is equal to seven, reduplication 03:59.240 --> 04:04.250 factor is equal to three and segment bias is by default against one gigabyte. 04:04.610 --> 04:05.020 Great. 04:05.270 --> 04:09.430 And here we see a difference from the output in previous example. 04:09.890 --> 04:12.620 Let's observe the tables for partition zero. 04:13.130 --> 04:16.100 You see here that the leader ID is two. 04:16.460 --> 04:23.030 That means that the broker with the two is, let's say, primary broker for this partition and it is 04:23.060 --> 04:28.850 responsible for all read and write requests from producers and consumers. 04:29.300 --> 04:36.920 And this broker, with added two, is responsible for replication of all messages to all followers. 04:38.110 --> 04:44.740 And here in the next column, you see a list of replicas and here you see I.D. of all brokers and first 04:44.740 --> 04:50.340 one is to so to zero one, first comes actually leader. 04:50.350 --> 04:53.790 And this is equal to this idea here in this column. 04:54.010 --> 04:59.560 And afterwards, we see I.D. of two women brokers, zero and one. 04:59.950 --> 05:07.210 And that means that those two brokers fall over for this partition partition with zero. 05:08.540 --> 05:16.100 Also in this column, you see in-sync replicas and here you see a list of ideas of the brokers that 05:16.100 --> 05:19.110 are fully synchronized for this partition. 05:19.880 --> 05:23.570 We haven't yet produced any messages and all brokers are up and running. 05:23.690 --> 05:28.480 And that's why here and here you'll see actually the same list of ideas. 05:28.850 --> 05:34.730 Later on, we will play with the set up and try to bring one of the brokers down and observe what will 05:34.730 --> 05:36.210 change here in this output. 05:36.350 --> 05:39.720 But for now, we could say that the hourglass is fully healthy. 05:39.890 --> 05:45.170 All brokers are up and running and all partitions are available for read and write operations. 05:45.890 --> 05:52.250 That's how picture looks like for our new topic month when it has multiple replicas configured. 05:52.430 --> 05:58.580 And again, in total, we have seven of partitions, wonderful lisinopril sit and next to let's try 05:58.580 --> 05:59.810 to produce some messages. 05:59.810 --> 06:03.480 And Delonge Kafka console consumer and console producer. 06:03.680 --> 06:04.520 So see you next. 06:04.550 --> 06:05.020 Bye bye.