Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

SQL Azure Federation and Scalability


Published on

In this presentation we review SQL Azure Federation and Scalability.

Best Regards,

Dr. Eduardo Castro Martinez
Microsoft SQL Server MVP

Published in: Technology
  • Be the first to comment

SQL Azure Federation and Scalability

  1. 1. Ing. Eduardo Castro, PhDecastro@grupoasesor.nethttp://ecastrom.blogspot.comhttp://comunidadwindows.org
  2. 2. Microsoft SQL AzureInformation Platform as a Service Managed Service Scale on Demand Innovate Faster Platform capabilities delivered as a service Database as a utility with pay as you Innovate with new data application (Database, Data Sync, Reporting…) grow scaling patterns Reduced complexity, greater flexibility Rely on Business-ready SLAs Build cloud-based data solutions on a familiar relational model Easy provisioning and deployment Enable multi-tenant solutions Build on existing developer skills and Auto High availability and fault tolerant Manage multiple servers familiar Transact-SQL syntax
  3. 3. A relational DB in the cloud SQL Azure Database Data Hub Others (Future) .NET Services Applications SQL Services Relational database as a service Highly available, automatically maintained Live Services Windows Azure Extension of the SQL Server Data Platform Applications Windows Windows Windows Others Server Vista/XP Mobile
  4. 4. Single Logical Multiple Physical Database Replicas Replica 1 Replica 2 DB Replica 3
  5. 5. Reference Data Sync Data Symmetric Programming Model Data Hub Aggregation• Initial services – core RDBMS capabilities with SQL Azure Database, Data Sync• Future Offerings • Additional data platform capabilities: Reporting, BI • New services: Reference Data
  6. 6. Clear Feedback: “I want a database in the Cloud”Focus on combining the best features of SQL Server running at scale with low friction
  7. 7. Application Application Application Browser Browser ODBC, OLEDB, ADO.N Application Application REST Client REST Client SQL Client* et PHP, Ruby, … Cloud Cloud Evolves HTTP+REST HTTP+REST HTTP HTTP TDS Windows Azure Windows Azure Web App REST (Astoria) Web AppData Center Data Center REST Client ADO.Net + EF SQL Client* REST/SOAP + ACE Model TDS + TSQL Model SDS Current SDS Next * Client access enabled using TDS for ODBC, ADO.Net, OLEDB, PHP-SQL, Ruby, …
  8. 8. SQL Azure Database Others (Future) SQL AzureApplications Windows Azure AppFabricWindows Azure Applications Windows Others
  9. 9. SQL Azure Database TDS DatabaseApplication Database DatabaseSQL Azure Database Others (Future)
  10. 10. SQL Azure Database DatabaseApplication Max database size Database is 50 GB DatabaseApplication Database
  11. 11. Applications use standard SQL client libraries: ODBC, ADO.Net, PHP, … Application Internet Azure Cloud TDS (tcp) Security Boundary Load balancer forwards „sticky‟ sessions to TDS protocol tier LB TDS (tcp) Gateway Gateway Gateway Gateway Gateway Gateway Gateway: TDS protocol gateway, enforces AUTHN/AUTHZ policy; proxy to CloudDB TDS (tcp)L SQL SQL SQL SQL Scalability and Availability: Fabric, Failover, Replication, and Load balancing
  12. 12. Gateway Process TDS Endpoint AdminSvc Endpoint Provisioning Endpoint Protocol Parser Business Logic Services Connection MgmtL SQL SQL SQL SQL Scalability and Availability: Fabric, Failover, Replication, and Load balancing
  13. 13. Live DNS Cluster Customer Browser Live DNS Svc 1 Datacenter (Sub-Region) 5 Portal LB Gateway LB 2 4 3 6Front-end Node Front-end Node Front-end Node Front-end NodeAdmin Portal Admin Portal Gateway Gateway 7 Backend Node Backend Node Backend NodeSQL Server SQL Server SQL Server Mgmt. Mgmt. Mgmt. Services Fabric Services Fabric Services Fabric
  14. 14. 1 TDS Gateway Front-end Node TDS Session Protocol Parser 2 3 Gateway Logic Master Cluster Master Node 4 Master Node Components 7 5 8 6Backend Node 1 Backend Node 2 Backend Node 3 SQL Instance SQL Instance SQL Instance SQL DB SQL DB SQL DB Scalability and and Availability: Fabric,Failover,Replication, and Load balancing Scalability Availability: Fabric, Failover, Replication, and Load balancing
  15. 15. AccountServerDatabase
  16. 16. Challenges Today “Capacity Bursting“ Elastic scale – database as a service Capacity Average Usage Time Pay as you grow and shrink Compute # of Hr‟s Average Usage Easy to provision and manage database No hardware, no manual Promotions, events, ticket selling businesses are “bursts – bound” by database administration required nature Capacity constraints limit business agility High costs of entry into new business Difficult to roll out extra capacity quickly Idle capacity “off-bursts” is cost prohibitive
  17. 17. T1 T2 T3 T4 T5T6 T7 T8 T9 T10 All my data is handled byT11 one DB on one server T12 T13 T14 T15T16 T17 T18 T19 T20
  18. 18. App
  19. 19. − Provisioning Covered by − Growing and shrinking capacity SQL Azure today− Managing − Upgrading, patching, HA for lots of databases− Routing − Where is the directory? − How to scale it and use it? Coming up in SQL Azure:− Partition Management Federations − Splitting and Merging, without loss of availability − Fan-out
  20. 20. Con- figData1 Data2 Data3 Data4 Data5
  21. 21. Root Federation “CustData” (Federation Key: CustID) Member: [min, 100) AU AU AUPK=5 PK=25 PK=35 Member: [100, 488) AU AU AUPK=105 PK=235 PK=365 Member: [488, max) AU AU AUPK=555 PK=2545 PK=3565
  22. 22. SalesDBFederation “Orders_Fed” (Federation Key: CustID) Member: [min, max)
  23. 23. Create a Federation use a BIGINT as the Federation KeyCOS222 What‟s New in Microsoft SQL Azure,
  24. 24. Establish the customerid as the Federation Key Data with the same customerid in these two tables should be treated as an Atomic Unit
  25. 25. COS222 What‟s New in Microsoft SQL Azure,
  26. 26. COS222 What‟s New in Microsoft SQL Azure,
  27. 27. SalesDB ProductsFederation “Orders_Fed” (Federation Key: CustID) Member: [min, max) orders zipcode
  28. 28. SalesDB ProductsFederation “Orders_Fed”(Federation Key: CustID) Member: [min, max) orders zipcode Member: [min, 100)ord zipcodeers Member: [100, max) ord zipcode ers
  29. 29. Federation Root houses the Directory Split the Federation Member into two at the customerid 100 boundaryCOS222 What‟s New in Microsoft SQL Azure,
  30. 30. Use Federation Member that containscustomerids < 100 Use Federation Member that contains customerids > 100
  31. 31. App Member: [min, 100) AU AU AUPK=5 PK=25 PK=56 zipcode
  32. 32. Master prod1 Prod2 prod2 DR1 Master clone copy prod2 clone copy prod2 Master Dev1 clone copy South Central US North Central USCREATE DATABASE efg.prod2clone abc.prod2cloneCREATE DATABASE xyz.prod2clone AS COPY OF xyz.prod2 AS COPY OF xyz.prod2
  33. 33. CTP1 SQL Azure Database Data Sync ServiceRetail Stores For SQL Azure Remote Offices Sync CTP2 On-Premises (Headquarters)