1 00:00:00,420 --> 00:00:01,590 ‫All right, guys, so. 2 00:00:02,930 --> 00:00:08,240 ‫We talked about Sharding a little bit, we did an implementation with sharding, with consistent hashing 3 00:00:08,240 --> 00:00:11,300 ‫and all that jazz, pretty cool ish stuff, right? 4 00:00:12,020 --> 00:00:14,510 ‫How about we talked about the pros and cons of Sharding? 5 00:00:14,510 --> 00:00:15,260 ‫Is this perfect? 6 00:00:15,470 --> 00:00:17,680 ‫Well, let's check let's check it out and see. 7 00:00:17,930 --> 00:00:25,520 ‫So the pros of shorting is you're going to get scalability and that's both and data memory and even 8 00:00:25,520 --> 00:00:32,270 ‫CPU and any resource that is on your server instead of having your server, essentially the resources 9 00:00:32,270 --> 00:00:38,330 ‫of getting hawked with one machine, you can spread the load on multiple machines across horizontally 10 00:00:38,330 --> 00:00:41,740 ‫partition horizontally scale things right. 11 00:00:41,780 --> 00:00:42,280 ‫Goes down. 12 00:00:42,290 --> 00:00:49,700 ‫Essentially your your data is spread out and now the client is aware of which part is where. 13 00:00:49,700 --> 00:00:55,490 ‫And then just like need to know and head that essentially and just build up, build that up. 14 00:00:55,490 --> 00:00:55,810 ‫Right. 15 00:00:56,000 --> 00:00:57,790 ‫So that's essentially what needs to happen. 16 00:00:58,640 --> 00:01:00,560 ‫So you get scalability for free. 17 00:01:00,740 --> 00:01:01,520 ‫That's great. 18 00:01:01,520 --> 00:01:01,840 ‫Right. 19 00:01:02,480 --> 00:01:03,770 ‫You also get security. 20 00:01:03,890 --> 00:01:04,250 ‫Right. 21 00:01:04,400 --> 00:01:06,080 ‫And that's well, that's interesting one. 22 00:01:06,080 --> 00:01:13,190 ‫Let's say you like if you have like certain customers data, you want the this shard of customers to 23 00:01:13,190 --> 00:01:15,250 ‫be accessed only by certain people. 24 00:01:15,770 --> 00:01:21,620 ‫So you can put your VIP customers in one shot and other customers are another charge. 25 00:01:21,620 --> 00:01:21,920 ‫Right. 26 00:01:22,040 --> 00:01:24,770 ‫And then you can have little bit access. 27 00:01:24,770 --> 00:01:28,040 ‫Control or not, Shahd can be accessed by what clients. 28 00:01:28,240 --> 00:01:33,800 ‫So with that and instead of having everything in one table, you kind of spread it out and have kind 29 00:01:33,800 --> 00:01:36,010 ‫of access control over what it's like. 30 00:01:36,050 --> 00:01:37,610 ‫So already you cannot access this chart. 31 00:01:38,240 --> 00:01:38,490 ‫Right. 32 00:01:38,510 --> 00:01:44,090 ‫So you can essentially have this level of control of security with pros, with sharding. 33 00:01:44,300 --> 00:01:45,260 ‫Pretty cool stuff. 34 00:01:45,260 --> 00:01:45,550 ‫Right. 35 00:01:46,430 --> 00:01:51,770 ‫And it's optimal because they were going to get a smaller and smaller and smaller index size. 36 00:01:51,770 --> 00:01:57,710 ‫And that's cool because the smaller index you get, the better and the quicker and more efficient queries 37 00:01:57,710 --> 00:01:58,130 ‫become. 38 00:01:58,130 --> 00:01:58,400 ‫Right. 39 00:01:58,730 --> 00:01:59,270 ‫Cool stuff.