8

General Availability of the Dapr Extension

 1 year ago
source link: https://techcommunity.microsoft.com/t5/azure-arc-blog/general-availability-of-the-dapr-extension/ba-p/3428938?WT_mc_id=DOP-MVP-4025064
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

General Availability of the Dapr Extension

Published Jun 07 2022 08:00 AM 390 Views

We are excited to announce General Availability of the Dapr extension for Arc-enabled Kubernetes clusters alongside AKS.

Distributed Application Runtime (Dapr) is a set of incrementally adoptable APIs that ease the implementation of common cloud-native patterns found in microservice applications. By leveraging the benefits of a sidecar architecture, Dapr helps developers tackle the challenges of building microservices while keeping code platform-agnostic. Dapr APIs, also referred to as building blocks: 

  • Seamlessly fit with your preferred language or framework 
  • Allow you to use one, several, or all the building blocks, depending on your needs 
  • Are built on best practice industry standards

For example, you can enable Dapr on your application to provide intercommunication through messaging via the Pub/Sub API, or reliable and secure service-to-service calls via the Service Invocation API. The below image depicts the various Dapr building blocks your microservices can leverage.

thumbnail image 1 of blog post titled                                              General Availability of the Dapr Extension

The Dapr extension provisions Dapr on your Arc-enabled Kubernetes clusters, eliminating the overhead of downloading any Dapr tooling or manually installing and managing the Dapr runtime on your cluster.

After writing Dapr into your application (in this example, using the Dapr .NET SDK to publish a message to a topic):

using var client = new DaprClientBuilder().Build();

await client.PublishEventAsync("order_pub_sub", "orders", order);

You can use the az k8s-extension CLI to install the Dapr control plane on your Arc-enabled Kubernetes clusters. The same Azure CLI commands are used to managed Dapr on AKS clusters. For AKS, swamp out the --cluster-type value of connectedClusters with managedClusters. Use the following command in the Azure CLI:

az k8s-extension create --extension-type Microsoft.Dapr \ 
--cluster-type connectedClusters \ 
--cluster-name myCluster \ 
--resource-group myResourceGroup \
--name myDaprExtension

The extension offers a fully supported version of Dapr and integrates with all native Dapr configuration capabilities through simple command-line arguments. For example, to provision Dapr with high availability (HA) enabled, set the global.ha.enabled parameter to ‘true’:

--configuration-settings "global.ha.enabled=true"

The extension platform provides the ability to set auto-upgrades for the Dapr control plane, making it easy for you to align to the latest minor version of Dapr. Specify the --auto-upgrade-minor-version parameter and setting the value to 'true':

--auto-upgrade-minor-version true

Once the extension is installed, the Dapr control plane is created on your Arc-enabled Kubernetes cluster. Your application code, instrumented with Dapr, can immediately begin leveraging the Dapr APIs.

Try the Dapr extension sample on your Arc-enabled Kubernetes cluster. For more information, refer to the Dapr cluster extension documentation.

You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.

%3CLINGO-SUB%20id%3D%22lingo-sub-3428938%22%20slang%3D%22en-US%22%3EGeneral%20Availability%20of%20the%20Dapr%20Extension%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-3428938%22%20slang%3D%22en-US%22%3E%3CP%3EWe%20are%20excited%20to%20announce%20General%20Availability%20of%20the%20Dapr%20extension%20for%20Arc-enabled%20Kubernetes%20clusters%20alongside%20%3CA%20href%3D%22https%3A%2F%2Faka.ms%2FAKSExtensionsGA%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3EAKS%3C%2FA%3E.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EDistributed%20Application%20Runtime%20(%3CA%20href%3D%22https%3A%2F%2Fdapr.io%2F%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3EDapr%3C%2FA%3E)%20is%20a%20set%20of%20incrementally%20adoptable%20APIs%20that%20ease%20the%20implementation%20of%20common%20cloud-native%20patterns%20found%20in%20microservice%20applications.%20By%20leveraging%20the%20benefits%20of%20a%20sidecar%20architecture%2C%20Dapr%20helps%20developers%20tackle%20the%20challenges%20of%20building%20microservices%20while%20keeping%20code%20platform-agnostic.%20Dapr%20APIs%2C%20also%20referred%20to%20as%20building%20blocks%3A%26nbsp%3B%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3ESeamlessly%20fit%20with%20your%20preferred%20language%20or%20framework%26nbsp%3B%3C%2FLI%3E%0A%3CLI%3EAllow%20you%20to%20use%20one%2C%20several%2C%20or%20all%20the%20building%20blocks%2C%20depending%20on%20your%20needs%26nbsp%3B%3C%2FLI%3E%0A%3CLI%3EAre%20built%20on%20best%20practice%20industry%20standards%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CP%3EFor%20example%2C%20you%20can%20enable%20Dapr%20on%20your%20application%20to%20provide%20intercommunication%20through%20messaging%20via%20the%20Pub%2FSub%20API%2C%20or%20reliable%20and%20secure%20service-to-service%20calls%20via%20the%20Service%20Invocation%20API.%26nbsp%3BThe%20below%20image%20depicts%20the%20various%20Dapr%20building%20blocks%20your%20microservices%20can%20leverage.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22greeniemsft_0-1653517660576.png%22%20style%3D%22width%3A%201000px%3B%22%3E%3Cspan%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22greeniemsft_0-1653517660576.png%22%20style%3D%22width%3A%201000px%3B%22%3E%3Cimg%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F375296i1FA07F4AA118EC33%2Fimage-dimensions%2F1000x380%3Fv%3Dv2%22%20width%3D%221000%22%20height%3D%22380%22%20role%3D%22button%22%20title%3D%22greeniemsft_0-1653517660576.png%22%20alt%3D%22greeniemsft_0-1653517660576.png%22%20%2F%3E%3C%2Fspan%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EThe%20Dapr%20extension%20provisions%20Dapr%20on%20your%20Arc-enabled%20Kubernetes%20clusters%2C%20eliminating%20the%20overhead%20of%20downloading%20any%20Dapr%20tooling%20or%20manually%20installing%20and%20managing%20the%20Dapr%20runtime%20on%20your%20cluster.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EAfter%20writing%20Dapr%20into%20your%20application%20(in%20this%20example%2C%20using%20the%20Dapr%20.NET%20SDK%20to%20publish%20a%20message%20to%20a%20topic)%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CPRE%20class%3D%22lia-code-sample%20language-csharp%22%3E%3CCODE%3Eusing%20var%20client%20%3D%20new%20DaprClientBuilder().Build()%3B%0A%0Aawait%20client.PublishEventAsync(%22order_pub_sub%22%2C%20%22orders%22%2C%20order)%3B%0A%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EYou%20can%20use%20the%20az%20k8s-extension%20CLI%20to%20install%20the%20Dapr%20control%20plane%20on%20your%20Arc-enabled%20Kubernetes%20clusters.%20The%20same%20Azure%20CLI%20commands%20are%20used%20to%20managed%20Dapr%20on%20AKS%20clusters.%20For%20AKS%2C%20swamp%20out%20the%20--cluster-type%20value%20of%20connectedClusters%20with%20managedClusters.%26nbsp%3BUse%20the%20following%20command%20in%20the%20Azure%20CLI%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CPRE%20class%3D%22lia-code-sample%20language-applescript%22%3E%3CCODE%3Eaz%E2%80%AFk8s-extension%20create%E2%80%AF--extension-type%E2%80%AFMicrosoft.Dapr%E2%80%AF%5C%E2%80%AF%0A--cluster-type%E2%80%AFconnectedClusters%E2%80%AF%5C%E2%80%AF%0A--cluster-name%E2%80%AFmyCluster%E2%80%AF%5C%E2%80%AF%0A--resource-group%E2%80%AFmyResourceGroup%20%5C%0A--name%E2%80%AFmyDaprExtension%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EThe%20extension%20offers%20a%20fully%20supported%20version%20of%20Dapr%20and%20integrates%26nbsp%3Bwith%26nbsp%3Ball%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2Fdapr%2Fdapr%2Fblob%2Fmaster%2Fcharts%2Fdapr%2FREADME.md%23configuration%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Enative%20Dapr%20configuration%20capabilities%3C%2FA%3E%26nbsp%3Bthrough%20simple%20command-line%20arguments.%20For%20example%2C%20to%20provision%20Dapr%20with%20high%20availability%20(HA)%20enabled%2C%20set%20the%26nbsp%3Bglobal.ha.enabled%26nbsp%3Bparameter%20to%26nbsp%3B%E2%80%98true%E2%80%99%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CPRE%20class%3D%22lia-code-sample%20language-applescript%22%3E%3CCODE%3E--configuration-settings%20%22global.ha.enabled%3Dtrue%22%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EThe%20extension%20platform%20provides%20the%20ability%20to%20set%20auto-upgrades%20for%20the%20Dapr%20control%20plane%2C%20making%20it%20easy%20for%20you%20to%20align%20to%20the%20latest%20minor%20version%20of%20Dapr.%20Specify%20the%26nbsp%3B--auto-upgrade-minor-version%20parameter%20and%20setting%20the%20value%20to%26nbsp%3B'true'%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CPRE%20class%3D%22lia-code-sample%20language-applescript%22%3E%3CCODE%3E--auto-upgrade-minor-version%20true%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EOnce%20the%20extension%20is%20installed%2C%20the%20Dapr%20control%20plane%20is%20created%20on%20your%20Arc-enabled%20Kubernetes%20cluster.%20Your%20application%20code%2C%20instrumented%20with%20Dapr%2C%20can%20immediately%20begin%20leveraging%20the%20Dapr%20APIs.%3CBR%20%2F%3E%3CBR%20%2F%3ETry%20the%20%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Faks%2Fquickstart-dapr%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3EDapr%20extension%20sample%3C%2FA%3E%20on%20your%20Arc-enabled%20Kubernetes%20cluster.%20For%20more%20information%2C%20refer%20to%20the%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Faks%2Fdapr%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3EDapr%26nbsp%3Bcluster%26nbsp%3Bextension%26nbsp%3Bdocumentation%3C%2FA%3E.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-3428938%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EAzure%20Arc%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EKubernetes%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EMicrosoft%20Build%202022%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E

Version history
Last update:

‎Jun 05 2022 09:42 AM

Updated by:

Share


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK