+ All Categories
Home > Documents > 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load...

9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load...

Date post: 24-Dec-2015
Category:
Upload: clinton-cook
View: 214 times
Download: 0 times
Share this document with a friend
Popular Tags:
53
Introduction to Developing With SQL Azure Jeff Mlakar Database Architect Ernst & Young
Transcript
Page 1: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Introduction to Developing With SQL Azure

Jeff MlakarDatabase ArchitectErnst & Young

Page 2: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

About meComputer Science and Mechanical Engineering degrees from the Engineering College at the University of Michigan(pause for “Boo”s from Ohio audience)Started in SQL Server 2000,C++,Started in .NET 1.1,BizTalk 2002Currently work as a Database Architect at accounting firm of Ernst & Young.

(Title has been referred to as Database Architect, SQL Lead Designer/Data Modeler, Senior Application Engineer, … so you tell me)Work on applications to Steward/Manage/ReportOn data across the global firm.

Blog: www.jeffmlakar.com , twitter: @JeffMlakar

Page 3: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

PURPOSE

To introduce you to working with Cloud databases in SQL Azure by working to accomplish a specific goal.

Page 4: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

THE GOAL

Create a Tool in Management Studio that can upload/retrieve common TSQL scripts to/from an online repository.

Page 5: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

AgendaAbout your speakerWhat is the Cloud?Windows Azure Platform OverviewSQL Azure overviewDEMO: Creating an Azure databaseDEMO: Creating your own SSMS AddInDEMO: Developing in the CloudDEMO: Connecting to and using your Cloud DBShow end productSQL Azure PricingSQL Azure News

Page 6: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

What is Cloud Computing?

A Service approach to computing that’s about scaling, abstraction by the vendor, and consumption-based pricing.

Page 7: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Think “Electricity”

Powering your building is like running your website / database

Page 8: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Why use the Cloud? 2 reasons:

1)Scale to and pay for what you use.

2)Only worry about the stuff you know well.

Page 9: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

9

TIME

IT C

AP

AC

ITY

Actual Load

Allocated IT-capacities

Too Much Power

Not Enough Power

Load Forecast

Page 10: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Actual Load

Capacity on Demand

TIME

IT C

AP

AC

ITY

Load Forecast

Page 11: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Cloud Services

Software-as-a-ServiceConsume

GMail

“SaaS”Platform-as-a-Service

Build

Microsoft

“PaaS”Infrastructure-as-a-Service

Host

Amazon

“IaaS”

Page 12: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Cloud ServicesIn-House Software

Storage

Servers

Networking

O/S

Middleware

Virtualization

Data

Applications

Runtime

You m

anage

Infrastructure(as a Service)

Storage

Servers

Networking

O/S

Middleware

Virtualization

Data

Applications

Runtime

Managed b

y v

endor

You m

anage

Platform(as a Service)

Managed b

y v

endor

You m

anage

Storage

Servers

Networking

O/S

Middleware

Virtualization

Applications

Runtime

Data

Software(as a Service)

Managed b

y v

endor

Storage

Servers

Networking

O/S

Middleware

Virtualization

Applications

Runtime

Data

Page 13: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Windows Azure PlatformPaaS

Page 14: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Windows Azure PlatformScalable compute and storageAutomated service managementFamiliar tools, technologies, languages Relational storage for the cloudConsistent development modelAutomated database management

Connect existing apps to the cloudConnect through network boundariesEasily control authorization to apps

Page 15: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Storage Options in Windows Azure Platform:1) Windows Azure Storage Instance: non-relational

storage by means of services that use 1) BLOBS2) Tables3) Queues

(cheap, but have to programmatically handle Referential Integrity, Transactions, Performance, etc…)

2) SQL Azure(more expensive that #1, but gives us relational storage with powerful and robust database engine we all know and love)

Page 16: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

SQL AzureDatabase as a Service

Page 17: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

HistoryFirst introduced in Community Technology Preview (CTP) as SQL Server Data Services (SSDS)SSDS was non-relational (similar to current Windows Azure Storage instances) and was an altogether new approach to persisting data.Customers complained. They wanted:

Relational engineEasy way to Migrate existing appsTo use the skill set they already have.

Exit SSDS. Enter SQL Azure. (Yay! A Database!)

Page 18: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

SQL Azure DatabaseThe first and only true database as a service

Scale On Demand

Innovate FasterManaged Serviceo Database utility; pay as

you growo Business-ready SLAso Enable multi-tenant

solutionso World-wide presence

o Easy provisioning and deployment

o Auto high-availability and fault tolerance

o No need for server or VM administration

o Build cloud-based database solutions on consistent relational model

o Leverage existing skills through existing ecosystem of developer and management tools

Page 19: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

SQL Azure Physical ArchitectureApps Tools

ODBC ADO.NET

TDSSQL Azure Services

Connection Routing

Billing Provisioning

Server

SQL ServerSQL Azure

Fabric

InfrastructureDatabase 1 Database 2 Database 3

Server

SQL ServerSQL Azure

Fabric

Server

SQL ServerSQL Azure

Fabric

Page 20: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Database Replicas (Hooray for HA!)

Replica 1

Replica 2

Replica 3

DB

Single Database Multiple Replicas

Single Primary

Replica 4

!

Page 21: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Logical vs. Physical AdministrationService handles physical management

Automatically provides HA “out of box”Transparent failover in case of failureLoad balancing of data to ensure SLA

SQL Azure focus on logical administrationSchema creation and managementQuery optimizationSecurity management (Logins, Users, Roles)

Page 22: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Azure Code/Data Architecture Options:

Near Far

Page 23: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Azure Code/Data Architecture Options: (cont.)From

Windows AzureFrom Outside

Microsoft Datacenter From Windows Azure & Outside

Microsoft Datacenter

Application / Browser

Windows Azure

SQL Azure

Code Near

App Code / Tools

SQL Azure

MicrosoftDatacenter

Code Far Hybrid

Microsoft Datacente

r

SQL Azure

SQL Server

Microsoft Datacenter Windows

Azure

SQL Azure Data Sync

App Code / Tools

Page 24: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

DEMO TIME!

Create a SQL Azure Server and Database

demo

Page 25: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Steps to Create a SQL Azure Database1) Get a free trial through:

http://www.microsoft.com/windowsazure/free-trial/

Includes one 1 GB DB free for 90 days. Charges begin after that.

2) Go your portal at http://windows.azure.com 3) Select Database -> Your Subscription -> Create

Server.4) Create firewall rules.

DONE!

Page 26: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Steps to Create a SQL Azure Database1) Select Create Database

Page 27: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Create an SSMS AddInStep-by-Step

demo

Page 28: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Steps to Create an SSMS AddIn1) Open Visual Studio.2) File->New Project->Other Project types-

>Extensibility-> Visual Studio AddIn3) Go through Wizard and select “Yes” for creating a

Command Bar UI4) Change Debugging from VS to SSMS by going to

the Project Properties, under “Debug”. 1) Remove Working Directory and Command Line 2) Change Start External Program to

C:\Program Files\Microsoft SQL Server\100\Tools\Binn\VSShell\Common7\IDE\Ssms.exe

Page 29: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Steps to Create an SSMS AddIn (cont.)5) While you’re in Properties, go to Build and Select

“Register for COM interop”6) Delete “.Addin” files7) Add a Setup Project. File->Add->New Project-

>Other Project Types->Setup Proj8) Right-click Setup Proj and Add Project Output.

Select the primary output of your AddIn project9) Select primary output, go to Properties->Register.

Change from vsdrpDoNotRegister to vsdrpCOM

Page 30: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Steps to Create an SSMS AddIn (cont.)10) Add Registry Keys to Setup Proj by right-clicking

and going to View-Registry. Add:[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\100\Tools\Shell\AddIns\AddInName.Connect]"LoadBehavior"=dword:00000001

11)

Add dlls (What make it possible)

Page 31: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Steps to Create an SSMS AddIn (cont.)11) Add DLLs:- SqlWorkbench.Interfaces.dll

- Microsoft.SqlServer.SqlTools.VSIntegration.dll

From: C:\Program Files\Microsoft SQL Server\100\Tools\Binn\VSShell\Common7\IDE

12) Open Connect.cs and add “using Microsoft.SqlServer.Management.UI.VSIntegration”

13) Comment out DTE2 _applicationObject and declaration; that interface is not supported in SSMS AddIn

14) Replace _applicationObject with ServiceCache.ExtensibilityModel

Page 32: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Steps to Create an SSMS AddIn (cont.)15) Locate OnConnection and make connectMode

StartupBefore:

After:

Page 33: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Steps to Create an SSMS AddIn (cont.)16) In Setup Proj, right click Detected Dependencies

and hit Refresh17) In the resulting list, right-click ieframe.dll and

Click “Exclude”. It’s not supported.

Page 34: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Now we’re ready to sayHello World

Page 35: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Steps to Create an SSMS AddIn (cont.)

Page 36: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Steps to Create an SSMS AddIn (cont.)18) Build your AddIn project and Setup Project.19) Run the msi you built and Start Management

Studio

(After you’re installed once, you can just hit F5 to run changes)

Page 37: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Make a more complex App

Page 38: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Add a User ControlCreate a Windows User Control “MainWindow” and launch it like so:

Page 39: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

If you need to create an update:1. In Setup Project Properties,

1. make sure “RemovePreviousVersions” is set to true2. Increment Version 3. Select “Yes” when prompted to update ProductCode

2. Correct update installer to function correctly for COM reg1. Download “Orca.exe”, a database table editor for

creating and editing Windows Installer packages.2. Open the resulting msi in Orca and open table

“InstallExecutionSequence” 3. Find Entry “RemoveExistingProducts” and give it a value

that falls between InstallValidate and InstallInitialize (ie 1450 if InstallValidate is 1400 and InstallInitialize is 1500)

Page 40: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Developing in the Cloud

demo

Page 41: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Database Manager

Page 42: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Connecting to and using your Cloud DB

demo

Page 43: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Use fully-qualified server name and SQL Server Authentication to connect in Connection String

Page 44: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Bail! Drop DB and Server. No more charges!

demo

Page 45: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

New(er) Stuff

SQL Server Reporting ServicesData-tier Application (DAC) framework v2.0 (CTP)Sparse ColumnsInbound data is FREE as of June! Federations

Page 46: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Not supportedChange Data CaptureData AuditingData CompressionExtended EventsExternal Key Management / Extensible Key ManagementFILESTREAM DataIntegrated Full-Text SearchLarge User-Defined Aggregates (UDAs)Large User-Defined Types (UDTs)Performance Data Collection (Data Collector)Policy-Based ManagementResource Governor

Page 47: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Not supported (cont.)SQL Server ReplicationTransparent Data EncryptionCommon Language Runtime (CLR) and CLR User-Defined TypesDatabase MirroringService BrokerTable PartitioningTyped XML and XML indexing is not supported. The XML data type is supported by SQL Azure.Extended Stored ProceduresExtended Properties

See General Guidelines & Limitations:http://msdn.microsoft.com/en-us/library/ff394115.aspx

Page 48: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Useful Tools

SQL Azure Data SyncBased on Microsoft Sync FrameworkEasy way if you want to sync data across data centers or from Cloud to On-Prem

SQL Azure Migration WizardAnalyze a DB or a script for Azure compliancehttp://sqlazuremw.codeplex.com/

Page 49: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

So what does this COST?Edition Web Business Bandwidth

Max 1 GB $9.99/month n/a FREE in / $.15 out / GB /month

Asia:FREE in / $.20 out / GB/month

Max 5 GB $49.95/month n/a same

Max 10 GB n/a $99.99/month same

Max 20 GB n/a $199.98/month same

Max 30 GB n/a $299.97/month same

Max 40 GB n/a $399.96/month same

Max 50 GB n/a $499.95/month same

Page 50: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Summary

SQL Azure provides a highly availablecloud database service.

Infrastructure in managed for youScale On DemandUse your existing skill set to innovate faster

Page 51: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

ResourcesBooks:

Azure in ActionPro SQL Azure

Downloads: Search: “Windows Azure Platform Training Kit”

Links:www.microsoft.com/windowsazure/www.microsoft.com/windowsazure/pricing/

Events:Azure Bootcamp: http://www.azurebootcamp.com/ Charlotte is today and tomorrow

Page 52: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Resources (cont.)My SSMS AddIn for Storing Scripts to Cloud:

http://scriptstore.cloudapp.net Download, install, will appear in Tools->ScriptStore for SSMS 2008/2008R2

My Blog: www.jeffmlakar.com Follow me on twitter: @JeffMlakar

Thanks to Microsoft and Brian Prince for many graphics in this presentation

Page 53: 9 TIME IT CAPACITY Actual Load Allocated IT-capacities Too Much Power Not Enough Power Load Forecast.

Questions?


Recommended