What is Database Sharding?

แชร์
ฝัง
  • เผยแพร่เมื่อ 30 พ.ค. 2024
  • 🔴 - To support my channel, I’d like to offer Mentorship/On-the-Job Support/Consulting - me@antonputra.com
    ▬▬▬▬▬ Experience & Location 💼 ▬▬▬▬▬
    ► I’m a Senior Software Engineer at Juniper Networks (12+ years of experience)
    ► Located in San Francisco Bay Area, CA (US citizen)
    ▬▬▬▬▬▬ Connect with me 👋 ▬▬▬▬▬▬
    ► LinkedIn: / anton-putra
    ► Twitter/X: / antonvputra
    ► GitHub: github.com/antonputra
    ► Email: me@antonputra.com
    ▬▬▬▬▬▬ Related videos 👨‍🏫 ▬▬▬▬▬▬
    👉 [Playlist] Kubernetes Tutorials: • Kubernetes Tutorials
    👉 [Playlist] Terraform Tutorials: • Terraform Tutorials fo...
    👉 [Playlist] Network Tutorials: • Network Tutorials
    👉 [Playlist] Apache Kafka Tutorials: • Apache Kafka Tutorials
    👉 [Playlist] Performance Benchmarks: • Performance Benchmarks
    👉 [Playlist] Database Tutorials: • Database Tutorials
    ▬▬▬▬▬▬▬ Timestamps ⏰ ▬▬▬▬▬▬▬
    0:00 What is database sharding?
    0:12 Why is database sharding important?
    0:58 What are the benefits of database sharding?
    1:57 How does database sharding work?
    3:42 What are the methods of database sharding?
    3:47 Range-based sharding
    4:59 Hashed sharding
    5:52 Directory sharding
    6:38 Geo sharding
    7:25 How to optimize database sharding for even data distribution?
    7:45 Cardinality
    8:05 Frequency
    8:24 Monotonic change
    ▬▬▬▬▬▬▬ Source Code 📚 ▬▬▬▬▬▬▬
    ► GitHub: github.com/antonputra/tutorials
    #kubernetes #devops #cloud
  • วิทยาศาสตร์และเทคโนโลยี

ความคิดเห็น • 76

  • @AntonPutra
    @AntonPutra  10 หลายเดือนก่อน +2

    🔴 - To support my channel, I’d like to offer Mentorship/On-the-Job Support/Consulting - me@antonputra.com

  • @jasper5016
    @jasper5016 3 หลายเดือนก่อน +10

    Hard to believe this top-notch content has very less views. Thanks a lot, Anton!!

    • @AntonPutra
      @AntonPutra  3 หลายเดือนก่อน

      ❤️

    • @jackfrost8969
      @jackfrost8969 2 หลายเดือนก่อน

      probably coz it basically has no volumn

  • @aslan1504
    @aslan1504 9 หลายเดือนก่อน +7

    As for the hashing, you probably will take hash only of a subset of columns of a record, most probably - only primary key, because changing any field of any record will result the hash to change also, which leads to data losses.

  • @ashutoshtiwari4398
    @ashutoshtiwari4398 หลายเดือนก่อน +1

    No Nonsense, direct to point, covering all cases.
    Well-compiled video!

    • @AntonPutra
      @AntonPutra  หลายเดือนก่อน

      thank you!

  • @alonsoalcantar7847
    @alonsoalcantar7847 หลายเดือนก่อน +1

    Ive tried to understand sharding for crypto purposes but every "crypto sharding" video display vague descriptions. I stumbled upon this by accident and it was great. Amazing work 🙌

    • @AntonPutra
      @AntonPutra  หลายเดือนก่อน

      thanks!

  • @bunnybal
    @bunnybal 5 วันที่ผ่านมา +1

    Really very well explained, thank you very much.

    • @AntonPutra
      @AntonPutra  5 วันที่ผ่านมา

      thanks!

  • @nero4581
    @nero4581 10 หลายเดือนก่อน +1

    Great Video, as always, Anton!

    • @AntonPutra
      @AntonPutra  10 หลายเดือนก่อน +1

      Thanks, if you think anything can be improved, please let me know!

  • @agun21st
    @agun21st 10 หลายเดือนก่อน +1

    Thank you sir for detail explaination of database sharding. We hope a practical handson of Database sharding will publish soon.

  • @xardiannon5038
    @xardiannon5038 3 หลายเดือนก่อน

    Superb explanation, and never strayed off topic.

  • @Xaoticex
    @Xaoticex 5 หลายเดือนก่อน +2

    Nice, exhaustive and short video considering it covers a lot.

  • @GabrielPozo
    @GabrielPozo 10 หลายเดือนก่อน +1

    Great video! Always an important topic when we think about scale our systems.

    • @AntonPutra
      @AntonPutra  10 หลายเดือนก่อน

      Thank you!

  • @helciopandelo
    @helciopandelo 10 หลายเดือนก่อน +1

    Truly awesome and simple to learn!!! Thank you!!!

    • @AntonPutra
      @AntonPutra  10 หลายเดือนก่อน

      Thank you for the feedback!

  • @PhillyHank
    @PhillyHank 6 หลายเดือนก่อน +1

    Very helpful. Very confused and to the point! I hope your colleagues who do technical videos would follow your framework. 👍🏾👍🏾👍🏾

  • @ab_azmi5584
    @ab_azmi5584 7 หลายเดือนก่อน +1

    Great video. Clear & easy to understand.

    • @AntonPutra
      @AntonPutra  7 หลายเดือนก่อน

      Thanks Ab!

  • @dmitriydiachenko5648
    @dmitriydiachenko5648 10 หลายเดือนก่อน +1

    Awesome video! thanks for explaining it

    • @AntonPutra
      @AntonPutra  10 หลายเดือนก่อน

      Thanks!

  • @shanchessmetilda5550
    @shanchessmetilda5550 2 หลายเดือนก่อน +2

    Great Explanation....Thanks for the efforts

    • @AntonPutra
      @AntonPutra  2 หลายเดือนก่อน

      Thanks!

  • @meron6913
    @meron6913 10 หลายเดือนก่อน +1

    Great video Anton.

    • @AntonPutra
      @AntonPutra  10 หลายเดือนก่อน

      Thank you!

  • @charlesopuoro5295
    @charlesopuoro5295 7 หลายเดือนก่อน

    Thank you so much for this clear, insightful explanation of Database Sharding.

    • @AntonPutra
      @AntonPutra  7 หลายเดือนก่อน

      Thank you, Charles!

  • @bossgd100
    @bossgd100 10 หลายเดือนก่อน +1

    thank you for these explanations

    • @AntonPutra
      @AntonPutra  10 หลายเดือนก่อน

      thanks for visiting

  • @cptn-nemo
    @cptn-nemo 3 หลายเดือนก่อน

    Good explanation, Thanks

  • @erkanakgul6954
    @erkanakgul6954 4 หลายเดือนก่อน +1

    Great explaination! Thanks

    • @AntonPutra
      @AntonPutra  4 หลายเดือนก่อน

      thank you!

  • @dhruvpatel6604
    @dhruvpatel6604 9 หลายเดือนก่อน +1

    Excellent tutorial

    • @AntonPutra
      @AntonPutra  9 หลายเดือนก่อน +1

      Thank you!

  • @LinuxForLife
    @LinuxForLife 10 หลายเดือนก่อน +1

    Very interesting! Thanks! 👍

    • @AntonPutra
      @AntonPutra  10 หลายเดือนก่อน

      welcome! my pleasure

  • @yourname-scorpion
    @yourname-scorpion 16 วันที่ผ่านมา +1

    Great video, thank you

    • @AntonPutra
      @AntonPutra  16 วันที่ผ่านมา

      thanks!

  • @egitim10
    @egitim10 2 หลายเดือนก่อน

    Short,nice,clear

  • @rayaalkhateeb874
    @rayaalkhateeb874 7 หลายเดือนก่อน

    thanks a lot for explaining

    • @AntonPutra
      @AntonPutra  7 หลายเดือนก่อน

      my pleasure!

  • @vikasgoel7529
    @vikasgoel7529 5 หลายเดือนก่อน +2

    Excellent described

    • @AntonPutra
      @AntonPutra  5 หลายเดือนก่อน

      Thanks!

  • @69k_gold
    @69k_gold 13 วันที่ผ่านมา

    Let's say I'm using a shard-nothing architecture, now let's say there's a relationship between customers table, payments table and orders table.
    Customers and orders tables are linked by the foreign key customers->id ~ orders->customer_id
    Orders table and payments table has the foreign key
    orders->id ~ payments->order_id
    Now how would you shard this database? You can't use a single shard key, because both customer_id and order_id are important that ensure all the related rows are in a single shard.
    So how would you solve this problem?

  • @EpoxyArt
    @EpoxyArt 3 หลายเดือนก่อน

    Hi, Anton! How can I search by the field that is not shard key? I need to go thru all the shards?
    And what if I need to scale it up or down (change shards number)?

  • @nicgeorge6126
    @nicgeorge6126 10 หลายเดือนก่อน +2

    Fortunately I’ve been able to get by with two read databases and a write by using table partitioning up until this point. Hopefully I don’t have to tackle sharding any time soon! Great video and thanks for sharing

    • @AntonPutra
      @AntonPutra  10 หลายเดือนก่อน

      Thanks! There a lot of distributed databases based on postgres that can shard for you.

  • @tejapolisettysai6950
    @tejapolisettysai6950 7 หลายเดือนก่อน

    sir thanks for the video, what do you use for editing, its really good.

    • @AntonPutra
      @AntonPutra  7 หลายเดือนก่อน

      thanks, adobe suite

  • @user-yv6ti2wf7c
    @user-yv6ti2wf7c 4 หลายเดือนก่อน

    thanks, but i have a question if i use range-based sharding and conside 4 shard what happen if i want to convert to 40 shard? what happen for previous data, and new data [ first i have 3 shard 1(a-h) 2(i-p) 3(q,z)) now need to make it 40.

    • @AntonPutra
      @AntonPutra  4 หลายเดือนก่อน +1

      If you shard manually at the application level, you need to write logic to rebalance it yourself. It's easier to use built-in mechanisms for sharding.

    • @user-yv6ti2wf7c
      @user-yv6ti2wf7c 4 หลายเดือนก่อน

      @@AntonPutra thanks

  • @ProSunnySharma
    @ProSunnySharma 8 หลายเดือนก่อน +1

    Excellent! What tool do you use to do animations?

    • @AntonPutra
      @AntonPutra  8 หลายเดือนก่อน

      Thanks Adobe suite

  • @ricardorqr
    @ricardorqr 10 หลายเดือนก่อน +2

    How do you create the animation for your videos? They are so cool!!!!! 💪🏼

    • @AntonPutra
      @AntonPutra  10 หลายเดือนก่อน

      Thanks! I use adobe suite.

  • @user-ui5yw6pf5p
    @user-ui5yw6pf5p 2 หลายเดือนก่อน

    you said sharding have unique data sets if one sharding not respond then other sharding response you but if customer search record and that record will be in sharding 1 . After that sharding 1 will not respond then what we have to show for customer

  • @gcheese25
    @gcheese25 7 หลายเดือนก่อน +1

    great video! start subscribing now

    • @AntonPutra
      @AntonPutra  7 หลายเดือนก่อน

      Thank you!

  • @rahuldinesh2840
    @rahuldinesh2840 9 หลายเดือนก่อน +1

    Can I do sharding in WordPress database?

    • @AntonPutra
      @AntonPutra  9 หลายเดือนก่อน

      WordPress uses a MySQL database under the hood. Take a look at Vitess.

  • @noahgsolomon
    @noahgsolomon 8 หลายเดือนก่อน +1

    w video

    • @AntonPutra
      @AntonPutra  8 หลายเดือนก่อน

      thanks

  • @andherium
    @andherium 10 หลายเดือนก่อน

    I think 99.9% use case are served fine by a monolith database server. Heck even stack overflow is fully powered on a single server

    • @cariyaputta
      @cariyaputta 10 หลายเดือนก่อน +3

      Yes. Still, it's useful to have a knowledge of whatever jargons uppermamagements are throwing at you.

    • @AntonPutra
      @AntonPutra  10 หลายเดือนก่อน +2

      For personal projects, sure, but in the enterprise, you frequently have to deal with sharding.

  • @thewaygoesup
    @thewaygoesup 10 หลายเดือนก่อน +1

    your example confusing between database shard and table partitioning
    range-base sharding is about one table sharding not about database sharding.

    • @AntonPutra
      @AntonPutra  10 หลายเดือนก่อน

      Noted, will improve

  • @APoIIy
    @APoIIy 9 หลายเดือนก่อน +1

    So, sharding is a pain in the ass and requires a lot of configuration, analytics and also business logic to manage shards in an respectable way.
    This is also why NoSQL Databases come in handy as they can scale better horizontaly without this extensive configuration activities you have with traditional SQL databases.
    But to be said SQL Databases will probably cover 90% of all usecases anyway without you getting into sharding.

    • @AntonPutra
      @AntonPutra  8 หลายเดือนก่อน

      Nowadays, once a year, I see a new distributed database based on PostgreSQL come out, lol.

  • @yoggg932
    @yoggg932 7 หลายเดือนก่อน

    Feels like a bot is reading the script. Good content, but please act it out a bit.

    • @AntonPutra
      @AntonPutra  7 หลายเดือนก่อน +1

      thanks for the feedback