Search code examples
powershellscaleazure-service-fabric

Service fabric increase stateless service instance without re-deployment


Is there a way to increase number of instance for stateless service on Service Fabric please? We can update the application manifest to increase the number however that will require a deployment. Is there a way to do that via Service Fabric Explorer or Powershell please?

Thank you very much Best regards


Solution

  • Yes using the Update-ServiceFabricService cmdlet

    Update-ServiceFabricService
      [-Stateless]
      [-ServiceName] <Uri>
      [-Correlation <String[]>]
      [-DefaultMoveCost <String>]
      [-Force]
      [-InstanceCount <Int32>]
      [-Metric <String[]>]
      [-PlacementConstraints <String>]
      [-PlacementPolicy <String[]>]
      [-TimeoutSec <Int32>]
      [-Confirm]
      [-WhatIf]
      [<CommonParameters>]
    

    https://learn.microsoft.com/en-us/powershell/module/servicefabric/update-servicefabricservice?view=azureservicefabricps