Package com.microsoft.azure.eventhubs
Class EventHubClientOptions
- java.lang.Object
-
- com.microsoft.azure.eventhubs.EventHubClientOptions
-
public class EventHubClientOptions extends Object
Convenient container for options for creating anEventHubClient
All options default to not specified (null)
-
-
Field Summary
Fields Modifier and Type Field Description static Duration
SILENT_MINIMUM
static Duration
SILENT_OFF
-
Constructor Summary
Constructors Constructor Description EventHubClientOptions()
Create with all defaults
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Duration
getMaximumSilentTime()
Gets the maximum silent time in seconds.Duration
getOperationTimeout()
Get the operation timeout.ProxyConfiguration
getProxyConfiguration()
Gets the proxy configuration for this set of options.RetryPolicy
getRetryPolicy()
Get the retry policyTransportType
getTransportType()
Get the transport typeEventHubClientOptions
setMaximumSilentTime(Duration maximumSilentTime)
Sets the maximum silent time, in seconds.EventHubClientOptions
setOperationTimeout(Duration operationTimeout)
Set the operation timeout.EventHubClientOptions
setProxyConfiguration(ProxyConfiguration proxyConfiguration)
Sets the proxy configuration for the client options.EventHubClientOptions
setRetryPolicy(RetryPolicy retryPolicy)
Set theRetryPolicy
for operationsEventHubClientOptions
setTransportType(TransportType transportType)
Set theTransportType
for the connection to the Event Hubs service
-
-
-
Method Detail
-
setOperationTimeout
public EventHubClientOptions setOperationTimeout(Duration operationTimeout)
Set the operation timeout.- Parameters:
operationTimeout
- new operation timeout, null to unset any previous value- Returns:
- this options object
-
getOperationTimeout
public Duration getOperationTimeout()
Get the operation timeout.- Returns:
- operation timeout or null if not set
-
setTransportType
public EventHubClientOptions setTransportType(TransportType transportType)
Set theTransportType
for the connection to the Event Hubs service- Parameters:
transportType
- new transport type, null to unset any previous value- Returns:
- this options object
-
getTransportType
public TransportType getTransportType()
Get the transport type- Returns:
TransportType
or null if not set
-
setRetryPolicy
public EventHubClientOptions setRetryPolicy(RetryPolicy retryPolicy)
Set theRetryPolicy
for operations- Parameters:
retryPolicy
- new retry policy, null to unset any previous value- Returns:
- this options object
-
getRetryPolicy
public RetryPolicy getRetryPolicy()
Get the retry policy- Returns:
RetryPolicy
or null if not set
-
setProxyConfiguration
public EventHubClientOptions setProxyConfiguration(ProxyConfiguration proxyConfiguration)
Sets the proxy configuration for the client options.- Parameters:
proxyConfiguration
- The proxy configuration to set on the options.- Returns:
- The updated options object.
-
getProxyConfiguration
public ProxyConfiguration getProxyConfiguration()
Gets the proxy configuration for this set of options.- Returns:
- Gets the proxy configuration.
-
setMaximumSilentTime
public EventHubClientOptions setMaximumSilentTime(Duration maximumSilentTime)
Sets the maximum silent time, in seconds. Use only on recommendation from the product group.- Parameters:
maximumSilentTime
- The time, or SILENT_OFF. Time must be at least SILENT_MINIMUM.- Returns:
- The updated options object.
-
getMaximumSilentTime
public Duration getMaximumSilentTime()
Gets the maximum silent time in seconds.- Returns:
- The maximum silent time, or SILENT_OFF.
-
-