COVID-19 data analytics and reporting with Azure Databricks and Azure SQL

Published Jul 06 2020 06:24 PM 7,215 Views

With the evolving need to keep up with growing data volumes, increased data dependency on the business decision making process and the evolution of data platforms with Cloud Computing, enterprises have widely adopted Unified Analytics systems, Data Warehouses and Data Lakes to fulfil their data analytics and machine learning requirements. To that end, there are technologies to support a modern data warehouse architecture in Azure using platforms like Azure Synapse which is an analytics service that brings together enterprise data warehousing and Big Data analytics. While the modern data warehouse architecture is well poised to serve as a central data repository and to fulfil advanced analytics requirements for many enterprises, there is also a growing desire to be able to support a hybrid OLTP database / Datamart for a wide variety of reporting and data visualization needs to simply serve an enriched dataset.

 

Organizations have invested significantly in leveraging the work of data engineers and data scientists to perform complex data transformations and to produce meticulously crafted machine learning models to deliver invaluable business insights. Disparate datasets are put through a process of sophisticated transformation along with batch scoring / predictions derived from Machine Learning models whose resulting datasets are often required to be stored in relational databases (Operational Data Stores, HTAP databases, Fit-for-purpose Reporting Datamarts etc.). These are use cases where data scientists or data engineers want to be able to simply land and store computed data insights in a relational SQL database to make it easily available to downstream applications and data visualization tools. The purpose of these use cases is not to perform complex computations and aggregations that is best suited for Massively Parallel Processing (MPP) based data warehouses but to serve the transformed dataset to business users and applications via Symmetric-Multi Processing (SMP) SQL databases.

 

The objective of this article is to focus on a use case that demonstrates the integration between Azure Databricks and Azure SQL to deliver insights and data visualizations using a publicly available COVID-19 dataset. While Azure Databricks provides the distributed computing power to process and transform complex datasets, Azure SQL is a fitting recipient of the transformed dataset that surfaces these insights to business users.

 

Azure SQL is a family of fully managed, secure, and intelligent SQL database services that support a wide range of application patterns, from re-hosting and modernizing existing SQL Server workloads to modern cloud application development. With the SQL Server engine powering the Azure SQL family of database services, Azure SQL offers the best-in-class relational, transactional and hybrid analytics database services that truly meets the varying data demands of our customers.

 

The architecture diagram below shows the various layers in a typical data analytics scenario and how Azure SQL can meet the requirements of both the storage layer (storing mission critical application transactions) and the serving layer (delivering pre-aggregated, transformed or predictive insights) that organizations need today. There are various technology services in Azure that can be overlayed on top of these generic architectural layers and we focus on one such pattern in this article that focusses on performing data transformation and producing machine learning predictive insights (using Azure Databricks) while serving the transformed datasets via a Datamart for visualizations and reporting (using Azure SQL).

 

Solution ArchitectureSolution Architecture

 

Apache Spark Connector for SQL Server and Azure SQL

One of the key requirements of the architectural pattern above is to ensure we are able to read data seamlessly into Spark DataFrames for transformation and to write back the transformed dataset to Azure SQL in a performant manner. We recently open-sourced the Spark connector for SQL Server and Azure SQL that was announced here. The Spark connector for SQL Server and Azure SQL is a high-performance connector that enables you to use transactional data in big data analytics and persists results for ad-hoc queries or reporting.

Key features of this connector include:

  • Support for all Spark bindings (Scala, Python, R).
  • Basic authentication and Active Directory (AD) keytab support.
  • Reordered DataFrame write support.
  • Reliable connector support for single instance.

The connector can either be downloaded from this GitHub repo.

  

Solution Walkthrough

To immerse into a working solution to demonstrate the architectural pattern mentioned above, the solution uses a publicly available COVID-19 dataset and runs a machine learning model in Azure Databricks to predict the fatalities of COVID-19 per day in each country. These predictions are then transformed and written into a DataMart in Azure SQL Managed Instance for visualization and reporting. Azure SQL Managed Instance is just one of the services in the Azure SQL family and the same solution can be modified to use other services in Azure SQL.

The dataset is from COVID-19 Data Lake published on Microsoft Azure Open Datasets. The dataset is the latest available public data on geographic distribution of COVID-19 cases worldwide from the European Center for Disease Prevention and Control (ECDC). More information on the dataset and COVID-19 Data Lake can be found here.

 

The solution comprises of the following parts as described in the data flow below.Solution Architecture Numbered .jpg

 

 

  1. The solution extracts the COVID-19 public dataset from the pandemic data lake into Azure Databricks as a Spark DataFrame.
  2. The extracted COVID-19 dataset is cleaned, pre-processed, trained and scored using a Gradient Boosted Trees (GBT) Machine Learning model. GBT is chosen to predict the deaths per day in each country purely for demonstration purposes only and should not be considered as the only model for such prediction
  3. The resulting dataset with the predicted scores is stored into a staging table in Azure SQL Managed Instance for further downstream transformation.
  4. Common data dimension tables and the staging tables from Azure SQL Managed Instance are read into DataFrames in Azure Databricks. Note the two Managed Instances shown in the “Store” and the “Serve” layer are essentially the same instance just depicted in different phases of the data flow. Azure SQL can play the role of both a data storage service and a data serving service for consuming applications / data visualization tools.
  5. The DataFrames containing the necessary dimension and staging data are further refined, joined and transformed to produce a denormalized fact table for reporting. Denormalization of data is highly recommended for reporting and data visualization as the data is structured in a way that optimizes performance of reporting queries and enables slicing-and-dicing of data as desired by business decision makers.
  6. The resulting denormalized data is written to Azure SQL Managed Instance (using the highly performant Spark connector for SQL Server and Azure SQL) which is ready to serve the data to its consumers.

Azure SQL Managed Instance Business Critical tier provides a readable secondary by default and is a fitting solution to read data off the replica while the primary is busy transacting from the application. The solution works just as good with the General Purpose tier except that there is no readable secondary by default (unless a Geo-Replica is provisioned) . Public endpoint for Azure SQL Managed Instance is securely enabled to allow Azure Databricks to connect to the instance. If there are security restrictions in your organization that prevents the usage of public endpoint, the solution will require Azure Databricks to be injected into a Vet and use one of the connectivity architectures either using VNet Peering or VNet-to-VNet VPN Gateway to establish connectivity between Azure Databricks and SQL MI.

 

The solution artefacts and a detailed walkthrough of the various steps are published here.

The transformed dataset can be visualized by data visualization tools like Power BI, consumed by APIs in downstream applications or even visualized in a Databricks notebook as shown below.

Data visualization - MapData visualization - Map

Note the predictions can be further refined by tuning the hyperparameters, by combining features from supplementary datasets and by leveraging other techniques to improve the accuracy of the model.

 

Conclusion

With continuous innovation to meet the growing demands of relational database services, Azure SQL offers the flexibility and deployment options to meet a wide variety of customers’ workloads ranging from real-time IoT streaming scenarios to business decision support systems with Hybrid Transactional and Analytical databases. This article touched upon one such scenario for interaction between predictive batch scoring using Azure Databricks and serving the data to consumers using Azure SQL. Find more scenarios and architectural references at the Azure Architecture Center.

 

%3CLINGO-SUB%20id%3D%22lingo-sub-1505849%22%20slang%3D%22en-US%22%3ECOVID-19%20data%20analytics%20and%20reporting%20with%20Azure%20Databricks%20and%20Azure%20SQL%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1505849%22%20slang%3D%22en-US%22%3E%3CP%3EWith%20the%20evolving%20need%20to%20keep%20up%20with%20growing%20data%20volumes%2C%20increased%20data%20dependency%20on%20the%20business%20decision%20making%20process%20and%20the%20evolution%20of%20data%20platforms%20with%20Cloud%20Computing%2C%20enterprises%20have%20widely%20adopted%20Unified%20Analytics%20systems%2C%20Data%20Warehouses%20and%20Data%20Lakes%20to%20fulfil%20their%20data%20analytics%20and%20machine%20learning%20requirements.%20To%20that%20end%2C%20there%20are%20technologies%20to%20support%20a%20modern%20data%20warehouse%20architecture%20in%20Azure%20using%20platforms%20like%20%3CA%20href%3D%22https%3A%2F%2Fazure.microsoft.com%2Fen-us%2Fservices%2Fsynapse-analytics%2F%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3EAzure%20Synapse%3C%2FA%3E%20which%20is%20an%20analytics%20service%20that%20brings%20together%20enterprise%20data%20warehousing%20and%20Big%20Data%20analytics.%20While%20the%20modern%20data%20warehouse%20architecture%20is%20well%20poised%20to%20serve%20as%20a%20central%20data%20repository%20and%20to%20fulfil%20advanced%20analytics%20requirements%20for%20many%20enterprises%2C%20there%20is%20also%20a%20growing%20desire%20to%20be%20able%20to%20support%20a%20hybrid%20OLTP%20database%20%2F%20Datamart%20for%20a%20wide%20variety%20of%20reporting%20and%20data%20visualization%20needs%20to%20simply%20serve%20an%20enriched%20dataset.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EOrganizations%20have%20invested%20significantly%20in%20leveraging%20the%20work%20of%20data%20engineers%20and%20data%20scientists%20to%20perform%20complex%20data%20transformations%20and%20to%20produce%20meticulously%20crafted%20machine%20learning%20models%20to%20deliver%20invaluable%20business%20insights.%20Disparate%20datasets%20are%20put%20through%20a%20process%20of%20sophisticated%20transformation%20along%20with%20batch%20scoring%20%2F%20predictions%20derived%20from%20Machine%20Learning%20models%20whose%20resulting%20datasets%20are%20often%20required%20to%20be%20stored%20in%20relational%20databases%20(Operational%20Data%20Stores%2C%20HTAP%20databases%2C%20Fit-for-purpose%20Reporting%20Datamarts%20etc.).%20These%20are%20use%20cases%20where%20data%20scientists%20or%20data%20engineers%20want%20to%20be%20able%20to%20simply%20land%20and%20store%20computed%20data%20insights%20in%20a%20relational%20SQL%20database%20to%20make%20it%20easily%20available%20to%20downstream%20applications%20and%20data%20visualization%20tools.%20The%20purpose%20of%20these%20use%20cases%20is%20not%20to%20perform%20complex%20computations%20and%20aggregations%20that%20is%20best%20suited%20for%20Massively%20Parallel%20Processing%20(MPP)%20based%20data%20warehouses%20but%20to%20serve%20the%20transformed%20dataset%20to%20business%20users%20and%20applications%20via%20Symmetric-Multi%20Processing%20(SMP)%20SQL%20databases.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EThe%20objective%20of%20this%20article%20is%20to%20focus%20on%20a%20use%20case%20that%20demonstrates%20the%20integration%20between%20Azure%20Databricks%20and%20Azure%20SQL%20to%20deliver%20insights%20and%20data%20visualizations%20using%20a%20publicly%20available%20COVID-19%20dataset.%20While%20Azure%20Databricks%20provides%20the%20distributed%20computing%20power%20to%20process%20and%20transform%20complex%20datasets%2C%20Azure%20SQL%20is%20a%20fitting%20recipient%20of%20the%20transformed%20dataset%20that%20surfaces%20these%20insights%20to%20business%20users.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CA%20href%3D%22https%3A%2F%2Faka.ms%2Fazure_sql%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3EAzure%20SQL%3C%2FA%3E%26nbsp%3Bis%20a%20family%20of%20fully%20managed%2C%20secure%2C%20and%20intelligent%20SQL%20database%20services%20that%20support%20a%20wide%20range%20of%20application%20patterns%2C%20from%20re-hosting%20and%20modernizing%20existing%20SQL%20Server%20workloads%20to%20modern%20cloud%20application%20development.%20With%20the%20SQL%20Server%20engine%20powering%20the%20Azure%20SQL%20family%20of%20database%20services%2C%20Azure%20SQL%20offers%20the%20best-in-class%20relational%2C%20transactional%20and%20hybrid%20analytics%20database%20services%20that%20truly%20meets%20the%20varying%20data%20demands%20of%20our%20customers.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EThe%20architecture%20diagram%20below%20shows%20the%20various%20layers%20in%20a%20typical%20data%20analytics%20scenario%20and%20how%20Azure%20SQL%20can%20meet%20the%20requirements%20of%20both%20the%20storage%20layer%20(storing%20mission%20critical%20application%20transactions)%20and%20the%20serving%20layer%20(delivering%20pre-aggregated%2C%20transformed%20or%20predictive%20insights)%20that%20organizations%20need%20today.%20There%20are%20various%20technology%20services%20in%20Azure%20that%20can%20be%20overlayed%20on%20top%20of%20these%20generic%20architectural%20layers%20and%20we%20focus%20on%20one%20such%20pattern%20in%20this%20article%20that%20focusses%20on%20performing%20data%20transformation%20and%20producing%20machine%20learning%20predictive%20insights%20(using%20Azure%20Databricks)%20while%20serving%20the%20transformed%20datasets%20via%20a%20Datamart%20for%20visualizations%20and%20reporting%20(using%20Azure%20SQL).%3C%2FP%3E%0A%3CDIV%20id%3D%22tinyMceEditorMohamed%20Kabiruddin_0%22%20class%3D%22mceNonEditable%20lia-copypaste-placeholder%22%3E%26nbsp%3B%3C%2FDIV%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22Solution%20ArchitectureAzureSQL.jpg%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F203783iDA4BE7572FBD4FFA%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22Solution%20ArchitectureAzureSQL.jpg%22%20alt%3D%22Solution%20Architecture%22%20%2F%3E%3CSPAN%20class%3D%22lia-inline-image-caption%22%20onclick%3D%22event.preventDefault()%3B%22%3ESolution%20Architecture%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3EApache%20Spark%20Connector%20for%20SQL%20Server%20and%20Azure%20SQL%3C%2FSTRONG%3E%3C%2FP%3E%0A%3CP%3EOne%20of%20the%20key%20requirements%20of%20the%20architectural%20pattern%20above%20is%20to%20ensure%20we%20are%20able%20to%20read%20data%20seamlessly%20into%20Spark%20DataFrames%20for%20transformation%20and%20to%20write%20back%20the%20transformed%20dataset%20to%20Azure%20SQL%20in%20a%20performant%20manner.%20We%20recently%20open-sourced%20the%20%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2Fmicrosoft%2Fsql-spark-connector%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3ESpark%20connector%20for%20SQL%20Server%20and%20Azure%20SQL%3C%2FA%3E%20that%20was%20announced%20%3CA%20href%3D%22https%3A%2F%2Fcloudblogs.microsoft.com%2Fsqlserver%2F2020%2F06%2F22%2Fapache-spark-connector-for-sql-server-and-azure-sql-is-now-open-source%2F%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Ehere%3C%2FA%3E.%20The%20Spark%20connector%20for%20SQL%20Server%20and%20Azure%20SQL%20is%20a%20high-performance%20connector%20that%20enables%20you%20to%20use%20transactional%20data%20in%20big%20data%20analytics%20and%20persists%20results%20for%20ad-hoc%20queries%20or%20reporting.%3C%2FP%3E%0A%3CP%3EKey%20features%20of%20this%20connector%20include%3A%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3ESupport%20for%20all%20Spark%20bindings%20(Scala%2C%20Python%2C%20R).%3C%2FLI%3E%0A%3CLI%3EBasic%20authentication%20and%20Active%20Directory%20(AD)%20keytab%20support.%3C%2FLI%3E%0A%3CLI%3EReordered%20DataFrame%20write%20support.%3C%2FLI%3E%0A%3CLI%3EReliable%20connector%20support%20for%20single%20instance.%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CP%3EThe%20connector%20can%20either%20be%20downloaded%20from%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2Fmicrosoft%2Fsql-spark-connector%2Freleases%2Ftag%2Fv1.0%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Ethis%20GitHub%20repo%3C%2FA%3E.%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3E%26nbsp%3B%3C%2FSTRONG%3E%3CSTRONG%3E%26nbsp%3B%3C%2FSTRONG%3E%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3ESolution%20Walkthrough%3C%2FSTRONG%3E%3C%2FP%3E%0A%3CP%3ETo%20immerse%20into%20a%20working%20solution%20to%20demonstrate%20the%20architectural%20pattern%20mentioned%20above%2C%20the%20solution%20uses%20a%20publicly%20available%20COVID-19%20dataset%20and%20runs%20a%20machine%20learning%20model%20in%20Azure%20Databricks%20to%20predict%20the%20fatalities%20of%20COVID-19%20per%20day%20in%20each%20country.%20These%20predictions%20are%20then%20transformed%20and%20written%20into%20a%20DataMart%20in%20Azure%20SQL%20Managed%20Instance%20for%20visualization%20and%20reporting.%20Azure%20SQL%20Managed%20Instance%20is%20just%20one%20of%20the%20services%20in%20the%20Azure%20SQL%20family%20and%20the%20same%20solution%20can%20be%20modified%20to%20use%20other%20services%20in%20Azure%20SQL.%3C%2FP%3E%0A%3CP%3E%3CEM%3EThe%20dataset%20is%20from%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fazure.microsoft.com%2Fen-au%2Fservices%2Fopen-datasets%2Fcatalog%2Fecdc-covid-19-cases%2F%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3ECOVID-19%20Data%20Lake%3C%2FA%3E%26nbsp%3Bpublished%20on%20Microsoft%20Azure%20Open%20Datasets.%20The%20dataset%20is%20the%20latest%20available%20public%20data%20on%20geographic%20distribution%20of%20COVID-19%20cases%20worldwide%20from%20the%26nbsp%3BEuropean%20Center%20for%20Disease%20Prevention%20and%20Control%20(ECDC).%20More%20information%20on%20the%20dataset%20and%20COVID-19%20Data%20Lake%20can%20be%20found%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fazure.microsoft.com%2Fen-au%2Fservices%2Fopen-datasets%2Fcatalog%2Fecdc-covid-19-cases%2F%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Ehere%3C%2FA%3E.%3C%2FEM%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EThe%20solution%20comprises%20of%20the%20following%20parts%20as%20described%20in%20the%20data%20flow%20below.%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22Solution%20Architecture%20Numbered%20.jpg%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F203788i2A342009FFA6DEDE%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22Solution%20Architecture%20Numbered%20.jpg%22%20alt%3D%22Solution%20Architecture%20Numbered%20.jpg%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3COL%3E%0A%3CLI%3EThe%20solution%20extracts%20the%20COVID-19%20public%20dataset%20from%20the%20%3CA%20href%3D%22https%3A%2F%2Fazure.microsoft.com%2Fen-au%2Fservices%2Fopen-datasets%2Fcatalog%2Fecdc-covid-19-cases%2F%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Epandemic%20data%20lake%3C%2FA%3E%20into%20Azure%20Databricks%20as%20a%20Spark%20DataFrame.%3C%2FLI%3E%0A%3CLI%3EThe%20extracted%20COVID-19%20dataset%20is%20cleaned%2C%20pre-processed%2C%20trained%20and%20scored%20using%20a%20Gradient%20Boosted%20Trees%20(GBT)%20Machine%20Learning%20model.%20%3CEM%3EGBT%20is%20chosen%20to%20predict%20the%20deaths%20per%20day%20in%20each%20country%20purely%20for%20demonstration%20purposes%20only%20and%20should%20not%20be%20considered%20as%20the%20only%20model%20for%20such%20prediction%3C%2FEM%3E%3C%2FLI%3E%0A%3CLI%3EThe%20resulting%20dataset%20with%20the%20predicted%20scores%20is%20stored%20into%20a%20staging%20table%20in%20Azure%20SQL%20Managed%20Instance%20for%20further%20downstream%20transformation.%3C%2FLI%3E%0A%3CLI%3ECommon%20data%20dimension%20tables%20and%20the%20staging%20tables%20from%20Azure%20SQL%20Managed%20Instance%20are%20read%20into%20DataFrames%20in%20Azure%20Databricks.%20%3CEM%3ENote%20the%20two%20Managed%20Instances%20shown%20in%20the%20%E2%80%9CStore%E2%80%9D%20and%20the%20%E2%80%9CServe%E2%80%9D%20layer%20are%20essentially%20the%20same%20instance%20just%20depicted%20in%20different%20phases%20of%20the%20data%20flow.%20Azure%20SQL%20can%20play%20the%20role%20of%20both%20a%20data%20storage%20service%20and%20a%20data%20serving%20service%20for%20consuming%20applications%20%2F%20data%20visualization%20tools.%3C%2FEM%3E%3C%2FLI%3E%0A%3CLI%3EThe%20DataFrames%20containing%20the%20necessary%20dimension%20and%20staging%20data%20are%20further%20refined%2C%20joined%20and%20transformed%20to%20produce%20a%20denormalized%20fact%20table%20for%20reporting.%20Denormalization%20of%20data%20is%20highly%20recommended%20for%20reporting%20and%20data%20visualization%20as%20the%20data%20is%20structured%20in%20a%20way%20that%20optimizes%20performance%20of%20reporting%20queries%20and%20enables%20slicing-and-dicing%20of%20data%20as%20desired%20by%20business%20decision%20makers.%3C%2FLI%3E%0A%3CLI%3EThe%20resulting%20denormalized%20data%20is%20written%20to%20Azure%20SQL%20Managed%20Instance%20(using%20the%20highly%20performant%20Spark%20connector%20for%20SQL%20Server%20and%20Azure%20SQL)%20which%20is%20ready%20to%20serve%20the%20data%20to%20its%20consumers.%3C%2FLI%3E%0A%3C%2FOL%3E%0A%3CP%3EAzure%20SQL%20Managed%20Instance%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Fazure-sql%2Fmanaged-instance%2Fsql-managed-instance-paas-overview%23business-critical-service-tier%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3EBusiness%20Critical%20tier%3C%2FA%3E%26nbsp%3Bprovides%20a%20readable%20secondary%20by%20default%20and%20is%20a%20fitting%20solution%20to%20read%20data%20off%20the%20replica%20while%20the%20primary%20is%20busy%20transacting%20from%20the%20application.%20The%20solution%20works%20just%20as%20good%20with%20the%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Fazure-sql%2Fmanaged-instance%2Fsql-managed-instance-paas-overview%23general-purpose-service-tier%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3EGeneral%20Purpose%20tier%3C%2FA%3E%26nbsp%3Bexcept%20that%20there%20is%20no%20readable%20secondary%20by%20default%20(unless%20a%20Geo-Replica%20is%20provisioned)%20.%20Public%20endpoint%20for%20Azure%20SQL%20Managed%20Instance%20is%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Fazure-sql%2Fmanaged-instance%2Fpublic-endpoint-overview%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Esecurely%20enabled%3C%2FA%3E%26nbsp%3Bto%20allow%20Azure%20Databricks%20to%20connect%20to%20the%20instance.%20If%20there%20are%20security%20restrictions%20in%20your%20organization%20that%20prevents%20the%20usage%20of%20public%20endpoint%2C%20the%20solution%20will%20require%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Fdatabricks%2Fadministration-guide%2Fcloud-configurations%2Fazure%2Fvnet-inject%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3EAzure%20Databricks%20to%20be%20injected%20into%20a%20Vet%3C%2FA%3E%26nbsp%3Band%20use%20one%20of%20the%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Fazure-sql%2Fmanaged-instance%2Fconnect-application-instance%3Fview%3Dsql-server-2017%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Econnectivity%20architectures%3C%2FA%3E%26nbsp%3Beither%20using%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Fvirtual-network%2Fvirtual-network-peering-overview%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3EVNet%20Peering%3C%2FA%3E%26nbsp%3Bor%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Fvpn-gateway%2Fvpn-gateway-howto-vnet-vnet-resource-manager-portal%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3EVNet-to-VNet%20VPN%20Gateway%3C%2FA%3E%26nbsp%3Bto%20establish%20connectivity%20between%20Azure%20Databricks%20and%20SQL%20MI.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3EThe%20solution%20artefacts%20and%20a%20detailed%20walkthrough%20of%20the%20various%20steps%20are%20published%20%3C%2FSTRONG%3E%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2Fmicrosoft%2Fsql-spark-connector%2Ftree%2Fmaster%2Fsamples%2FDatabricks-AzureSQL%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3E%3CSTRONG%3Ehere%3C%2FSTRONG%3E%3C%2FA%3E.%3C%2FP%3E%0A%3CP%3EThe%20transformed%20dataset%20can%20be%20visualized%20by%20data%20visualization%20tools%20like%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fpowerbi.microsoft.com%2Fen-us%2F%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3EPower%20BI%3C%2FA%3E%2C%20consumed%20by%20APIs%20in%20downstream%20applications%20or%20even%20visualized%20in%20a%20Databricks%20notebook%20as%20shown%20below.%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22map.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F203785i7142BD9E8777EFE1%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22map.png%22%20alt%3D%22Data%20visualization%20-%20Map%22%20%2F%3E%3CSPAN%20class%3D%22lia-inline-image-caption%22%20onclick%3D%22event.preventDefault()%3B%22%3EData%20visualization%20-%20Map%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%3CEM%3ENote%20the%20predictions%20can%20be%20further%20refined%20by%20tuning%20the%20hyperparameters%2C%20by%20combining%20features%20from%20supplementary%20datasets%20and%20by%20leveraging%20other%20techniques%20to%20improve%20the%20accuracy%20of%20the%20model.%3C%2FEM%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3EConclusion%3C%2FSTRONG%3E%3C%2FP%3E%0A%3CP%3EWith%20continuous%20innovation%20to%20meet%20the%20growing%20demands%20of%20relational%20database%20services%2C%20Azure%20SQL%20offers%20the%20flexibility%20and%20deployment%20options%20to%20meet%20a%20wide%20variety%20of%20customers%E2%80%99%20workloads%20ranging%20from%20real-time%20IoT%20streaming%20scenarios%20to%20business%20decision%20support%20systems%20with%20Hybrid%20Transactional%20and%20Analytical%20databases.%20This%20article%20touched%20upon%20one%20such%20scenario%20for%20interaction%20between%20predictive%20batch%20scoring%20using%20Azure%20Databricks%20and%20serving%20the%20data%20to%20consumers%20using%20Azure%20SQL.%20Find%20more%20scenarios%20and%20architectural%20references%20at%20the%20%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Farchitecture%2F%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3EAzure%20Architecture%20Center%3C%2FA%3E.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-TEASER%20id%3D%22lingo-teaser-1505849%22%20slang%3D%22en-US%22%3E%3CP%3EThis%20blog%20focusses%20on%20a%20use%20case%20that%20demonstrates%20the%20integration%20between%20Azure%20Databricks%20and%20Azure%20SQL%20to%20deliver%20insights%20and%20data%20visualizations%20using%20a%20publicly%20available%20COVID-19%20dataset.%3C%2FP%3E%3C%2FLINGO-TEASER%3E%3CLINGO-LABS%20id%3D%22lingo-labs-1505849%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3Eazure%20sql%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EManaged%20Instance%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E
Version history
Last update:
‎Nov 09 2020 09:40 AM
Updated by: