# Cloud Run Admin v2 API - Class ServiceScaling (2.19.0)

<button class="button button-with-icon cloud-select-dropdown__button " aria-haspopup="true">Version latest</button>

- [2.19.0 (latest)](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/latest/Google.Cloud.Run.V2.ServiceScaling)
- [2.18.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/2.18.0/Google.Cloud.Run.V2.ServiceScaling)
- [2.17.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/2.17.0/Google.Cloud.Run.V2.ServiceScaling)
- [2.16.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/2.16.0/Google.Cloud.Run.V2.ServiceScaling)
- [2.15.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/2.15.0/Google.Cloud.Run.V2.ServiceScaling)
- [2.14.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/2.14.0/Google.Cloud.Run.V2.ServiceScaling)
- [2.13.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/2.13.0/Google.Cloud.Run.V2.ServiceScaling)
- [2.12.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/2.12.0/Google.Cloud.Run.V2.ServiceScaling)
- [2.11.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/2.11.0/Google.Cloud.Run.V2.ServiceScaling)
- [2.10.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/2.10.0/Google.Cloud.Run.V2.ServiceScaling)
- [2.9.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/2.9.0/Google.Cloud.Run.V2.ServiceScaling)
- [2.8.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/2.8.0/Google.Cloud.Run.V2.ServiceScaling)
- [2.7.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/2.7.0/Google.Cloud.Run.V2.ServiceScaling)
- [2.6.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/2.6.0/Google.Cloud.Run.V2.ServiceScaling)
- [2.5.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/2.5.0/Google.Cloud.Run.V2.ServiceScaling)
- [2.4.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/2.4.0/Google.Cloud.Run.V2.ServiceScaling)
- [2.3.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/2.3.0/Google.Cloud.Run.V2.ServiceScaling)
- [2.2.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/2.2.0/Google.Cloud.Run.V2.ServiceScaling)
- [2.1.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/2.1.0/Google.Cloud.Run.V2.ServiceScaling)
- [2.0.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/2.0.0/Google.Cloud.Run.V2.ServiceScaling)
- [1.0.0-beta02](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/1.0.0-beta02/Google.Cloud.Run.V2.ServiceScaling)

    public sealed class ServiceScaling : IMessage<ServiceScaling>, IEquatable<ServiceScaling>, IDeepCloneable<ServiceScaling>, IBufferMessage, IMessage

Reference documentation and code samples for the Cloud Run Admin v2 API class ServiceScaling.

Scaling settings applied at the service level rather than
at the revision level.

## Inheritance

[object](https://learn.microsoft.com/dotnet/api/system.object) \> ServiceScaling

## Implements

[IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage-1.html)[ServiceScaling](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/latest/Google.Cloud.Run.V2.ServiceScaling), [IEquatable](https://learn.microsoft.com/dotnet/api/system.iequatable-1)[ServiceScaling](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/latest/Google.Cloud.Run.V2.ServiceScaling), [IDeepCloneable](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IDeepCloneable-1.html)[ServiceScaling](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/latest/Google.Cloud.Run.V2.ServiceScaling), [IBufferMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IBufferMessage.html), [IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage.html)

## Inherited Members

[object.GetHashCode()](https://learn.microsoft.com/dotnet/api/system.object.gethashcode) [object.GetType()](https://learn.microsoft.com/dotnet/api/system.object.gettype) [object.ToString()](https://learn.microsoft.com/dotnet/api/system.object.tostring)

## Namespace

[Google.Cloud.Run.V2](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/latest/Google.Cloud.Run.V2)

## Assembly

Google.Cloud.Run.V2.dll

## Constructors

### ServiceScaling()

    public ServiceScaling()

### ServiceScaling(ServiceScaling)

    public ServiceScaling(ServiceScaling other)

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `other` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/latest/Google.Cloud.Run.V2.ServiceScaling` |

## Properties

### HasManualInstanceCount

    public bool HasManualInstanceCount { get; }

Gets whether the "manual_instance_count" field is set

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |

### ManualInstanceCount

    public int ManualInstanceCount { get; set; }

Optional. total instance count for the service in manual scaling mode. This
number of instances is divided among all revisions with specified traffic
based on the percent of traffic they are receiving.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.int32` |   |

### MaxInstanceCount

    public int MaxInstanceCount { get; set; }

Optional. total max instances for the service. This number of instances is
divided among all revisions with specified traffic based on the percent
of traffic they are receiving.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.int32` |   |

### MinInstanceCount

    public int MinInstanceCount { get; set; }

Optional. total min instances for the service. This number of instances is
divided among all revisions with specified traffic based on the percent
of traffic they are receiving.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.int32` |   |

### ScalingMode

    public ServiceScaling.Types.ScalingMode ScalingMode { get; set; }

Optional. The scaling mode for the service.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/latest/Google.Cloud.Run.V2.ServiceScalinghttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/latest/Google.Cloud.Run.V2.ServiceScaling.Typeshttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Run.V2/latest/Google.Cloud.Run.V2.ServiceScaling.Types.ScalingMode` |   |