public sealed class ClientCreationSettingsSettings for creating PublisherServiceApiClients.
Namespace
Google.Cloud.PubSub.V1Assembly
Google.Cloud.PubSub.V1.dll
Constructors
ClientCreationSettings(Nullable<Int32>, PublisherServiceApiSettings, ChannelCredentials, String)
public ClientCreationSettings(int? clientCount = default(int? ), PublisherServiceApiSettings publisherServiceApiSettings = null, ChannelCredentials credentials = null, string serviceEndpoint = null)Instantiate with the specified settings.
| Parameters | |
|---|---|
| Name | Description |
clientCount |
Nullable<Int32>Optional. The number of PublisherServiceApiClients to create and use within a PublisherClient instance. |
publisherServiceApiSettings |
PublisherServiceApiSettingsOptional. The settings to use when creating PublisherServiceApiClient instances. |
credentials |
ChannelCredentialsOptional. Credentials to use when creating PublisherServiceApiClient instances. |
serviceEndpoint |
StringOptional. The endpoint to use when creating PublisherServiceApiClient instances. |
Properties
ClientCount
public int? ClientCount { get; }The number of PublisherServiceApiClients to create and use within a PublisherClient instance.
If null, defaults to the CPU count on the machine this is being executed on.
| Property Value | |
|---|---|
| Type | Description |
Nullable<Int32> |
|
Credentials
public ChannelCredentials Credentials { get; }Credentials to use when creating PublisherServiceApiClient instances.
If null, defaults to using the default credentials.
| Property Value | |
|---|---|
| Type | Description |
ChannelCredentials |
|
EmulatorDetection
public EmulatorDetection EmulatorDetection { get; }Specifies how to respond to the presence of emulator environment variables.
| Property Value | |
|---|---|
| Type | Description |
EmulatorDetection |
|
This property defaults to None, meaning that environment variables are ignored.
PublisherServiceApiSettings
public PublisherServiceApiSettings PublisherServiceApiSettings { get; }The settings to use when creating PublisherServiceApiClient instances.
If null, defaults to GetDefault().
| Property Value | |
|---|---|
| Type | Description |
PublisherServiceApiSettings |
|
ServiceEndpoint
public string ServiceEndpoint { get; }The endpoint to use when creating PublisherServiceApiClient instances.
If null, defaults to DefaultEndpoint.
| Property Value | |
|---|---|
| Type | Description |
String |
|
Methods
WithEmulatorDetection(EmulatorDetection)
public PublisherClient.ClientCreationSettings WithEmulatorDetection(EmulatorDetection emulatorDetection)Creates a new instance of this type with the specified emulator detection value.
| Parameter | |
|---|---|
| Name | Description |
emulatorDetection |
EmulatorDetectionDetermines how and whether to detect the emulator. |
| Returns | |
|---|---|
| Type | Description |
PublisherClient.ClientCreationSettings |
The new instance |