Hyder Ahmed
Hyder Ahmed

Reputation: 149

What are the advantages of using a Service Fabric stateless service over a Cloud Service Worker Role?

I am trying to understand the advantages of using Service Fabric over a cloud service worker role.

Currently, I am using a cloud service for hosting (web role and worker role).

Will there be any advantage if I change the cloud service to an App Service Web app for hosting the web role and a Service Fabric stateless service for hosting the worker role? If so, what are the advantages?

Upvotes: 2

Views: 813

Answers (2)

Joey Cai
Joey Cai

Reputation: 20127

As @PRADEEP CHEEKATLA said,Service Fabric itself is an application platform layer that runs on Windows or Linux, whereas Cloud Services is a system for deploying Azure-managed VMs with workloads attached.

In Cloud Services, a Worker Role VM hosts one workload. In Service Fabric, applications are separate from the VMs that run them, meaning you can deploy a large number of applications to a small number of VMs, which can lower overall cost for larger deployments.

And the key difference between Service Fabric and Cloud Services is that in Cloud Services you connect to a VM, whereas in Service Fabric you connect to a service.

This is an important distinction for a couple reasons:

1.Services in Service Fabric are not bound to the VMs that host them; services may move around in the cluster, and in fact, are expected to move around for various reasons: Resource balancing, failover, application and infrastructure upgrades, and placement or load constraints. This means a service instance's address can change at any time.

2.A VM in Service Fabric can host multiple services, each with unique endpoints.

Here is a comparing Cloud Services with Service Fabricenter image description here

Also, you could refer to this article to converting Web and Worker Roles to Service Fabric stateless services.

Upvotes: 1

CHEEKATLAPRADEEP
CHEEKATLAPRADEEP

Reputation: 12788

Service Fabric itself is an application platform layer that runs on Windows or Linux, whereas Cloud Services is a system for deploying Azure-managed VMs with workloads attached. The Service Fabric application model has a number of advantages:

  • Fast deployment times. Creating VM instances can be time consuming. In Service Fabric, VMs are only deployed once to form a cluster that hosts the Service Fabric application platform. From that point on, application packages can be deployed to the cluster very quickly.
  • High-density hosting. In Cloud Services, a Worker Role VM hosts one workload. In Service Fabric, applications are separate from the VMs that run them, meaning you can deploy a large number of applications to a small number of VMs, which can lower overall cost for larger deployments.
  • The Service Fabric platform can run anywhere that has Windows Server or Linux machines, whether it's Azure or on-premises. The platform provides an abstraction layer over the underlying infrastructure so your application can run on different environments.
  • Distributed application management. Service Fabric is a platform that not only hosts distributed applications, but also helps manage their lifecycle independently of the hosting VM or machine lifecycle.

For more details, refer "Learn about the differences between Cloud Services and Service Fabric before migrating applications".

This article helps you understand the options and make the right choice for your web application.

Upvotes: 2

Related Questions