Sdílet prostřednictvím


EventHubBufferedProducerClient Constructors

Definition

Overloads

EventHubBufferedProducerClient()

Used for mocking the producer for testing purposes.

EventHubBufferedProducerClient(String)

Initializes a new instance of the EventHubBufferedProducerClient class.

EventHubBufferedProducerClient(EventHubConnection, EventHubBufferedProducerClientOptions)

Initializes a new instance of the EventHubBufferedProducerClient class.

EventHubBufferedProducerClient(String, EventHubBufferedProducerClientOptions)

Initializes a new instance of the EventHubBufferedProducerClient class.

EventHubBufferedProducerClient(String, String)

Initializes a new instance of the EventHubBufferedProducerClient class.

EventHubBufferedProducerClient(String, String, EventHubBufferedProducerClientOptions)

Initializes a new instance of the EventHubBufferedProducerClient class.

EventHubBufferedProducerClient(String, String, AzureNamedKeyCredential, EventHubBufferedProducerClientOptions)

Initializes a new instance of the EventHubBufferedProducerClient class.

EventHubBufferedProducerClient(String, String, AzureSasCredential, EventHubBufferedProducerClientOptions)

Initializes a new instance of the EventHubBufferedProducerClient class.

EventHubBufferedProducerClient(String, String, TokenCredential, EventHubBufferedProducerClientOptions)

Initializes a new instance of the EventHubBufferedProducerClient class.

EventHubBufferedProducerClient()

Source:
EventHubBufferedProducerClient.cs
Source:
EventHubBufferedProducerClient.cs

Used for mocking the producer for testing purposes.

protected EventHubBufferedProducerClient ();
Protected Sub New ()

Applies to

EventHubBufferedProducerClient(String)

Source:
EventHubBufferedProducerClient.cs
Source:
EventHubBufferedProducerClient.cs

Initializes a new instance of the EventHubBufferedProducerClient class.

public EventHubBufferedProducerClient (string connectionString);
new Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClient : string -> Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClient
Public Sub New (connectionString As String)

Parameters

connectionString
String

The connection string to use for connecting to the Event Hubs namespace; it is expected that the Event Hub name and the shared key properties are contained in this connection string.

Remarks

If the connection string is copied from the Event Hubs namespace, it will likely not contain the name of the desired Event Hub, which is needed. In this case, the name can be added manually by adding ";EntityPath=[[ EVENT HUB NAME ]]" to the end of the connection string. For example, ";EntityPath=telemetry-hub".

If you have defined a shared access policy directly on the Event Hub itself, then copying the connection string from that Event Hub will result in a connection string that contains the name.

Applies to

EventHubBufferedProducerClient(EventHubConnection, EventHubBufferedProducerClientOptions)

Source:
EventHubBufferedProducerClient.cs
Source:
EventHubBufferedProducerClient.cs

Initializes a new instance of the EventHubBufferedProducerClient class.

public EventHubBufferedProducerClient (Azure.Messaging.EventHubs.EventHubConnection connection, Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClientOptions clientOptions = default);
new Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClient : Azure.Messaging.EventHubs.EventHubConnection * Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClientOptions -> Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClient
Public Sub New (connection As EventHubConnection, Optional clientOptions As EventHubBufferedProducerClientOptions = Nothing)

Parameters

connection
EventHubConnection

The EventHubConnection connection to use for communication with the Event Hubs service.

clientOptions
EventHubBufferedProducerClientOptions

A set of EventHubBufferedProducerClientOptions to apply when configuring the producer.

Applies to

EventHubBufferedProducerClient(String, EventHubBufferedProducerClientOptions)

Source:
EventHubBufferedProducerClient.cs
Source:
EventHubBufferedProducerClient.cs

Initializes a new instance of the EventHubBufferedProducerClient class.

public EventHubBufferedProducerClient (string connectionString, Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClientOptions clientOptions);
new Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClient : string * Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClientOptions -> Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClient
Public Sub New (connectionString As String, clientOptions As EventHubBufferedProducerClientOptions)

Parameters

connectionString
String

The connection string to use for connecting to the Event Hubs namespace; it is expected that the Event Hub name and the shared key properties are contained in this connection string.

clientOptions
EventHubBufferedProducerClientOptions

A set of EventHubBufferedProducerClientOptions to apply when configuring the buffered producer.

Remarks

If the connection string is copied from the Event Hubs namespace, it will likely not contain the name of the desired Event Hub, which is needed. In this case, the name can be added manually by adding ";EntityPath=[[ EVENT HUB NAME ]]" to the end of the connection string. For example, ";EntityPath=telemetry-hub".

If you have defined a shared access policy directly on the Event Hub itself, then copying the connection string from that Event Hub will result in a connection string that contains the name.

Applies to

EventHubBufferedProducerClient(String, String)

Source:
EventHubBufferedProducerClient.cs
Source:
EventHubBufferedProducerClient.cs

Initializes a new instance of the EventHubBufferedProducerClient class.

public EventHubBufferedProducerClient (string connectionString, string eventHubName);
new Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClient : string * string -> Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClient
Public Sub New (connectionString As String, eventHubName As String)

Parameters

connectionString
String

The connection string to use for connecting to the Event Hubs namespace; it is expected that the Event Hub name and the shared key properties are contained in this connection string.

eventHubName
String

The name of the specific Event Hub to associate the producer with.

Remarks

If the connection string is copied from the Event Hub itself, it will contain the name of the desired Event Hub, and can be used directly without passing the eventHubName. The name of the Event Hub should be passed only once, either as part of the connection string or separately.

Applies to

EventHubBufferedProducerClient(String, String, EventHubBufferedProducerClientOptions)

Source:
EventHubBufferedProducerClient.cs
Source:
EventHubBufferedProducerClient.cs

Initializes a new instance of the EventHubBufferedProducerClient class.

public EventHubBufferedProducerClient (string connectionString, string eventHubName, Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClientOptions clientOptions);
new Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClient : string * string * Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClientOptions -> Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClient
Public Sub New (connectionString As String, eventHubName As String, clientOptions As EventHubBufferedProducerClientOptions)

Parameters

connectionString
String

The connection string to use for connecting to the Event Hubs namespace; it is expected that the Event Hub name and the shared key properties are contained in this connection string.

eventHubName
String

The name of the specific Event Hub to associate the producer with.

clientOptions
EventHubBufferedProducerClientOptions

A set of EventHubBufferedProducerClientOptions to apply when configuring the buffered producer.

Remarks

If the connection string is copied from the Event Hub itself, it will contain the name of the desired Event Hub, and can be used directly without passing the eventHubName. The name of the Event Hub should be passed only once, either as part of the connection string or separately.

Applies to

EventHubBufferedProducerClient(String, String, AzureNamedKeyCredential, EventHubBufferedProducerClientOptions)

Source:
EventHubBufferedProducerClient.cs
Source:
EventHubBufferedProducerClient.cs

Initializes a new instance of the EventHubBufferedProducerClient class.

public EventHubBufferedProducerClient (string fullyQualifiedNamespace, string eventHubName, Azure.AzureNamedKeyCredential credential, Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClientOptions clientOptions = default);
new Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClient : string * string * Azure.AzureNamedKeyCredential * Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClientOptions -> Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClient
Public Sub New (fullyQualifiedNamespace As String, eventHubName As String, credential As AzureNamedKeyCredential, Optional clientOptions As EventHubBufferedProducerClientOptions = Nothing)

Parameters

fullyQualifiedNamespace
String

The fully qualified Event Hubs namespace to connect to. This is likely to be similar to {yournamespace}.servicebus.windows.net.

eventHubName
String

The name of the specific Event Hub to associate the producer with.

credential
AzureNamedKeyCredential

The shared access key credential to use for authorization. Access controls may be specified by the Event Hubs namespace or the requested Event Hub, depending on Azure configuration.

clientOptions
EventHubBufferedProducerClientOptions

A set of EventHubBufferedProducerClientOptions to apply when configuring the producer.

Applies to

EventHubBufferedProducerClient(String, String, AzureSasCredential, EventHubBufferedProducerClientOptions)

Source:
EventHubBufferedProducerClient.cs
Source:
EventHubBufferedProducerClient.cs

Initializes a new instance of the EventHubBufferedProducerClient class.

public EventHubBufferedProducerClient (string fullyQualifiedNamespace, string eventHubName, Azure.AzureSasCredential credential, Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClientOptions clientOptions = default);
new Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClient : string * string * Azure.AzureSasCredential * Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClientOptions -> Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClient
Public Sub New (fullyQualifiedNamespace As String, eventHubName As String, credential As AzureSasCredential, Optional clientOptions As EventHubBufferedProducerClientOptions = Nothing)

Parameters

fullyQualifiedNamespace
String

The fully qualified Event Hubs namespace to connect to. This is likely to be similar to {yournamespace}.servicebus.windows.net.

eventHubName
String

The name of the specific Event Hub to associate the producer with.

credential
AzureSasCredential

The shared access key credential to use for authorization. Access controls may be specified by the Event Hubs namespace or the requested Event Hub, depending on Azure configuration.

clientOptions
EventHubBufferedProducerClientOptions

A set of EventHubBufferedProducerClientOptions to apply when configuring the producer.

Applies to

EventHubBufferedProducerClient(String, String, TokenCredential, EventHubBufferedProducerClientOptions)

Source:
EventHubBufferedProducerClient.cs
Source:
EventHubBufferedProducerClient.cs

Initializes a new instance of the EventHubBufferedProducerClient class.

public EventHubBufferedProducerClient (string fullyQualifiedNamespace, string eventHubName, Azure.Core.TokenCredential credential, Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClientOptions clientOptions = default);
new Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClient : string * string * Azure.Core.TokenCredential * Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClientOptions -> Azure.Messaging.EventHubs.Producer.EventHubBufferedProducerClient
Public Sub New (fullyQualifiedNamespace As String, eventHubName As String, credential As TokenCredential, Optional clientOptions As EventHubBufferedProducerClientOptions = Nothing)

Parameters

fullyQualifiedNamespace
String

The fully qualified Event Hubs namespace to connect to. This is likely to be similar to {yournamespace}.servicebus.windows.net.

eventHubName
String

The name of the specific Event Hub to associate the producer with.

credential
TokenCredential

The shared access key credential to use for authorization. Access controls may be specified by the Event Hubs namespace or the requested Event Hub, depending on Azure configuration.

clientOptions
EventHubBufferedProducerClientOptions

A set of EventHubBufferedProducerClientOptions to apply when configuring the producer.

Applies to