<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Lena Hall</title>
    <description>The latest articles on DEV Community by Lena Hall (@lenadroid).</description>
    <link>https://dev.to/lenadroid</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F114791%2F5518f738-5fad-4045-b189-9f316d5e40b0.jpg</url>
      <title>DEV Community: Lena Hall</title>
      <link>https://dev.to/lenadroid</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/lenadroid"/>
    <language>en</language>
    <item>
      <title>Unleash the Potential of PowerApps with BigData </title>
      <dc:creator>Lena Hall</dc:creator>
      <pubDate>Thu, 09 Jul 2020 17:06:41 +0000</pubDate>
      <link>https://dev.to/azure/unleash-the-potential-of-powerapps-with-bigdata-eog</link>
      <guid>https://dev.to/azure/unleash-the-potential-of-powerapps-with-bigdata-eog</guid>
      <description> 
&lt;h4&gt;
  
  
  #PowerfulDevs Conference
&lt;/h4&gt;

&lt;p&gt;&lt;code&gt;RSVP HERE BY JULY 15:&lt;/code&gt; &lt;/p&gt;

&lt;p&gt;&lt;a href="https://aka.ms/powerfuldevsconf" rel="noopener noreferrer"&gt;https://aka.ms/powerfuldevsconf&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;The &lt;a href="https://aka.ms/powerfuldevsconf" rel="noopener noreferrer"&gt;Powerful DEVs Conference&lt;/a&gt; is the first virtual conference of its kind. We will showcase how developers can leverage the Power Platform to build applications faster and with far less effort. Connect with industry-recognized ProDev influencers, Microsoft Cloud Advocates, trusted and diverse community leaders, and members of the Power Platform Team. &lt;/p&gt;

&lt;p&gt;&lt;code&gt;BOOKMARK THIS FOR RESOURCES AND DISCUSSION WITH SPEAKERS&lt;/code&gt;&lt;br&gt;&lt;br&gt;
&lt;/p&gt;
&lt;div class="ltag__link"&gt;
  &lt;a href="/azure" class="ltag__link__link"&gt;
    &lt;div class="ltag__link__org__pic"&gt;
      &lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Forganization%2Fprofile_image%2F512%2F64ce0b82-730d-4ca0-8359-2c21513a0063.jpg" alt="Microsoft Azure"&gt;
      &lt;div class="ltag__link__user__pic"&gt;
        &lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F422403%2F5e52a938-ac03-4919-afca-d684c4a3e39a.jpg" alt=""&gt;
      &lt;/div&gt;
    &lt;/div&gt;
  &lt;/a&gt;
  &lt;a href="/azure/powerfuldevs-conference-join-us-on-july-15th-online-fe3" class="ltag__link__link"&gt;
    &lt;div class="ltag__link__content"&gt;
      &lt;h2&gt;#powerfuldevs Conference: Join us on July 15th Online!&lt;/h2&gt;
      &lt;h3&gt;JennyMEvents for Microsoft Azure ・ Jul 10 '20&lt;/h3&gt;
      &lt;div class="ltag__link__taglist"&gt;
        &lt;span class="ltag__link__tag"&gt;#powerfuldevs&lt;/span&gt;
        &lt;span class="ltag__link__tag"&gt;#powerplatform&lt;/span&gt;
        &lt;span class="ltag__link__tag"&gt;#prodev&lt;/span&gt;
        &lt;span class="ltag__link__tag"&gt;#programming&lt;/span&gt;
      &lt;/div&gt;
    &lt;/div&gt;
  &lt;/a&gt;
&lt;/div&gt;
 

&lt;p&gt;Revisit this page during the event to engage in live (and post-event) discussions on those topics with both speakers and community. The speakers will be here for a live Q&amp;amp;A for at least 30 minutes immediately after their session concludes. After the event, come back to find additional slides, videos, and resources for this session. &lt;/p&gt;


 

&lt;h2&gt;
  
  
  About This Session:
&lt;/h2&gt;

&lt;p&gt;&lt;code&gt;July 15, 2020: 15:00 PDT - 15:25 PDT&lt;/code&gt; &lt;/p&gt;

&lt;p&gt;Learn how to extract value from your data to bring the impact of your low-code solutions to a whole new level. PowerApps already enable creation of useful business applications with minimal effort. In this session, you will learn about how and why to connect your applications to Azure services responsible for Big Data. You will see an example of an application that keeps track of NYC taxi logs and provides logistical information for greater business insights. You will leave this session with confident understanding of what Big Data connection options PowerApps provide, how to connect your application to Big Data, as well as how to reference and visualize it. &lt;/p&gt;

&lt;h2&gt;
  
  
  About the Speakers:
&lt;/h2&gt;

&lt;p&gt;Lena Hall is a Principal Software Engineer @Microsoft and the Team Lead for Big Data Services. Follow &lt;a href="https://%20https://twitter.com/lenadroid" rel="noopener noreferrer"&gt;@lenadroid&lt;/a&gt; on Twitter. &lt;/p&gt;

&lt;h2&gt;
  
  
  Additional Resources
&lt;/h2&gt;

&lt;p&gt;Dev'ing for Power Apps session&lt;/p&gt;

&lt;p&gt;DevTo page:  &lt;a href="https://aka.ms/PowerAppsDevs" rel="noopener noreferrer"&gt;https://aka.ms/PowerAppsDevs&lt;/a&gt;&lt;/p&gt;

</description>
      <category>ama</category>
      <category>powerfuldevs</category>
      <category>azure</category>
      <category>powerapps</category>
    </item>
    <item>
      <title>Applied Cloud Stories: Winning Entries</title>
      <dc:creator>Lena Hall</dc:creator>
      <pubDate>Tue, 16 Jun 2020 18:45:38 +0000</pubDate>
      <link>https://dev.to/azure/applied-cloud-stories-winning-entries-3n66</link>
      <guid>https://dev.to/azure/applied-cloud-stories-winning-entries-3n66</guid>
      <description>&lt;p&gt;In January this year, we launched &lt;a href="https://aka.ms/applied-cloud-stories"&gt;Applied Cloud Stories&lt;/a&gt; initiative - a call for new content created by independent community members, focusing on practical stories about scenarios and workloads that can run on Azure.&lt;/p&gt;

&lt;p&gt;Over the last couple of months, we were fortunate to receive a number of outstanding community stories. Many of them shared lessons learned, trade-offs, tips and tricks, and valuable experience. We are grateful for every single story we received from you! &lt;/p&gt;

&lt;p&gt;We are absolutely delighted to share the winners of &lt;a href="https://aka.ms/applied-cloud-stories"&gt;Applied Cloud Stories&lt;/a&gt; initiative!&lt;/p&gt;

&lt;h2&gt;
  
  
  ✨ Machine Learning and Data Science ✨
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://www.linkedin.com/pulse/optimize-azure-ml-iot-production-usage-reducing-data-cost-logvinskiy/"&gt;"Optimize Azure ML IoT for Production Usage"&lt;/a&gt; by &lt;a href="https://uk.linkedin.com/in/vlogvinskiy"&gt;Valentyn Logvinskiy&lt;/a&gt;.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;"Over the last few years IoT devices and ML/AI have become very popular, and now a lot of companies are moving forward to use them in production. All cloud providers, including Microsoft Azure, provides services how to deploy developed machine learning algorithms to the edge device. The main concern of some industries (automotive, agriculture, etc.) is that in production the cost for data transfer, out of the total cost of ownership, will be huge."&lt;/p&gt;

&lt;p&gt;"Let's take a look at how Azure ML IoT works and when reducing the data transfer matters."&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--yOo3aRK5--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://media-exp1.licdn.com/dms/image/C4D12AQF24QLFEhje5A/article-cover_image-shrink_600_2000/0%3Fe%3D1597881600%26v%3Dbeta%26t%3DpxVjyihhBuekIhpnYej1RheN-K8Sn1b0bEi5TgGvnVo" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--yOo3aRK5--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://media-exp1.licdn.com/dms/image/C4D12AQF24QLFEhje5A/article-cover_image-shrink_600_2000/0%3Fe%3D1597881600%26v%3Dbeta%26t%3DpxVjyihhBuekIhpnYej1RheN-K8Sn1b0bEi5TgGvnVo" alt="machine learning diagram"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  💬 Reviewer's Note 💬
&lt;/h3&gt;

&lt;p&gt;The reviewers highlighted that the author does a superb work with using different technologies on Azure and applying them to solve a real technical challenge and a business problem. The fact that he demonstrates how to reduce the size for the Docker image layers, which need to be transferred to the IoT device is very unique and has a visible business impact: the cost of the update of the model in production decreases exponentially and other developers and data scientists can leverage this lesson to operationalize their IoT solutions while maintaining costs low.&lt;/p&gt;

&lt;h2&gt;
  
  
  ✨ DevOps and Infrastructure ✨
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://4bes.nl/2020/04/02/deploy-a-test-environment-with-a-calendar-appointment/"&gt;Deploy a Test Environment With a Calendar Appointment&lt;/a&gt; by &lt;a href="https://twitter.com/ba4bes"&gt;Barbara Forbes&lt;/a&gt;.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;"How to find an automated and easy way to create a non-production environment?"&lt;/p&gt;

&lt;p&gt;"In most cases, the ongoing situation is that developers are sharing VMs with the needed applications, or they use their own workstation. While this works, it is far from ideal. I found a solution, using PowerShell, ARM Templates and Azure Serverless services. In this post I want to talk about how to deploy a test environment with a calendar appointment."&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--FBFXJTD1--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://4bes.nl/wp-content/uploads/2020/03/diagram02.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--FBFXJTD1--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://4bes.nl/wp-content/uploads/2020/03/diagram02.png" alt="devops diagram"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  💬 Reviewer's Note 💬
&lt;/h3&gt;

&lt;p&gt;Our reviewers found the idea and the concept described in the article to be interesting and original! They appreciated that the author technically shows how to use "unexpected" APIs integrations to trigger various cloud actions.&lt;/p&gt;

&lt;h2&gt;
  
  
  ✨ Applications ✨
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://www.cloudskew.com/about/cloudskew-architecture.html"&gt;CloudSkew Architecture&lt;/a&gt; by &lt;a href="https://twitter.com/MithunShanbhag"&gt;Mithun Shanbhag&lt;/a&gt;.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;"CloudSkew's infrastructure has been built on top of various Azure services - snapped together like lego blocks."&lt;/p&gt;

&lt;p&gt;"Deep-dive on CloudSkew's building blocks discussing the lessons learnt, key decisions &amp;amp; trade offs made."&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--7NyCdXXv--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://www.cloudskew.com/assets/img/cloudskew-architecture.7f1edd8b.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--7NyCdXXv--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://www.cloudskew.com/assets/img/cloudskew-architecture.7f1edd8b.png" alt="applications architecture"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  💬 Reviewer's Note 💬
&lt;/h3&gt;

&lt;p&gt;The reviewers noted the wide spectrum of topics and technologies covered in this amazing article. Incredible covering of monitoring and incident management, things like manual approvals, and many more. The author also focused on technology choices and tradeoffs, such as PaaS vs Kubernetes.&lt;/p&gt;

&lt;h2&gt;
  
  
  ✨ Research ✨
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://github.com/PascalS86/Docs/tree/master/AzureCloudStories"&gt;Azure Notebooks And Cognitive Services Within An University Class&lt;/a&gt; by &lt;a href="https://twitter.com/PaSe_Lp"&gt;Pascal&lt;/a&gt;.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;"This story shows how we used &lt;a href="https://notebooks.azure.com/"&gt;Azure Notebooks&lt;/a&gt; for providing an interactive learning experience in class."&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--CkVgOJGd--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://github.com/PascalS86/Docs/raw/master/AzureCloudStories/images/SampleSolution.PNG" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--CkVgOJGd--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://github.com/PascalS86/Docs/raw/master/AzureCloudStories/images/SampleSolution.PNG" alt="research diagram"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  💬 Reviewer's Note 💬
&lt;/h3&gt;

&lt;p&gt;The reviewers agreed the story is a nice use case for academic audiences. It shows how easy is it to use Azure to teach students. &lt;/p&gt;

&lt;h2&gt;
  
  
  What's Next?
&lt;/h2&gt;

&lt;p&gt;Congratulations to authors of the winning stories!&lt;/p&gt;

&lt;p&gt;Over the next days, we will be reaching out to the winners and to authors of submission that Applied Cloud Stories Committee chose to feature.&lt;/p&gt;

&lt;p&gt;We look forward to publishing winning and featured stories on Microsoft content properties and sharing with you very soon! We are incredibly grateful for hearing all the amazing community stories.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Large-scale Data Analytics with Azure Synapse - Workspaces with CLI </title>
      <dc:creator>Lena Hall</dc:creator>
      <pubDate>Wed, 20 May 2020 17:20:09 +0000</pubDate>
      <link>https://dev.to/azure/large-scale-data-analytics-with-azure-synapse-workspaces-with-cli-3g99</link>
      <guid>https://dev.to/azure/large-scale-data-analytics-with-azure-synapse-workspaces-with-cli-3g99</guid>
      <description>&lt;p&gt;One of the challenges of large scale data analysis is being able to get the value from data with least effort. Doing that often involves multiple stages: provisioning infrastructure, accessing or moving data, transforming or filtering data, analyzing and learning from data, automating the data pipelines, connecting with other services that provide input or consume the output data, and more. There are quite a few tools available to solve these questions, but it's usually difficult to have them all in one place and easily connected.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;If this article was helpful or interesting to you, follow &lt;a href="https://twitter.com/lenadroid" rel="noopener noreferrer"&gt;@lenadroid&lt;/a&gt; on Twitter. &lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  Introduction
&lt;/h2&gt;

&lt;p&gt;This is the first article in this series, which will cover what Azure Synapse is and how to start using it with Azure CLI. Make sure your &lt;a href="https://docs.microsoft.com/en-us/cli/azure?WT.mc_id=synapse-blog-alehall" rel="noopener noreferrer"&gt;Azure CLI&lt;/a&gt; is installed and up-to-date, and add a &lt;code&gt;synapse&lt;/code&gt; extension if necessary:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;$ &lt;/span&gt;az extension add &lt;span class="nt"&gt;--name&lt;/span&gt; synapse
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;What is Azure Synapse?&lt;/strong&gt;&lt;br&gt;
In Azure, we have &lt;a href="https://docs.microsoft.com/en-us/azure/synapse-analytics/sql-data-warehouse/sql-data-warehouse-overview-what-is?WT.mc_id=synapse-blog-alehall" rel="noopener noreferrer"&gt;Synapse Analytics&lt;/a&gt; service, which aims to provide managed support for distributed data analysis workloads with less friction. If you're coming from GCP or AWS background, Azure Synapse alternatives in other clouds are products like BigQuery or Redshift. Azure Synapse is currently in public preview.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Serverless and provisioned capacity&lt;/strong&gt;&lt;br&gt;
In the world of large-scale data processing and analytics, things like autoscale clusters and pay-for-what-you-use has become a must-have. In Azure Synapse, you can choose between &lt;a href="https://docs.microsoft.com/en-us/azure/synapse-analytics/overview-what-is?WT.mc_id=synapse-blog-alehall" rel="noopener noreferrer"&gt;serverless and provisioned&lt;/a&gt; capacity, depending on whether you need to be flexible and adjust to bursts, or have a predictable resource load.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Native Apache Spark support&lt;/strong&gt;&lt;br&gt;
Apache Spark has demonstrated its power in data processing for both batch and real-time streaming models. It offers a great Python and Scala/Java support for data operations at large scale. Azure Synapse provides &lt;a href="https://docs.microsoft.com/en-us/azure/synapse-analytics/quickstart-apache-spark-notebook?WT.mc_id=synapse-blog-alehall" rel="noopener noreferrer"&gt;built-in support&lt;/a&gt; for data analytics using Apache Spark. It's possible to create an Apache Spark pool, upload Spark jobs, or create Spark notebooks for experimenting with the data.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;SQL support&lt;/strong&gt;&lt;br&gt;
In addition to Apache Spark support, Azure Synapse has excellent support for data analytics with &lt;a href="https://docs.microsoft.com/en-us/azure/synapse-analytics/quickstart-create-sql-pool-portal?WT.mc_id=synapse-blog-alehall" rel="noopener noreferrer"&gt;SQL&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Other features&lt;/strong&gt;&lt;br&gt;
Azure Synapse provides smooth integration with Azure Machine Learning and Spark ML. It enables convenient data ingestion and export using Azure Data Factory, which connects with many Azure and independent data input and output sources. Data can be effectively visualized with PowerBI.&lt;/p&gt;

&lt;p&gt;At Microsoft Build 2020, Satya Nadella announced &lt;a href="https://azure.microsoft.com/en-us/blog/azure-analytics-clarity-in-an-instant?WT.mc_id=synapse-blog-alehall" rel="noopener noreferrer"&gt;Synapse Link&lt;/a&gt; functionality that will help get insights from real-time transactional data stored in operational databases (e.g. Cosmos DB) with a single click, without the need to manage data movement.&lt;/p&gt;
&lt;h2&gt;
  
  
  Get started with Azure Synapse Workspaces using Azure CLI
&lt;/h2&gt;

&lt;p&gt;Prepare the necessary environment variables:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;$ StorageAccountName&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;'&amp;lt;come up with a name for your storage account&amp;gt;'&lt;/span&gt;
&lt;span class="nv"&gt;$ ResourceGroup&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;'&amp;lt;come up with a name for your resource group&amp;gt;'&lt;/span&gt;
&lt;span class="nv"&gt;$ Region&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;'&amp;lt;come up with a name of the region, e.g. eastus&amp;gt;'&lt;/span&gt;
&lt;span class="nv"&gt;$ FileShareName&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;'&amp;lt;come up with a name of the storage file share&amp;gt;'&lt;/span&gt;
&lt;span class="nv"&gt;$ SynapseWorkspaceName&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;'&amp;lt;come up with a name for Synapse Workspace&amp;gt;'&lt;/span&gt;
&lt;span class="nv"&gt;$ SqlUser&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;'&amp;lt;come up with a username&amp;gt;'&lt;/span&gt;
&lt;span class="nv"&gt;$ SqlPassword&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s1"&gt;'&amp;lt;come up with a secure password&amp;gt;'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Create a resource group as a container for your resources:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;$ &lt;/span&gt;az group create &lt;span class="nt"&gt;--name&lt;/span&gt; &lt;span class="nv"&gt;$ResourceGroup&lt;/span&gt; &lt;span class="nt"&gt;--location&lt;/span&gt; &lt;span class="nv"&gt;$Region&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Create a Data Lake storage account:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;$ &lt;/span&gt;az storage account create &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;--name&lt;/span&gt; &lt;span class="nv"&gt;$StorageAccountName&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;--resource-group&lt;/span&gt; &lt;span class="nv"&gt;$ResourceGroup&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;--location&lt;/span&gt; &lt;span class="nv"&gt;$Region&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;--sku&lt;/span&gt; Standard_GRS &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;--kind&lt;/span&gt; StorageV2
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The output of this command will be similar to:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="err"&gt;-&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="err"&gt;Finished&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="err"&gt;..&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"accessTier"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"Hot"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"creationTime"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"2020-05-19T01:32:42.434045+00:00"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"customDomain"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"enableAzureFilesAadIntegration"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"enableHttpsTrafficOnly"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;false&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"encryption"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"keySource"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"Microsoft.Storage"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"keyVaultProperties"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"services"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"blob"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="nl"&gt;"enabled"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="nl"&gt;"lastEnabledTime"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"2020-05-19T01:32:42.496550+00:00"&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"file"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="nl"&gt;"enabled"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="nl"&gt;"lastEnabledTime"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"2020-05-19T01:32:42.496550+00:00"&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"queue"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"table"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"failoverInProgress"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"geoReplicationStats"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"id"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"/subscriptions/&amp;lt;subscription-id&amp;gt;/resourceGroups/Synapse-test/providers/Microsoft.Storage/storageAccounts/&amp;lt;storage-account-name&amp;gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"identity"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"isHnsEnabled"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"kind"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"StorageV2"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"lastGeoFailoverTime"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"location"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"eastus"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"name"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"&amp;lt;storage-account-name&amp;gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"networkRuleSet"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"bypass"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"AzureServices"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"defaultAction"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"Allow"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"ipRules"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[],&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"virtualNetworkRules"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[]&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"primaryEndpoints"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"blob"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"https://&amp;lt;storage-account-name&amp;gt;.blob.core.windows.net/"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"dfs"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"https://&amp;lt;storage-account-name&amp;gt;.dfs.core.windows.net/"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"file"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"https://&amp;lt;storage-account-name&amp;gt;.file.core.windows.net/"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"queue"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"https://&amp;lt;storage-account-name&amp;gt;.queue.core.windows.net/"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"table"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"https://&amp;lt;storage-account-name&amp;gt;.table.core.windows.net/"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"web"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"https://&amp;lt;storage-account-name&amp;gt;.z13.web.core.windows.net/"&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"primaryLocation"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"eastus"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"provisioningState"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"Succeeded"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"resourceGroup"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"&amp;lt;resource-group-name&amp;gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"secondaryEndpoints"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"secondaryLocation"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"westus"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"sku"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"capabilities"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"kind"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"locations"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"name"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"Standard_GRS"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"resourceType"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"restrictions"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;null&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"tier"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"Standard"&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"statusOfPrimary"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"available"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"statusOfSecondary"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"available"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"tags"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{},&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"Microsoft.Storage/storageAccounts"&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Retrieve the storage account key:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;$ StorageAccountKey&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="si"&gt;$(&lt;/span&gt;az storage account keys list &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;--account-name&lt;/span&gt; &lt;span class="nv"&gt;$StorageAccountName&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  | jq &lt;span class="nt"&gt;-r&lt;/span&gt; &lt;span class="s1"&gt;'.[0] | .value'&lt;/span&gt;&lt;span class="si"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Retrieve Storage Endpoint URL:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;$ StorageEndpointUrl&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="si"&gt;$(&lt;/span&gt;az storage account show &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;--name&lt;/span&gt; &lt;span class="nv"&gt;$StorageAccountName&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;--resource-group&lt;/span&gt; &lt;span class="nv"&gt;$ResourceGroup&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  | jq &lt;span class="nt"&gt;-r&lt;/span&gt; &lt;span class="s1"&gt;'.primaryEndpoints | .dfs'&lt;/span&gt;&lt;span class="si"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You can always check what your storage account key and endpoint are by looking at them, if you'd like:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;$ &lt;/span&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Storage Account Key: &lt;/span&gt;&lt;span class="nv"&gt;$StorageAccountKey&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;
&lt;span class="nv"&gt;$ &lt;/span&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"Storage Endpoint URL: &lt;/span&gt;&lt;span class="nv"&gt;$StorageEndpointUrl&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Create a fileshare:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;$ &lt;/span&gt;az storage share create &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;--account-name&lt;/span&gt; &lt;span class="nv"&gt;$StorageAccountName&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;--account-key&lt;/span&gt; &lt;span class="nv"&gt;$StorageAccountKey&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;--name&lt;/span&gt; &lt;span class="nv"&gt;$FileShareName&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Create a Synapse Workspace:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;$ &lt;/span&gt;az synapse workspace create &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;--name&lt;/span&gt; &lt;span class="nv"&gt;$SynapseWorkspaceName&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;--resource-group&lt;/span&gt; &lt;span class="nv"&gt;$ResourceGroup&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;--storage-account&lt;/span&gt; &lt;span class="nv"&gt;$StorageAccountName&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;--file-system&lt;/span&gt; &lt;span class="nv"&gt;$FileShareName&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;--sql-admin-login-user&lt;/span&gt; &lt;span class="nv"&gt;$SqlUser&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;--sql-admin-login-password&lt;/span&gt; &lt;span class="nv"&gt;$SqlPassword&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;--location&lt;/span&gt; &lt;span class="nv"&gt;$Region&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The output of the command should show the successful creation:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="o"&gt;{&lt;/span&gt;- Finished ..
  &lt;span class="s2"&gt;"connectivityEndpoints"&lt;/span&gt;: &lt;span class="o"&gt;{&lt;/span&gt;
    &lt;span class="s2"&gt;"dev"&lt;/span&gt;: &lt;span class="s2"&gt;"https://&amp;lt;synapse-workspace-name&amp;gt;.dev.azuresynapse.net"&lt;/span&gt;,
    &lt;span class="s2"&gt;"sql"&lt;/span&gt;: &lt;span class="s2"&gt;"&amp;lt;synapse-workspace-name&amp;gt;.sql.azuresynapse.net"&lt;/span&gt;,
    &lt;span class="s2"&gt;"sqlOnDemand"&lt;/span&gt;: &lt;span class="s2"&gt;"&amp;lt;synapse-workspace-name&amp;gt;-ondemand.sql.azuresynapse.net"&lt;/span&gt;,
    &lt;span class="s2"&gt;"web"&lt;/span&gt;: &lt;span class="s2"&gt;"https://web.azuresynapse.net?workspace=%2fsubscriptions%&amp;lt;subscription-id&amp;gt;%2fresourceGroups%2fS&amp;lt;resource-group-name&amp;gt;%2fproviders%2fMicrosoft.Synapse%2fworkspaces%&amp;lt;synapse-workspace-name&amp;gt;"&lt;/span&gt;
  &lt;span class="o"&gt;}&lt;/span&gt;,
  &lt;span class="s2"&gt;"defaultDataLakeStorage"&lt;/span&gt;: &lt;span class="o"&gt;{&lt;/span&gt;
    &lt;span class="s2"&gt;"accountUrl"&lt;/span&gt;: &lt;span class="s2"&gt;"https://&amp;lt;storage-account-name&amp;gt;.dfs.core.windows.net"&lt;/span&gt;,
    &lt;span class="s2"&gt;"filesystem"&lt;/span&gt;: &lt;span class="s2"&gt;"&amp;lt;file-share-name&amp;gt;"&lt;/span&gt;
  &lt;span class="o"&gt;}&lt;/span&gt;,
  &lt;span class="s2"&gt;"id"&lt;/span&gt;: &lt;span class="s2"&gt;"/subscriptions/&amp;lt;subscription-id&amp;gt;/resourceGroups/&amp;lt;resource-group-name&amp;gt;/providers/Microsoft.Synapse/workspaces/&amp;lt;synapse-workspace-name&amp;gt;"&lt;/span&gt;,
  &lt;span class="s2"&gt;"identity"&lt;/span&gt;: &lt;span class="o"&gt;{&lt;/span&gt;
    &lt;span class="s2"&gt;"principalId"&lt;/span&gt;: &lt;span class="s2"&gt;"&amp;lt;principal-id&amp;gt;"&lt;/span&gt;,
    &lt;span class="s2"&gt;"tenantId"&lt;/span&gt;: &lt;span class="s2"&gt;"&amp;lt;tenant-id&amp;gt;"&lt;/span&gt;,
    &lt;span class="s2"&gt;"type"&lt;/span&gt;: &lt;span class="s2"&gt;"SystemAssigned"&lt;/span&gt;
  &lt;span class="o"&gt;}&lt;/span&gt;,
  &lt;span class="s2"&gt;"location"&lt;/span&gt;: &lt;span class="s2"&gt;"eastus"&lt;/span&gt;,
  &lt;span class="s2"&gt;"managedResourceGroupName"&lt;/span&gt;: &lt;span class="s2"&gt;"&amp;lt;managed-tesource-group-id&amp;gt;"&lt;/span&gt;,
  &lt;span class="s2"&gt;"name"&lt;/span&gt;: &lt;span class="s2"&gt;"&amp;lt;synapse-workspace-name&amp;gt;"&lt;/span&gt;,
  &lt;span class="s2"&gt;"provisioningState"&lt;/span&gt;: &lt;span class="s2"&gt;"Succeeded"&lt;/span&gt;,
  &lt;span class="s2"&gt;"resourceGroup"&lt;/span&gt;: &lt;span class="s2"&gt;"&amp;lt;resource-group-name&amp;gt;"&lt;/span&gt;,
  &lt;span class="s2"&gt;"sqlAdministratorLogin"&lt;/span&gt;: &lt;span class="s2"&gt;"&amp;lt;admin-login&amp;gt;"&lt;/span&gt;,
  &lt;span class="s2"&gt;"sqlAdministratorLoginPassword"&lt;/span&gt;: &amp;lt;admin-password&amp;gt;,
  &lt;span class="s2"&gt;"tags"&lt;/span&gt;: null,
  &lt;span class="s2"&gt;"type"&lt;/span&gt;: &lt;span class="s2"&gt;"Microsoft.Synapse/workspaces"&lt;/span&gt;,
  &lt;span class="s2"&gt;"virtualNetworkProfile"&lt;/span&gt;: null
&lt;span class="o"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;After you successfully created these resources, you should be able to go to Azure Portal, and navigate to the resource called &lt;code&gt;$SynapseWorkspaceName&lt;/code&gt; within &lt;code&gt;$ResourceGroup&lt;/code&gt; resource group. You should see a similar page:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fx43czkxwz9kfjhgt7n3b.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fx43czkxwz9kfjhgt7n3b.png" alt="Synapse Workspaces Page in Azure Portal"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What's next?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;You can now load data and experiment with it in Synapse Data Studio, create Spark or SQL pools and run analytics queries, connect to PowerBI and visualize your data, and many more.&lt;/p&gt;

&lt;p&gt;Stay tuned for next articles in this series to learn more! Thanks for reading!&lt;/p&gt;

&lt;p&gt;If this article was interesting to you, follow &lt;a href="https://twitter.com/lenadroid" rel="noopener noreferrer"&gt;@lenadroid&lt;/a&gt; on Twitter. &lt;/p&gt;

</description>
      <category>cloud</category>
      <category>azure</category>
      <category>computerscience</category>
      <category>data</category>
    </item>
    <item>
      <title>Apache Kafka Applications Can Work Without Apache Kafka Cluster?</title>
      <dc:creator>Lena Hall</dc:creator>
      <pubDate>Fri, 03 Apr 2020 16:00:23 +0000</pubDate>
      <link>https://dev.to/azure/apache-kafka-applications-can-work-without-apache-kafka-cluster-3en5</link>
      <guid>https://dev.to/azure/apache-kafka-applications-can-work-without-apache-kafka-cluster-3en5</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;If this article was interesting to you, follow &lt;a href="https://twitter.com/lenadroid" rel="noopener noreferrer"&gt;@lenadroid&lt;/a&gt; on Twitter. If you prefer video format better, take a look at &lt;a href="https://aka.ms/azfr/623/yt" rel="noopener noreferrer"&gt;this video&lt;/a&gt; about the topic. &lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;a href="https://kafka.apache.org/" rel="noopener noreferrer"&gt;Apache Kafka&lt;/a&gt; and &lt;a href="https://azure.microsoft.com/en-us/services/event-hubs?WT.mc_id=kafkaeventhubs-blog-alehall" rel="noopener noreferrer"&gt;Azure Event Hubs&lt;/a&gt; are two different systems for managing events, that have the same goal in mind. Their aim is to provide distributed, reliable, fault-tolerant, persistent, scalable, and fast system for managing events, decoupling event publishers and subscribers, making it easier to build event-driven architectures.&lt;/p&gt;

&lt;p&gt;Many projects already rely on Apache Kafka for event ingestion, because it has the richest ecosystem around it, many contributors, a variety of open-source libraries, connectors, and projects available.&lt;/p&gt;

&lt;p&gt;Apache Kafka can run anywhere - in the cloud and on-premises. For example, one can run it on Azure using &lt;a href="https://docs.microsoft.com/en-us/azure/hdinsight/kafka/apache-kafka-introduction?WT.mc_id=kafkaeventhubs-blog-alehall" rel="noopener noreferrer"&gt;HDInsight for Apache Kafka&lt;/a&gt;, or deploy it on standard VMs.&lt;/p&gt;

&lt;p&gt;One of the things we always have to keep in mind, there is infrastructure behind Apache Kafka that we have to maintain. Apache Kafka assumes of a cluster of broker VMs, which we need to manage. Sometimes we want to spend the least amount of time managing the infrastructure, but still, have a reliable backend for event-ingestion. This is the exact reason why someone might want to take a look at using Event Hubs for Apache Kafka ecosystems. You can keep using your existing Apache Kafka applications unchanged, and rely on Azure Event Hubs as a backend for your event-ingestion by just swapping the connection information. This allows to keep using Apache Kafka connectors and libraries to hundreds of projects and delegate the complexity to Azure Event Hubs behind the scenes to help you focus on code instead of maintaining infrastructure. &lt;/p&gt;

&lt;h2&gt;
  
  
  I'm confused, how can I use Apache Kafka and Event Hubs together? Event Hubs for Apache Kafka? What does it mean?
&lt;/h2&gt;

&lt;p&gt;There are three parts we need to think about:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;What is the system we work with on the backend - the one that collects events from producers and distributes it to subscribers?&lt;/strong&gt; This could be Apache Kafka installed on pure VMs in your data center, Apache Kafka running in the cloud, or it can be Event Hubs - a managed service in Azure.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;What is the application we have to work with the backend event-ingestion system?&lt;/strong&gt; This can be an event producer, an event consumer, a command line application that connects to the backend event system.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;How does the client event application talk to the backend event system?&lt;/strong&gt; When the backend system is Apache Kafka, clients can talk to it using Apache Kafka API. When we decide to use Event Hubs, clients can talk to it using the standard Event Hubs API or using Apache Kafka API (thanks to &lt;a href="https://docs.microsoft.com/en-us/azure/event-hubs/event-hubs-for-kafka-ecosystem-overview?WT.mc_id=kafkaeventhubs-blog-alehall" rel="noopener noreferrer"&gt;Event Hubs for Kafka ecosystems&lt;/a&gt; feature).&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;This way, if you are already working with Apache Kafka, it can be easy to simplify management of your event infrastructure. You can keep using your existing Apache Kafka applications unchanged, and rely on Azure Event Hubs as a backend for your event-ingestion by just swapping the connection information. This allows us to keep using Apache Kafka connectors and libraries to hundreds of projects and delegate the complexity to Azure Event Hubs behind the scenes to help you focus on code instead of maintaining infrastructure.&lt;/p&gt;

&lt;h2&gt;
  
  
  A Real-World Example
&lt;/h2&gt;

&lt;p&gt;Using Apache Kafka for event streaming scenarios is a very common use case. Frequently it is used together with &lt;a href="https://spark.apache.org/" rel="noopener noreferrer"&gt;Apache Spark&lt;/a&gt; - an event processing and distributed computing system.&lt;/p&gt;

&lt;p&gt;There are many advantages of using Apache Kafka. One of them is the availability of so many useful libraries and connectors that let you send and receive events to and from a big variety of sources. Kafka ecosystem is incredibly rich and the community is very active.&lt;/p&gt;

&lt;p&gt;Let’s take a look at a common architecture with Apache Kafka. &lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fy12iemi4xgzfiz8k2x8z.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fy12iemi4xgzfiz8k2x8z.png" alt="Kafka and Spark architecture"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Apache Kafka acts as a data ingestion component, that receives data from some data producer. It can be data sent from sensors or other applications.&lt;/p&gt;

&lt;p&gt;Apache Spark is a data processing system that receives the data and performs some processing logic with the data it receives in real-time.&lt;/p&gt;

&lt;p&gt;There is nothing wrong with this architecture, and it’s very common. However, it can get complicated to run and manage your own Kafka clusters. Managing a Kafka cluster can become a full-time job. To make sure your Kafka cluster operates correctly and is performant, you usually have to tune and configure virtual machines that Kafka uses called brokers. When the cluster is scaled up or new topics are added you’d need to perform partition rebalancing. There are many similar things you’ll need to take care of.&lt;/p&gt;

&lt;h2&gt;
  
  
  Can We Simplify This?
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ft4ibp5u6q135ttptphzc.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ft4ibp5u6q135ttptphzc.png" alt="Event Hubs and Spark"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;One of the things you &lt;em&gt;can&lt;/em&gt; do to optimize your architecture is to use a managed service that will eliminate the need for cluster maintenance. Event Hubs is a completely managed service in Azure that can ingest millions of events per second and costs 3 cents an hour. It is very similar to Apache Kafka in what its goal is. There are some differences in how they work. For example, with Event Hubs, you can use the Auto-Inflate feature to automatically adjust throughput according to workload spikes, and many more useful features.&lt;/p&gt;

&lt;p&gt;In most cases, nobody wants to rewrite code and move to another service, and this is exactly the case with Event Hubs. Because Event Hubs protocol is binary compatible Apache Kafka, you can still use the code that you wrote that already works with Apache Kafka, and it will work with Event Hubs as well. This means you can still use your favorite Apache Kafka libraries, such as &lt;a href="https://spark.apache.org/docs/latest/streaming-kafka-0-10-integration.html" rel="noopener noreferrer"&gt;Spark-to-Kafka&lt;/a&gt; connector, and use Event Hubs as a backend for event ingestion and not ever think about cluster management again. &lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Frxth5ed3v1ci4r9xmz3l.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Frxth5ed3v1ci4r9xmz3l.png" alt="image"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;To start using Event Hubs with your existing Apache Kafka logic, all you need to do is change the configuration to point to Event Hubs instead of Kafka. If with Apache Kafka we use bootstrap servers to connect to it, with Event Hubs we’d use the public URL and connection string to connect.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F8og9qw9h72b80rd1bxi3.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F8og9qw9h72b80rd1bxi3.png" alt="image"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;As a result, we didn't change any logic for producer and consumer, we didn't change any libraries. With the only change in connection configuration, we can provide seamless migration to a completely managed service for event ingestion, and we can use it with many Apache Kafka clients, libraries, and existing applications.&lt;/p&gt;

&lt;h2&gt;
  
  
  Can You Show Us The Code?
&lt;/h2&gt;

&lt;p&gt;Why, yes. Let’s take a look at how this can be done in-action!&lt;/p&gt;

&lt;p&gt;Let's say, a company is already using Apache Kafka on HDInsight for their events, together with Apache Spark to process them.&lt;/p&gt;

&lt;p&gt;They have an HDInsight Kafka cluster that looks like this:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F78rdejcmuc6ay2bm0tx6.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F78rdejcmuc6ay2bm0tx6.png" alt="image"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;They also have an Azure Databricks workspace that looks like this:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Facrril6ud9i4blzq1duq.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Facrril6ud9i4blzq1duq.png" alt="image"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Their Spark cluster exists in the same virtual network as the Kafka cluster (using &lt;a href="https://docs.microsoft.com/en-us/azure/azure-databricks/vnet-injection?WT.mc_id=kafkaeventhubs-blog-alehall" rel="noopener noreferrer"&gt;VNet Injection&lt;/a&gt; feature), and has the following Spark-Kafka connector library attached:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fa5ary641y00bptg9kwyo.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fa5ary641y00bptg9kwyo.png" alt="image"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Let's generate the data for this use case. We can think of it as sensor data with a timestamp and some numerical indicator, which we generate using rate stream in Spark and send it to Kafka using the Spark-Kafka connector. Let's run it in Azure Databricks Notebook:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight scala"&gt;&lt;code&gt;

&lt;span class="c1"&gt;// MESSAGE PRODUCER LOGIC&lt;/span&gt;
&lt;span class="k"&gt;val&lt;/span&gt; &lt;span class="nv"&gt;rates&lt;/span&gt; &lt;span class="k"&gt;=&lt;/span&gt;
  &lt;span class="n"&gt;spark&lt;/span&gt;
  &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;readStream&lt;/span&gt;
  &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;format&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"rate"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
  &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"rowsPerSecond"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt;&lt;span class="mi"&gt;10&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
  &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;load&lt;/span&gt;

&lt;span class="c1"&gt;// MESSAGE PRODUCER CONFIGURATION&lt;/span&gt;
&lt;span class="c1"&gt;// CAN BE READ PURELY FROM CONFIGURATION FILES&lt;/span&gt;
&lt;span class="c1"&gt;// REPLACE TOPIC NAME AND BOOTSTRAP SERVERS WITH CORRECT VALUES&lt;/span&gt;
&lt;span class="k"&gt;val&lt;/span&gt; &lt;span class="nv"&gt;TOPIC&lt;/span&gt; &lt;span class="k"&gt;=&lt;/span&gt; &lt;span class="s"&gt;"testtopic"&lt;/span&gt;
&lt;span class="k"&gt;val&lt;/span&gt; &lt;span class="nv"&gt;BOOTSTRAP_SERVERS&lt;/span&gt; &lt;span class="k"&gt;=&lt;/span&gt; &lt;span class="s"&gt;"172.16.0.4:9092,172.16.0.6:9092,172.16.0.5:9092"&lt;/span&gt;

&lt;span class="n"&gt;rates&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;select&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="n"&gt;$&lt;/span&gt;&lt;span class="s"&gt;"timestamp"&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;alias&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"key"&lt;/span&gt;&lt;span class="o"&gt;),&lt;/span&gt; &lt;span class="n"&gt;$&lt;/span&gt;&lt;span class="s"&gt;"value"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;selectExpr&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"CAST(key as STRING)"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="s"&gt;"CAST(value as STRING)"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;writeStream&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;format&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"kafka"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"topic"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nc"&gt;TOPIC&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"kafka.bootstrap.servers"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nc"&gt;BOOTSTRAP_SERVERS&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"checkpointLocation"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="s"&gt;"/ratecheckpoint"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;start&lt;/span&gt;&lt;span class="o"&gt;()&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ffppjifkj52apxvpxniy3.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ffppjifkj52apxvpxniy3.png" alt="image"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The real-time event stream of sensor data is consumed by a separate notebook:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight scala"&gt;&lt;code&gt;

&lt;span class="c1"&gt;// CONSUMER CONFIGURATION&lt;/span&gt;
&lt;span class="c1"&gt;// REPLACE TOPIC NAME AND BOOTSTRAP SERVERS WITH CORRECT VALUES&lt;/span&gt;
&lt;span class="k"&gt;val&lt;/span&gt; &lt;span class="nv"&gt;TOPIC&lt;/span&gt; &lt;span class="k"&gt;=&lt;/span&gt; &lt;span class="s"&gt;"testtopic"&lt;/span&gt;
&lt;span class="k"&gt;val&lt;/span&gt; &lt;span class="nv"&gt;BOOTSTRAP_SERVERS&lt;/span&gt; &lt;span class="k"&gt;=&lt;/span&gt; &lt;span class="s"&gt;"172.16.0.4:9092,172.16.0.6:9092,172.16.0.5:9092"&lt;/span&gt;

&lt;span class="k"&gt;val&lt;/span&gt; &lt;span class="nv"&gt;rates&lt;/span&gt; &lt;span class="k"&gt;=&lt;/span&gt; &lt;span class="nv"&gt;spark&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;readStream&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;format&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"kafka"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"subscribe"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nc"&gt;TOPIC&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"kafka.bootstrap.servers"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nc"&gt;BOOTSTRAP_SERVERS&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"kafka.request.timeout.ms"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="s"&gt;"60000"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"kafka.session.timeout.ms"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="s"&gt;"60000"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"failOnDataLoss"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="s"&gt;"false"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"startingOffsets"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="s"&gt;"latest"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;load&lt;/span&gt;&lt;span class="o"&gt;()&lt;/span&gt;

&lt;span class="c1"&gt;// PROCESSING LOGIC &lt;/span&gt;
&lt;span class="n"&gt;rates&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;selectExpr&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"CAST(key as STRING)"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="s"&gt;"CAST(value as STRING)"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;writeStream&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;outputMode&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"append"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;format&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"console"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"truncate"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt;&lt;span class="o"&gt;).&lt;/span&gt;&lt;span class="py"&gt;start&lt;/span&gt;&lt;span class="o"&gt;().&lt;/span&gt;&lt;span class="py"&gt;awaitTermination&lt;/span&gt;&lt;span class="o"&gt;()&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fanza7l5p3cfg3aa9f14o.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fanza7l5p3cfg3aa9f14o.png" alt="image"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;We use &lt;code&gt;bootstrap servers&lt;/code&gt; to connect to the Apache Kafka cluster brokers in both, producer and consumer, and work with &lt;code&gt;testtopic&lt;/code&gt; topic. On instructions for creating a topic in HDInsight Kafka and getting Kafka broker addresses, take a look at this &lt;a href="https://docs.microsoft.com/en-us/azure/hdinsight/kafka/apache-kafka-get-started?WT.mc_id=kafkaeventhubs-blog-alehall" rel="noopener noreferrer"&gt;document&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Swapping Apache Kafka backend with Event Hubs but leaving the code and libraries as is.
&lt;/h3&gt;

&lt;p&gt;Now we want to start using Event Hubs, so we create a new Event Hubs with Apache Kafka &lt;a href="https://docs.microsoft.com/en-us/azure/event-hubs/event-hubs-for-kafka-ecosystem-overview?WT.mc_id=kafkaeventhubs-blog-alehall" rel="noopener noreferrer"&gt;feature&lt;/a&gt; enabled, and add a new &lt;code&gt;testtopic&lt;/code&gt; hub.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7o4z8zy7gwcjozwgnyor.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7o4z8zy7gwcjozwgnyor.png" alt="image"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;To make the same code work with the new event backend, we only need to change the connection configuration in both producer and consumer. Instead of using IP addresses for brokers in &lt;code&gt;bootstrap servers&lt;/code&gt;, we use Event Hubs endpoint. We also specify Event Hubs connection string. Because Event Hubs is a managed service, there is no cluster we need to manage, and the &lt;code&gt;namespace&lt;/code&gt; (an alternative to the &lt;code&gt;cluster&lt;/code&gt; in Apache Kafka terms) is just a container for topics. Scalability is managed using throughput units (1 TU = 1MB/sec, or 1000 events/sec) and can be adjusted automatically according to workload spikes.&lt;/p&gt;

&lt;p&gt;Producer code:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight scala"&gt;&lt;code&gt;

&lt;span class="c1"&gt;// UNCHANGED MESSAGE PRODUCER LOGIC&lt;/span&gt;
&lt;span class="k"&gt;val&lt;/span&gt; &lt;span class="nv"&gt;rates&lt;/span&gt; &lt;span class="k"&gt;=&lt;/span&gt; 
    &lt;span class="n"&gt;spark&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;readStream&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;format&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"rate"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"rowsPerSecond"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt;&lt;span class="mi"&gt;10&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;load&lt;/span&gt;


&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="nn"&gt;kafkashaded.org.apache.kafka.common.security.plain.PlainLoginModule&lt;/span&gt;
&lt;span class="k"&gt;val&lt;/span&gt; &lt;span class="nv"&gt;TOPIC&lt;/span&gt; &lt;span class="k"&gt;=&lt;/span&gt; &lt;span class="s"&gt;"testtopic"&lt;/span&gt;

&lt;span class="c1"&gt;// NEW VALUE, REPLACE EVENTHUBSNAME WITH YOUR OWN VALUE&lt;/span&gt;
&lt;span class="k"&gt;val&lt;/span&gt; &lt;span class="nv"&gt;BOOTSTRAP_SERVERS&lt;/span&gt; &lt;span class="k"&gt;=&lt;/span&gt; &lt;span class="s"&gt;"EVENTHUBSNAME.servicebus.windows.net:9093"&lt;/span&gt;

&lt;span class="c1"&gt;// NEW VALUE, REPLACE EVENTHUBSNAME, SECRETKEYNAME, SECRETKEYVALUE WITH YOUR OWN VALUES&lt;/span&gt;
&lt;span class="k"&gt;val&lt;/span&gt; &lt;span class="nv"&gt;EH_SASL&lt;/span&gt; &lt;span class="k"&gt;=&lt;/span&gt; &lt;span class="s"&gt;"org.apache.kafka.common.security.plain.PlainLoginModule required username=\"$ConnectionString\" password=\"Endpoint=sb://EVENTHUBSNAME.servicebus.windows.net/;SharedAccessKeyName=SECRETKEYNAME;SharedAccessKey=SECRETKEYVALUE\";"&lt;/span&gt;

&lt;span class="n"&gt;rates&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;select&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="n"&gt;$&lt;/span&gt;&lt;span class="s"&gt;"timestamp"&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;alias&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"key"&lt;/span&gt;&lt;span class="o"&gt;),&lt;/span&gt; &lt;span class="n"&gt;$&lt;/span&gt;&lt;span class="s"&gt;"value"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;selectExpr&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"CAST(key as STRING)"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="s"&gt;"CAST(value as STRING)"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;writeStream&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;format&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"kafka"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"topic"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nc"&gt;TOPIC&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"kafka.bootstrap.servers"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nc"&gt;BOOTSTRAP_SERVERS&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"kafka.sasl.mechanism"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="s"&gt;"PLAIN"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"kafka.security.protocol"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="s"&gt;"SASL_SSL"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"kafka.sasl.jaas.config"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nc"&gt;EH_SASL&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"checkpointLocation"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="s"&gt;"/ratecheckpoint"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;start&lt;/span&gt;&lt;span class="o"&gt;()&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F2ot74dq3n47xp2oodxkc.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F2ot74dq3n47xp2oodxkc.png" alt="image"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Consumer code:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight scala"&gt;&lt;code&gt;

&lt;span class="c1"&gt;//CONSUMER CONFIGURATION &lt;/span&gt;
&lt;span class="k"&gt;val&lt;/span&gt; &lt;span class="nv"&gt;TOPIC&lt;/span&gt; &lt;span class="k"&gt;=&lt;/span&gt; &lt;span class="s"&gt;"testtopic"&lt;/span&gt;

&lt;span class="c1"&gt;// NEW VALUE, REPLACE EVENTHUBSNAME WITH YOUR OWN VALUE&lt;/span&gt;
&lt;span class="k"&gt;val&lt;/span&gt; &lt;span class="nv"&gt;BOOTSTRAP_SERVERS&lt;/span&gt; &lt;span class="k"&gt;=&lt;/span&gt; &lt;span class="s"&gt;"EVENTHUBSNAME.servicebus.windows.net:9093"&lt;/span&gt;

&lt;span class="c1"&gt;// NEW VALUE, REPLACE EVENTHUBSNAME, SECRETKEYNAME, SECRETKEYVALUE WITH YOUR OWN VALUES&lt;/span&gt;
&lt;span class="k"&gt;val&lt;/span&gt; &lt;span class="nv"&gt;EH_SASL&lt;/span&gt; &lt;span class="k"&gt;=&lt;/span&gt; &lt;span class="s"&gt;"org.apache.kafka.common.security.plain.PlainLoginModule required username=\"$ConnectionString\" password=\"Endpoint=sb://EVENTHUBSNAME.servicebus.windows.net/;SharedAccessKeyName=SECRETKEYNAME;SharedAccessKey=SECRETKEYVALUE\";"&lt;/span&gt;

&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="nn"&gt;org.apache.kafka.common.security.plain.PlainLoginModule&lt;/span&gt;

&lt;span class="c1"&gt;// READ STREAM USING SPARK's KAFKA CONNECTOR&lt;/span&gt;
&lt;span class="k"&gt;val&lt;/span&gt; &lt;span class="nv"&gt;rates&lt;/span&gt; &lt;span class="k"&gt;=&lt;/span&gt; &lt;span class="nv"&gt;spark&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;readStream&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;format&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"kafka"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"subscribe"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nc"&gt;TOPIC&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"kafka.bootstrap.servers"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nc"&gt;BOOTSTRAP_SERVERS&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"kafka.sasl.mechanism"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="s"&gt;"PLAIN"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"kafka.security.protocol"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="s"&gt;"SASL_SSL"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"kafka.sasl.jaas.config"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nc"&gt;EH_SASL&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"kafka.request.timeout.ms"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="s"&gt;"60000"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"kafka.session.timeout.ms"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="s"&gt;"60000"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"failOnDataLoss"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="s"&gt;"false"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"startingOffsets"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="s"&gt;"latest"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"kafka.group.id"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="s"&gt;"$Default"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;load&lt;/span&gt;&lt;span class="o"&gt;()&lt;/span&gt;

&lt;span class="c1"&gt;// UNCHANGED PROCESSING LOGIC &lt;/span&gt;
&lt;span class="n"&gt;rates&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;selectExpr&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"CAST(key as STRING)"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="s"&gt;"CAST(value as STRING)"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;writeStream&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;outputMode&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"append"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;format&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"console"&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;
    &lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="py"&gt;option&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"truncate"&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt;&lt;span class="o"&gt;).&lt;/span&gt;&lt;span class="py"&gt;start&lt;/span&gt;&lt;span class="o"&gt;().&lt;/span&gt;&lt;span class="py"&gt;awaitTermination&lt;/span&gt;&lt;span class="o"&gt;()&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fxp3w6ftkdd27xsrncp1d.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fxp3w6ftkdd27xsrncp1d.png" alt="image"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  When Should I Still Use Apache Kafka Cluster?
&lt;/h2&gt;

&lt;p&gt;For example, when you &lt;em&gt;want&lt;/em&gt; or &lt;em&gt;need&lt;/em&gt; to manage your own cluster, or when you want to run Apache Kafka on-premises. Or, if there are certain features not yet supported by Event Hubs Kafka feature.&lt;/p&gt;

&lt;h2&gt;
  
  
  When Should I Use Event Hubs With Apache Kafka Clients?
&lt;/h2&gt;

&lt;p&gt;When you are happy with what Event Hubs provides, and want to reduce the time you spend on managing clusters. Event Hubs offers better integration with existing Azure services. You can also mix and match Apache Kafka and Event Hubs clients! Event Hubs supports many automation features, like auto-inflate to scale the system and adjust it for the workload.&lt;/p&gt;

&lt;p&gt;Take a look at other &lt;a href="https://github.com/Azure/azure-event-hubs-for-kafka/blob/master/tutorials/?WT.mc_id=kafkaeventhubs-github-alehall" rel="noopener noreferrer"&gt;interesting examples&lt;/a&gt; of technologies Event Hubs for Apache Kafka can be used for.&lt;/p&gt;

&lt;h2&gt;
  
  
  Summary
&lt;/h2&gt;

&lt;p&gt;We can keep using Apache Kafka libraries and connectors when using Event Hubs as a backend event injection system, which opens the door to an incredible number of integrations.&lt;/p&gt;

</description>
      <category>opensource</category>
      <category>computerscience</category>
      <category>kafka</category>
      <category>cloud</category>
    </item>
    <item>
      <title>Applied Cloud Stories</title>
      <dc:creator>Lena Hall</dc:creator>
      <pubDate>Tue, 21 Jan 2020 17:22:24 +0000</pubDate>
      <link>https://dev.to/azure/applied-cloud-stories-3f04</link>
      <guid>https://dev.to/azure/applied-cloud-stories-3f04</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;Have experience with building practical applications or driving complex workloads on &lt;a href="https://docs.microsoft.com/azure/azure-functions/?WT.mc_id=appliedcloudstories_devto-cxa"&gt;Azure&lt;/a&gt;. &lt;em&gt;Share your #AppliedCloudStories with us!&lt;/em&gt;&lt;br&gt;
✓ Sign up for a &lt;a href="https://azure.microsoft.com/free/?WT.mc_id=appliedcloudstories_devto-cxa"&gt;free account on Azure&lt;/a&gt; and validate stories &lt;br&gt;
✓ Submit your story and &lt;a class="twitter-share-button" href="https://twitter.com/intent/tweet?text=I'm%20joining%20the%20@azureadvocates%20%23AppliedCloudStories%20challenge!!%20Learn%20more%20at%20https://aka.ms/applied-cloud-stories%20and%20join%20me!"&gt; spread the word on Twitter!  &lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;



&lt;p&gt;We are delighted to announce the &lt;a href="https://aka.ms/applied-cloud-stories"&gt;Applied Cloud Stories&lt;/a&gt; initiative by Microsoft!&lt;/p&gt;

&lt;h3&gt;
  
  
  📚 What Is Applied Cloud Stories?
&lt;/h3&gt;

&lt;p&gt;Do you work with open-source? Are you passionate about machine learning or data science? Do you have stories to share about solving scale or data challenges? Are you investing time and effort so that you and your teams can ship code better, faster, with more confidence? Do you work with Java, Python, JavaScript, Go, Rust, or other exciting languages in the cloud? Are you active in computer science research and love when theory meets practice?&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;We would love to hear your &lt;a href="https://aka.ms/applied-cloud-stories"&gt;story&lt;/a&gt;.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Applied Cloud Stories is an open call for technical content about relevant cloud scenarios and workloads, interesting challenges, and practical solutions that can run on Azure. You can participate by writing a new article, or recording a new video about the topic of your choice in one of the categories:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Open Source&lt;/li&gt;
&lt;li&gt;Applications&lt;/li&gt;
&lt;li&gt;DevOps + Infrastructure&lt;/li&gt;
&lt;li&gt;Big Data + Distributed Systems&lt;/li&gt;
&lt;li&gt;Machine Learning + Data Science&lt;/li&gt;
&lt;li&gt;Research&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Share your stories before &lt;strong&gt;March 15, 2020&lt;/strong&gt;! Learn more about the timelines, rules of participation, and details about each category in the &lt;a href="https://aka.ms/applied-cloud-stories"&gt;announcement&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  📚 Why Should I Participate?
&lt;/h3&gt;

&lt;p&gt;Your stories will help inspire and educate engineers across the globe about how to approach advanced, innovative, and mission-critical cloud scenarios that are solving specific problems.&lt;/p&gt;

&lt;p&gt;All of the stories will be reviewed by the amazing committee consisting of Azure engineering leaders, cloud advocates, and industry leaders, like &lt;a href="https://twitter.com/editingemily"&gt;Emily Freeman&lt;/a&gt;, &lt;a href="https://twitter.com/jpetazzo"&gt;Jérôme Petazzoni&lt;/a&gt;, &lt;a href="https://twitter.com/ashleymcnamara"&gt;Ashley McNamara&lt;/a&gt;, &lt;a href="https://twitter.com/sarahnovotny"&gt;Sarah Novotny&lt;/a&gt;, &lt;a href="https://twitter.com/aronchick"&gt;David Aronchick&lt;/a&gt;, &lt;a href="//twitter.com/nnja"&gt;Nina Zakharenko&lt;/a&gt; and &lt;a href="https://aka.ms/applied-cloud-stories#reviewers"&gt;more&lt;/a&gt;. &lt;/p&gt;

&lt;p&gt;Applied Cloud Stories &lt;a href="https://aka.ms/applied-cloud-stories#reviewers"&gt;Reviewers&lt;/a&gt; will vote to determine winning and featured stories.  We will help share featured stories with the world! Winning stories will receive &lt;a href="https://aka.ms/applied-cloud-stories"&gt;prizes and rewards&lt;/a&gt;! &lt;/p&gt;

&lt;h3&gt;
  
  
  📚 Wait, I Have To Write About Azure?
&lt;/h3&gt;

&lt;p&gt;Not really! The minimal requirement is to use any part of the Azure platform to run scenario workloads on. However, we are not looking for tutorials that explain how to apply Azure services to solve the task. We are more interested to hear about people’s scenarios and technology choices first. Check out the &lt;a href="https://aka.ms/applied-cloud-stories"&gt;announcement&lt;/a&gt; for the examples.&lt;/p&gt;

&lt;h3&gt;
  
  
  Need Ideas?
&lt;/h3&gt;

&lt;p&gt;Don't hesitate to reach out to &lt;a href="//twitter.com/lenadroid"&gt;me&lt;/a&gt; or to any of the committee members to validate your ideas, we'd love to help!&lt;/p&gt;

&lt;p&gt;To make it easier, our committee members worked on example good story titles to inspire more ideas!&lt;/p&gt;

</description>
      <category>news</category>
      <category>cloud</category>
      <category>opensource</category>
    </item>
    <item>
      <title>Story of Eventually Perfect Distributed Systems</title>
      <dc:creator>Lena Hall</dc:creator>
      <pubDate>Thu, 22 Aug 2019 00:12:22 +0000</pubDate>
      <link>https://dev.to/lenadroid/story-of-eventually-perfect-distributed-systems-209a</link>
      <guid>https://dev.to/lenadroid/story-of-eventually-perfect-distributed-systems-209a</guid>
      <description>&lt;p&gt;&lt;em&gt;This article is based on O'Reilly Velocity 2019 Keynote by &lt;a href="//twitter.com/lenadroid"&gt;@lenadroid&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;It's about the impact of our work, the complexity and obstacles we face, and what is important for building better distributed systems, especially when other life-critical areas rely on and build on what we create.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Systems available today already offer many solutions, encapsulate a lot of the distributed algorithms, automate, and abstract away some of the complexity. Engineers who use them don’t necessarily have to have the same massive knowledge that was required to develop them in the first place. Even though there is less and less necessity for new engineers to learn the fundamentals those systems are built on, there are scenarios when knowing what is behind the scenes is essential to making the right decisions and to solving difficult issues that come up when something doesn’t act as expected.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Are Fundamentals Still Important?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Why is it important to come back to fundamentals from where we are now? We are at the point, where distributed systems get increasing adoption in the medical field, autonomous devices, transport automation, and other life-critical scenarios, where the cost of the mistake is growing, and correctness becomes really important.&lt;/p&gt;

&lt;p&gt;Cost of mistake is not how many seconds your system was unavailable today. It’s about what was the price of your system's inaction or failure for your users and their users. We should take it with responsibility and always remember why we’re doing this, what is the real problem we’re solving.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fmgn3nsx2e9zdoc3a18ar.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fmgn3nsx2e9zdoc3a18ar.jpeg" alt="Trade-offs"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Every industry wants to make more progress by combining their and our research and solutions. Our work helps other fields and domains to better achieve their goals. And it can be immensely useful for us to understand how to relax certain limitations or fine-tune certain trade-offs.&lt;/p&gt;

&lt;p&gt;Understanding what’s at the core is a powerful tool to navigate the complexity of ever-changing options and tools, and it helps us to compose correct solutions to improve the options we have.&lt;/p&gt;

&lt;p&gt;Turns out it’s not so easy, there are some obstacles in our way!&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;There Is A Big Gap Between Theory And Practice&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;It’s challenging to understand what “correct” means for our systems. Most of the theoretical material is not approachable enough, it is notoriously hard to grasp. It often doesn’t include the information necessary to successfully bring this theory into practice. Production systems have to modify the theoretical algorithms and adjust them to work in real environments. Many of them don’t reveal the specific details important for practical solutions. And even a slight misunderstanding of the details of the protocol destroys its correctness. So we need to do additional work to guarantee that implementation is still correct.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fo5dbb0x775ibcbm2isry.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fo5dbb0x775ibcbm2isry.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Hard To Verify And Maintain Correctness&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;It’s challenging to verify and maintain correctness of distributed systems in real-world environments. It could sound perfect on the paper but could be inefficient or hard in practice. It can sound unrealistic in theory but be perfectly acceptable in practice. There are many things that can go wrong both in the algorithm logic and its implementation that are hard to detect.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Correctness Isn’t Always A Priority&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;On the other hand, correctness doesn't always happen to be a priority. There are deadlines, competition, and customers who need solutions faster. It can happen that the end-system will be rushed and not properly correct. This means a team might not have time to properly discuss and systematically address real reasons behind rare “intermittent” errors which will happen again lead to more errors in the future.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;How Can We Improve?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;We can improve in many directions. One of them is emphasizing and putting more focused efforts on improving correctness, to make sure we are able to build and maintain systems that keep doing exactly what we expect them to do.&lt;/p&gt;

&lt;p&gt;Another one is improving understanding of how they work as it helps us reduce the complexity and possible mistakes, and makes us more prepared to face the challenges that come up.&lt;/p&gt;

&lt;p&gt;When we aren’t implementing distributed algorithms and concepts directly, we definitely rely on systems that do. At the point where what we build intersects with other domains and fields, understanding fundamentals concepts and trade-offs becomes extremely relevant.&lt;/p&gt;

&lt;p&gt;If you are promised some performance and consistency, how do you actually make sure those guarantees are provided at the exact level you need?&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Simple Problems Become Hard&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;When several computers are talking to each other, trivial problems become hard problems, and they accumulate. Distributed systems are hard to understand, hard to implement, and it’s hard to keep them correct in practice.&lt;/p&gt;

&lt;p&gt;I think there are many ways to show why. Recently, I had a chance to explain it to someone from the field of bioinformatics, who was wondering why they needed to make trade-offs between important properties in a distributed setting.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Ordering&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The first thing that came to my mind was ordering events. Ordering is easy on a single machine, but when messages are sent across the network, it’s hard! We can’t rely on physical timestamps because physical clocks on different machines tend to drift. For ordering in distributed systems, we often apply logical clock, or simply speaking, counters that are passed around between nodes.&lt;/p&gt;

&lt;p&gt;Because of the asynchronous nature of distributed systems, we can’t easily establish compete order for all the events, because some of them are concurrent! What we can do is figure out which events are concurrent and which events happened before one another. And even with such a simple task, we already need to make some decisions.&lt;/p&gt;

&lt;p&gt;For example, would we be okay if the system told us that events are ordered, but in reality, they turned out to be concurrent?&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fy07tx43s7rdwsg2853a0.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fy07tx43s7rdwsg2853a0.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Or do we need to know for sure, that events really are not concurrent when we can order them?&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F7ljktcv5gb2yyhyzag0d.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F7ljktcv5gb2yyhyzag0d.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Agreement&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;We can’t simply order concurrent events, and sometimes, we still need to decide on the order of operations, on a value, a sequence of values, or anything else.&lt;/p&gt;

&lt;p&gt;Turns out that getting several machines to choose the same thing is another situation where we have to ask ourselves questions and determine what’s right for us.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fsbgnu9mmh0qezmimcg70.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fsbgnu9mmh0qezmimcg70.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;For example, Two-Phase Commit is one of the solutions where our nodes can all agree on something.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fd2lm0ojv3hotqo9148mf.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fd2lm0ojv3hotqo9148mf.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;It works, as long as our nodes don’t fail.&lt;/p&gt;

&lt;p&gt;If some of the nodes crash, to prevent any possibility of inconsistent data, the system just blocks until the crashed nodes come back, which might never happen or take a very, very long time.&lt;/p&gt;

&lt;p&gt;So the algorithm is safe but isn’t live.&lt;/p&gt;

&lt;p&gt;What if it’s not something we can accept and we really need a system to respond?&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F1oprcqp5qcd36wzcfubp.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F1oprcqp5qcd36wzcfubp.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;In this case, we might have another possible solution - three-phase commit. It doesn’t block when there are failures.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F9a8rxwxbvk4of3h0ruhm.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F9a8rxwxbvk4of3h0ruhm.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;But when there’s a network partition ...&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F7259eo15a29izjukf7p6.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F7259eo15a29izjukf7p6.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The two isolated sides of the network can come to two different decisions after they time out, and the system will end up in an inconsistent state.&lt;/p&gt;

&lt;p&gt;So here we have the opposite: the system is responsive and live, but it’s not safe because different nodes can decide on different values.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fk0q433gybhxesdldzaop.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fk0q433gybhxesdldzaop.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If we are okay with any of these two options, that’s great!&lt;/p&gt;

&lt;p&gt;What should we do if we want data to be always consistent and the system to be responsive?&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Impossibility Result&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The &lt;a href="https://groups.csail.mit.edu/tds/papers/Lynch/jacm85.pdf" rel="noopener noreferrer"&gt;impossibility result&lt;/a&gt; proved that actually, there isn’t a deterministic algorithm that will always terminate and come to a decision in a fully asynchronous environment, with even one possible failure.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.019.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.019.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The main thing we can learn from this result is: if we want to solve agreement in practice, we will have to rethink our assumptions to reflect more realistic expectations! For example, we can put an upper bound on maximum message delays, and determine what is an acceptable number of failures for our system.&lt;/p&gt;

&lt;p&gt;If we change our assumptions, we can solve distributed agreement in multiple ways!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.020.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.020.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Paxos&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The most famous solution is &lt;a href="https://lamport.azurewebsites.net/pubs/paxos-simple.pdf" rel="noopener noreferrer"&gt;Paxos&lt;/a&gt; algorithm, which is known for being hard to understand, and hard to implement correctly.&lt;/p&gt;

&lt;p&gt;It actually works, but it only under the condition, that majority of nodes have to be up, and the maximum message delay is bounded. &lt;/p&gt;

&lt;p&gt;In Paxos any node can propose a value, and after going through a “Prepare” and “Propose” phases, all of the nodes should agree on the same value.&lt;/p&gt;

&lt;p&gt;The majority of nodes need to be up, because if during each phase quorums intersect, there will always be at least one node that remembers what the most recent proposal is, which prevents agreeing on an old value.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.022.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.022.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;There are many optimizations to the initial algorithm that are applied in practice to make it more efficient. There are also many possible variations to consensus algorithms based on what trade-offs they chose.&lt;/p&gt;

&lt;p&gt;For example, how much work is done by the leader. Having a strong leader can be good or bad, depending on how frequently it fails and how hard it is to reelect. Another trade-off is how many node failures can we forgive and how big should the quorum be.&lt;/p&gt;

&lt;p&gt;Somewhat underrated criteria is how understandable and implementable the algorithm is in practice. Raft is popular because it was more understandable and is now applied in many widely used projects.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Still Discovering New Trade-Offs&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;But what’s even more interesting is that even though the topic of consensus and agreement isn’t new, we are still discovering many new optimizations and trade-offs.&lt;/p&gt;

&lt;p&gt;In classic Paxos, the majority needs to be up to make sure all the quorums will intersect. But it turns out we can rethink and simplify the majority quorum requirement. Turns out, it’s enough only for quorums of prepare and propose phases to intersect, which gives us much more flexibility to experiment with quorum sizes and performance in each phase!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.023.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.023.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The main point is, revealing new performance and availability trade-offs up to this day, helps us expand the spectrum of our choices in practice. Consensus is just a building block, but it can be used to solve many common problems, like atomic broadcast, distributed locks, strongly consistent replication, and many more!&lt;/p&gt;

&lt;p&gt;Please check out Dr. Heidi Howard's &lt;a href="https://www.cl.cam.ac.uk/techreports/UCAM-CL-TR-935.pdf" rel="noopener noreferrer"&gt;paper "Distributed Consensus Revised"&lt;/a&gt;. It's one of the very best papers on the topic.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Consistent Replication?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Replication is a massive part of any distributed system today.&lt;/p&gt;

&lt;p&gt;We can actually use consensus to implement strongly consistent replication, but one of the downsides of it is performance. Another side of the spectrum is of course, eventually consistent replication, which is very fast, but then clients can see inconsistent data. In practice, we often want better performance and still maintain stronger consistency, which can be tricky.&lt;/p&gt;

&lt;p&gt;So in some cases, we can come up with solutions that are faster than consensus, and are more consistent than eventual consistency.&lt;/p&gt;

&lt;p&gt;One of the interesting examples is Aurora, where they &lt;a href="https://dl.acm.org/citation.cfm?id=3183713.3196937" rel="noopener noreferrer"&gt;avoid consensus&lt;/a&gt; for I/O and a couple of other operations. They use quorums for writes, but don’t use them for reads. In reality, replicas might be storing different values, but when client performs a read, because the database maintains consistency points, it can look directly at nodes where data is known to be consistent, and return the correct data to the client.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.025.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.025.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Conflict-Free Replicated Data Types (CRDTs)&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Another interesting example is &lt;a href="https://en.wikipedia.org/wiki/Conflict-free_replicated_data_type" rel="noopener noreferrer"&gt;Conflict-Free Replicated Data Types&lt;/a&gt;. They can provide strong eventual consistency with both, fast reads and writes, and staying available even during network partitions, without using consensus or synchronization. However, it’s only possible if we can have rules for resolving any concurrent conflict.&lt;/p&gt;

&lt;p&gt;In other words, we can only use this technique if it’s possible to merge concurrent updates using some function that can apply them in any order, and as many times as we want, without corrupting the result.&lt;/p&gt;

&lt;p&gt;This is a perfectly acceptable example, where all the updates are additive, so they perfectly satisfy this requirement. &lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.027.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.027.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;This one, on the other hand, isn’t as obvious, as we don’t have clear rules for resolving conflicts with simultaneous updates of this kind.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.028.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.028.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://azure.microsoft.com/en-us/services/cosmos-db?WT.mc_id=keynote-blog-alehall" rel="noopener noreferrer"&gt;Azure Cosmos DB&lt;/a&gt; uses CRDTs for conflict resolution behind the scenes of concurrent multi-master multi-region writes. Redis and Riak also use CRDTs.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.029.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.029.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Failure Detection&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;If we teleport into another topic in distributed systems, we will always find more trade-offs.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/natadzen/failure-detectors-and-consensus-fsharp" rel="noopener noreferrer"&gt;Failure detectors&lt;/a&gt; is one of the essential techniques to discover node crashes in a distributed system. They can be applied in agreement problems, leader election, group membership protocols and in other areas.&lt;/p&gt;

&lt;p&gt;We can measure the efficiency of failure detectors by their “completeness” and "accuracy”. &lt;/p&gt;

&lt;p&gt;&lt;em&gt;Completeness&lt;/em&gt; shows whether some or all nodes in the system discover all the failures. &lt;em&gt;Accuracy&lt;/em&gt; measures the level of mistake a failure detector can make in suspecting the failure of another node.&lt;/p&gt;

&lt;p&gt;Turns out, even unreliable failure detectors can be extremely useful in practical systems because we can improve their completeness by adding a gossiping mechanism that spreads the knowledge about failures to all the nodes.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Why Does All Of This Matter?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Trade-offs may take different shapes and forms, and we can be really flexible if we know how to use them and where to look.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.032.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.032.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Many products are built around the algorithms and trade-offs. These products make certain choices for us, and we make choices by using certain products. Uneducated choices can result in delays and data loss. For some systems, this can lead to losing clients and large amounts of money. For other systems, it can result in slow reaction, or wrong order of actions, that poses an actual life threat. Understanding your trade-offs is very important for making the right choices, for knowing what correct means, and for verifying correctness of our systems in reality.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Verifying And Maintaining Correctness In Reality&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;After we are clear with our decisions and trade-offs, how do we maintain correctness in real systems?&lt;/p&gt;

&lt;p&gt;One of the frequently used options to verify distributed logic on safety and liveness, especially safety, is system model checking. Model checking is useful because it explores all possible states your system can end up in. There are quite a few tools out there. &lt;a href="https://lamport.azurewebsites.net/tla/tla.html" rel="noopener noreferrer"&gt;TLA+&lt;/a&gt; is pretty famous, there are more emerging techniques like &lt;a href="https://www.usenix.org/system/files/conference/osdi14/osdi14-paper-leesatapornwongsa.pdf" rel="noopener noreferrer"&gt;semantic aware model checking&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;To verify correctness of real, running implementations of distributed systems, model checking alone isn’t enough.&lt;/p&gt;

&lt;p&gt;Not many projects publish information on how they maintain correctness of their systems and verify it. But some of them do.&lt;/p&gt;

&lt;p&gt;For example, a &lt;a href="https://www.confluent.io/blog/apache-kafka-tested/" rel="noopener noreferrer"&gt;variety of system tests&lt;/a&gt; for Kafka is run every day and anyone in the world can &lt;a href="http://testing.confluent.io/confluent-kafka-system-test-results/" rel="noopener noreferrer"&gt;check and see&lt;/a&gt; what is working as expected and what isn’t.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.036.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.036.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Cassandra has a really great write up about &lt;a href="http://cassandra.apache.org/blog/2018/08/21/testing_apache_cassandra.html" rel="noopener noreferrer"&gt;their approach&lt;/a&gt; to &lt;a href="http://cassandra.apache.org/blog/2018/10/17/finding_bugs_with_property_based_testing.html" rel="noopener noreferrer"&gt;comprehensive testing&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.037.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.037.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I really wish more products, projects, and systems would be more open about efforts they put into testing and correctness verification.&lt;/p&gt;

&lt;p&gt;If we look at what it takes to be prepared to run a production-level distributed system, there’s quite a lot.&lt;/p&gt;

&lt;p&gt;Of course, for small scope scenarios and ensuring that multiple services work together well, unit tests and integration tests are essential. But not enough! There are more techniques we can use. Fuzz testing and property-based testing provide randomly-generated input to your systems to make sure that its fundamental properties are correct based on its specification. I actually worked on a fuzzing project at Microsoft Research and it’s a really fascinating topic in general. Performance tests are useful to collect data on latency and throughput of various components. Fault injection is helpful for checking that the system is available during fault scenarios and that expected system properties remain correct.&lt;/p&gt;

&lt;p&gt;With all of that, an insane amount of reasons behind the most critical errors is in exception handling logic.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.038.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.038.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;There are some things we can’t fully fix. We need to accept the fact that, in reality after all the tests and checks we’ve written, there will be mistakes anyway. We’re humans, there are context switches, and it’s impossible to know every single thing, there are too many moving parts. We’re never exploring new territory, we’d never make progress if we were afraid to leave the area we’re familiar with. However, we can definitely prepare ourselves better for dealing with unexpected errors, find patterns, and try to address what causes them. That’s why instrumenting your code matters and observability matters. It’s less scary when we’re aware of the possibility and have built the foundation for solving production errors.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Take Aways&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Products change fast, and terms that describe their consistency, resiliency, and performance are extremely overloaded. Fundamentals concepts and trade-offs stay and build-up. They aren’t useful in isolation, but knowing them can be essential for making the right choices and maintaining correctness in practice. Correctness is especially important when our systems are trusted in scenarios where a specific level of responsiveness and safety is a strong requirement.&lt;/p&gt;

&lt;p&gt;If you are building something, ask yourself a question: can this be misunderstood? Complexity is like a big bulletproof wall around your project, it makes it hard to explain, build, use, and improve. Try to make systems you build understandable to others because understanding contributes to correctness.&lt;/p&gt;

&lt;p&gt;Correctness isn’t easy and doesn’t come for free. You have to work on it and make it a priority. Not just at a level of one engineer willing to do it, but at the level of the entire organization. Don’t trust your system to just work: Test it, Verify it, and be ready when things fail. Show your users and customers what techniques and efforts you are putting into verifying your systems.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.040.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.040.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Think of areas related to your work that aren’t getting enough attention and are important. If you ever have an opportunity to chat with people different than you, who work in another area - do it, to learn more about what challenges they face in their work and what trade-offs they’re making. Ask questions. Share the same with them about your work. It will help you be a better engineer.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.041.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Flenadroid.github.io%2Fposts%2FOReillyVelocity%2Fimages%2FVelocity-Keynote-Lena-Hall.041.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
      <category>computerscience</category>
      <category>testing</category>
      <category>programming</category>
      <category>database</category>
    </item>
    <item>
      <title>Making Machine Learning Approachable</title>
      <dc:creator>Lena Hall</dc:creator>
      <pubDate>Wed, 03 Apr 2019 21:55:34 +0000</pubDate>
      <link>https://dev.to/lenadroid/making-machine-learning-approachable-7ap</link>
      <guid>https://dev.to/lenadroid/making-machine-learning-approachable-7ap</guid>
      <description>&lt;p&gt;&lt;em&gt;&lt;a href="http://ml4all.org/attend.html" rel="noopener noreferrer"&gt;Attend ML4ALL&lt;/a&gt; in Portland, OR April 28-30.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;The topic of Machine Learning advances and plays a bigger role in our development lives every day. It sounds exciting, and it's a universe of areas on its own. People can spend their entire lives studying some topic within machine learning, and there will be more and more to learn.&lt;/p&gt;

&lt;p&gt;There isn't a person who knows everything there is about machine learning, but there are people who know a lot about certain machine learning areas. For example, someone can be an expert in machine learning for recommendation systems or natural language processing but know nothing about deep learning for computer vision. Someone can be great at computer vision but don't know anything about natural language processing.&lt;/p&gt;

&lt;h2&gt;
  
  
  Is Machine Learning Really THAT Hard 🤔
&lt;/h2&gt;

&lt;p&gt;TL;DR: It can be, but doesn't &lt;em&gt;have to be&lt;/em&gt; THAT hard.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fh1q5bmom1cxyvlwclpc6.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fh1q5bmom1cxyvlwclpc6.jpg" alt="complexity"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Often we hear about machine learning and deep learning as a topic that only researchers, mathematicians, or PhDs can be smart enough grasp. When machine learning appears as the most complex area in computer science, it is most likely because of several common reasons:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Language used in many learning resources is cryptic.&lt;/li&gt;
&lt;li&gt;There aren't enough real-world examples of implementation of machine learning algorithms applied to business problems we can relate to.&lt;/li&gt;
&lt;li&gt;Explanation of fundamental concepts assumes knowledge of a certain amount of mathematics and notation and uses insufficiently explained formulas.&lt;/li&gt;
&lt;li&gt;Many learning resources are often hit or miss, as some of them are too difficult to understand, and others are hiding too many important underlying details.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Making Machine Learning Understandable ✨
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fpf6fltvcaghb1r1vbmlk.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fpf6fltvcaghb1r1vbmlk.jpeg" alt="understanding"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;It &lt;em&gt;is&lt;/em&gt; possible to explain seemingly complex fundamental concepts and algorithms of machine learning without using cryptic terminology or confusing notation. &lt;/p&gt;

&lt;p&gt;With this thought in mind, I and group of like-minded friends decided to organize a community conference about machine learning "for the rest of us", and call it 🎉&lt;a href="http://ml4all.org" rel="noopener noreferrer"&gt;ML4ALL&lt;/a&gt; 🎉. We set some goals for the conference:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Invite speakers that can articulate difficult concepts in an approachable, non-boring, intuitive ways&lt;/li&gt;
&lt;li&gt;Make sure the conference is extremely affordable and accessible to those who want everyone to get machine learning knowledge.&lt;/li&gt;
&lt;li&gt;Build community of friendly and curious people, passionate about machine learning and data science.&lt;/li&gt;
&lt;li&gt;Provide a platform for people to collaborate and exchange ideas through an unconference and encouraging discussions.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;We held the first ML4ALL conference in May 2018 and it was successful!&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;All of the talk recordings are &lt;a href="https://www.youtube.com/channel/UCfVG8K_0XyMh7r2162aDKJw/videos" rel="noopener noreferrer"&gt;available online&lt;/a&gt;. For example, Paige Bailey gave a great talk called &lt;a href="https://www.youtube.com/watch?v=n5ae9SejRh4" rel="noopener noreferrer"&gt;"Kill (Deep) Math"&lt;/a&gt;:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F5cqa6pn6k3z4c1busjk2.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F5cqa6pn6k3z4c1busjk2.png" alt="Paige's talk"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  ML4ALL Is Back!
&lt;/h2&gt;

&lt;p&gt;Turns out, the audience &lt;a href="https://www.youtube.com/watch?v=m3EK-C1WylM" rel="noopener noreferrer"&gt;loved&lt;/a&gt; ML4ALL more than we could ever expect, and we immediately knew that we are on the right path. This is why ML4ALL is back to Portland this year on &lt;strong&gt;April 28 - 30&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Come and be weird with us at ML4ALL this year!&lt;/strong&gt;&lt;br&gt;
&lt;em&gt;If you are coming from Seattle, you can join us on a Machine Learning &lt;em&gt;Train&lt;/em&gt; to Portland.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;🎟🎟🎟&lt;strong&gt;Tickets&lt;/strong&gt;: &lt;a href="http://ml4all.org/attend.html" rel="noopener noreferrer"&gt;Buy here&lt;/a&gt; (extremely affordable - $150-$375).&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fb2ed5hzvwn9z5jfp62wf.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Fb2ed5hzvwn9z5jfp62wf.jpg" alt="ML4ALL"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;We have already announced our first speakers with a wide range of topics, including:&lt;/p&gt;

&lt;p&gt;✓ Connected Feature Extraction&lt;br&gt;
✓ Classifier to Listen to Killer Whales&lt;br&gt;
✓ Machine Learning Ops&lt;br&gt;
✓ Quantum Machine Learning&lt;br&gt;
✓ Feature Engineering&lt;br&gt;
✓ Privacy in Machine Learning&lt;br&gt;
✓ Churn Prediction&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Frh5god4u6r0jgb2itsu3.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2Frh5god4u6r0jgb2itsu3.png" alt="speakers"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;With many more topics and speakers announced soon.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;The conference is organized 100% by the community: Lena Hall, Troy Howard, Adron Hall, Byron Gerlach, Glenn Block, and Ben Acker (Ben created the ML4ALL art-character ❤️).&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Follow us on Twitter &lt;a href="https://twitter.com/ml4all" rel="noopener noreferrer"&gt;@ml4all&lt;/a&gt; and spread the word!&lt;/p&gt;

&lt;p&gt;❓&lt;em&gt;What are the topics you'd like to see explained better&lt;/em&gt; ❓&lt;/p&gt;

</description>
      <category>learning</category>
      <category>programming</category>
      <category>explainlikeimfive</category>
      <category>machinelearning</category>
    </item>
  </channel>
</rss>
