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 anEventHubClientAll options default to not specified (null)
-
-
Field Summary
Fields Modifier and Type Field Description static DurationSILENT_MINIMUMstatic DurationSILENT_OFF
-
Constructor Summary
Constructors Constructor Description EventHubClientOptions()Create with all defaults
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DurationgetMaximumSilentTime()Gets the maximum silent time in seconds.DurationgetOperationTimeout()Get the operation timeout.ProxyConfigurationgetProxyConfiguration()Gets the proxy configuration for this set of options.RetryPolicygetRetryPolicy()Get the retry policyTransportTypegetTransportType()Get the transport typeEventHubClientOptionssetMaximumSilentTime(Duration maximumSilentTime)Sets the maximum silent time, in seconds.EventHubClientOptionssetOperationTimeout(Duration operationTimeout)Set the operation timeout.EventHubClientOptionssetProxyConfiguration(ProxyConfiguration proxyConfiguration)Sets the proxy configuration for the client options.EventHubClientOptionssetRetryPolicy(RetryPolicy retryPolicy)Set theRetryPolicyfor operationsEventHubClientOptionssetTransportType(TransportType transportType)Set theTransportTypefor 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 theTransportTypefor 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:
TransportTypeor null if not set
-
setRetryPolicy
public EventHubClientOptions setRetryPolicy(RetryPolicy retryPolicy)
Set theRetryPolicyfor 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:
RetryPolicyor 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.
-
-