Rotem Varon
Rotem Varon

Reputation: 1647

Azure Service Fabric - Improve Local Performance

When I deploy or exercise the cluster locally, I am facing drastic recourse degradation on my local machine.

I wonder if you can recommend a way to mitigate that negative impact (SW & HW)?

Additional info:

It is important to understand that the Service Fabric local cluster is not an emulator or simulator. It runs the same platform code that is found on multi-machine clusters. The only difference is that it runs the platform processes that are normally spread across five machines on one machine.

https://azure.microsoft.com/en-us/documentation/articles/service-fabric-get-started-with-a-local-cluster/

One though I had was to add one more SSD, so the OS and Service Fabric will not compete on the bus resource. After adding that SSD and using PowerShell to move the cluster to the new drive (the one without the OS) I can see negligible effect. Looking at the performance monitor, it seems that most of the IO still going to the main (OS) drive. Any thoughts?

I have a standard dev machine with the following specs:

This question might be a good fit for the HW forum as well

Upvotes: 3

Views: 519

Answers (1)

Eli Arbel
Eli Arbel

Reputation: 22739

The Service Fabric SDK creates a 5 node cluster on your dev machine, which means that each system service has 5 instances (processes). You could decrease the amount of nodes to 3 (the minimum).

To do that, you'll have to manually edit the cluster manifest and recreate it. The manifest is located at

%ProgramFiles%\Microsoft SDKs\Service Fabric\ClusterSetup\NonSecure\ClusterManifestTemplate.xml

  • Delete NodeType3 and NodeType4
  • Delete _Node_3 and _Node_4
  • Change: ExpectedClusterSize to 2, TargetReplicaSetSize to 3 and MinReplicaSetSize to 2 (appears multiple times; you could try lower values here, I haven't had the chance to test it)

Note: You will need to apply these changes every time you update the SDK.

After saving the file, recreate the local cluster (e.g. using the cluster manager tray app).

In addition, you should make sure that when you deploy your applications, they too have the defaults for local deployment (i.e. instance and partition counts set to 1). These usually appears in the Local.xml parameters file.

One last thing you could try is configuring your service EXEs to build as a "Windows Application" rather than a "Console Application" (in each service's project properties), which would reduce the amount of conhost.exe processes.

Upvotes: 4

Related Questions