Рет қаралды 7,772
Traditionally, when a server starts to reach its limit we have simply thrown more resources at it, either more CPU, memory or disk.
However there comes a point, especially in the cloud, where it is no longer possible to add more resources to a database. Here we need a different solution.
Instead of scaling up we must scale out, sometimes called horizontal scaling or sharding.
In this talk we will look at how to scale out in Microsoft Azure SQL database using the Azure Elastic Database tools
We will look at the requirements and options for horizontal scaling in Azure and then we will have a go at sharding an Azure SQL database and then querying and updating the different shards
We will be using t-sql, PowerShell and c# so be prepared for some serious coding.
*****
I've found that there is a mistake when I'm creating the range mappings. The range is actually "greater than or equal" to the RangeLow value to "less than" the RangeHigh value. (not "less than or equal" the RangeHigh as I used here) The RangeHigh value is not actually included in that range but will be the RangeLow value of the next range. So when I created the RangeMappings, Shard1 should have been from 1-8, Shard2 should have been from 8-15 and Shard 3 from 15-22. Which explains why the SplitMerge didn't go quite as planned!
Apologies, sometimes you only learn these things with use.
I wanted to add this comment as an annotation at the point in the video when I create the ranges but google in their wisdom have removed annotations.