Class EventHubsConfiguration

java.lang.Object
org.apache.camel.component.azure.eventhubs.EventHubsConfiguration
All Implemented Interfaces:
Cloneable

@UriParams public class EventHubsConfiguration extends Object implements Cloneable
  • Constructor Details

    • EventHubsConfiguration

      public EventHubsConfiguration()
  • Method Details

    • getNamespace

      public String getNamespace()
      EventHubs namespace created in Azure Portal.
    • setNamespace

      public void setNamespace(String namespace)
    • getEventHubName

      public String getEventHubName()
      EventHubs name under a specific namespace.
    • setEventHubName

      public void setEventHubName(String eventHubName)
    • getSharedAccessName

      public String getSharedAccessName()
      The name you chose for your EventHubs SAS keys.
    • setSharedAccessName

      public void setSharedAccessName(String sharedAccessName)
    • getSharedAccessKey

      public String getSharedAccessKey()
      The generated value for the SharedAccessName.
    • setSharedAccessKey

      public void setSharedAccessKey(String sharedAccessKey)
    • getConnectionString

      public String getConnectionString()
      Instead of supplying namespace, sharedAccessKey, sharedAccessName, etc. you can supply the connection string for your eventHub. The connection string for EventHubs already includes all the necessary information to connect to your EventHub. To learn how to generate the connection string, take a look at this documentation: https://docs.microsoft.com/en-us/azure/event-hubs/event-hubs-get-connection-string
    • setConnectionString

      public void setConnectionString(String connectionString)
    • getTokenCredential

      public com.azure.core.credential.TokenCredential getTokenCredential()
      Provide custom authentication credentials using an implementation of TokenCredential.
    • setTokenCredential

      public void setTokenCredential(com.azure.core.credential.TokenCredential tokenCredential)
    • getAmqpTransportType

      public com.azure.core.amqp.AmqpTransportType getAmqpTransportType()
      Sets the transport type by which all the communication with Azure Event Hubs occurs.
    • setAmqpTransportType

      public void setAmqpTransportType(com.azure.core.amqp.AmqpTransportType amqpTransportType)
    • getAmqpRetryOptions

      public com.azure.core.amqp.AmqpRetryOptions getAmqpRetryOptions()
      Sets the retry policy for EventHubProducerAsyncClient. If not specified, the default retry options are used.
    • setAmqpRetryOptions

      public void setAmqpRetryOptions(com.azure.core.amqp.AmqpRetryOptions amqpRetryOptions)
    • getConsumerGroupName

      public String getConsumerGroupName()
      Sets the name of the consumer group this consumer is associated with. Events are read in the context of this group. The name of the consumer group that is created by default is $Default.
    • setConsumerGroupName

      public void setConsumerGroupName(String consumerGroupName)
    • getPrefetchCount

      public int getPrefetchCount()
      Sets the count used by the receiver to control the number of events the Event Hub consumer will actively receive and queue locally without regard to whether a receive operation is currently active.
    • setPrefetchCount

      public void setPrefetchCount(int prefetchCount)
    • getProducerAsyncClient

      public com.azure.messaging.eventhubs.EventHubProducerAsyncClient getProducerAsyncClient()
      Sets the EventHubProducerAsyncClient.An asynchronous producer responsible for transmitting EventData to a specific Event Hub, grouped together in batches. Depending on the CreateBatchOptions options specified when creating an EventDataBatch, the events may be automatically routed to an available partition or specific to a partition. Use by this component to produce the data in camel producer.
    • setProducerAsyncClient

      public void setProducerAsyncClient(com.azure.messaging.eventhubs.EventHubProducerAsyncClient producerAsyncClient)
    • getPartitionId

      public String getPartitionId()
      Sets the identifier of the Event Hub partition that the EventData events will be sent to. If the identifier is not specified, the Event Hubs service will be responsible for routing events that are sent to an available partition.
    • setPartitionId

      public void setPartitionId(String partitionId)
    • getPartitionKey

      public String getPartitionKey()
      Sets a hashing key to be provided for the batch of events, which instructs the Event Hubs service to map this key to a specific partition. The selection of a partition is stable for a given partition hashing key. Should any other batches of events be sent using the same exact partition hashing key, the Event Hubs service will route them all to the same partition. This should be specified only when there is a need to group events by partition, but there is flexibility into which partition they are routed. If ensuring that a batch of events is sent only to a specific partition, it is recommended that the identifier of the position be specified directly when sending the batch.
    • setPartitionKey

      public void setPartitionKey(String partitionKey)
    • getCheckpointStore

      public com.azure.messaging.eventhubs.CheckpointStore getCheckpointStore()
      Sets the CheckpointStore the EventProcessorClient will use for storing partition ownership and checkpoint information.

      Users can, optionally, provide their own implementation of CheckpointStore which will store ownership and checkpoint information.

      By default, it's set to use BlobCheckpointStore which stores all checkpoint offsets into Azure Blob Storage.
    • setCheckpointStore

      public void setCheckpointStore(com.azure.messaging.eventhubs.CheckpointStore checkpointStore)
    • getBlobAccountName

      public String getBlobAccountName()
      In case you chose the default BlobCheckpointStore, this sets Azure account name to be used for authentication with azure blob services.
    • setBlobAccountName

      public void setBlobAccountName(String blobAccountName)
    • getBlobAccessKey

      public String getBlobAccessKey()
      In case you chose the default BlobCheckpointStore, this sets access key for the associated azure account name to be used for authentication with azure blob services.
    • setBlobAccessKey

      public void setBlobAccessKey(String blobAccessKey)
    • getBlobContainerName

      public String getBlobContainerName()
      In case you chose the default BlobCheckpointStore, this sets the blob container that shall be used by the BlobCheckpointStore to store the checkpoint offsets.
    • setBlobContainerName

      public void setBlobContainerName(String blobContainerName)
    • getBlobStorageSharedKeyCredential

      public com.azure.storage.common.StorageSharedKeyCredential getBlobStorageSharedKeyCredential()
      In case you chose the default BlobCheckpointStore, StorageSharedKeyCredential can be injected to create the azure client, this holds the important authentication information.
    • setBlobStorageSharedKeyCredential

      public void setBlobStorageSharedKeyCredential(com.azure.storage.common.StorageSharedKeyCredential blobStorageSharedKeyCredential)
    • getEventPosition

      public Map<String,com.azure.messaging.eventhubs.models.EventPosition> getEventPosition()
      Sets the map containing the event position to use for each partition if a checkpoint for the partition does not exist in CheckpointStore. This map is keyed off of the partition id. If there is no checkpoint in CheckpointStore and there is no entry in this map, the processing of the partition will start from EventPosition.latest() position.
    • setEventPosition

      public void setEventPosition(Map<String,com.azure.messaging.eventhubs.models.EventPosition> eventPosition)
    • getCheckpointBatchSize

      public int getCheckpointBatchSize()
    • setCheckpointBatchSize

      public void setCheckpointBatchSize(int checkpointBatchSize)
      Sets the batch size between each checkpoint update. Works jointly with checkpointBatchTimeout.
    • getCheckpointBatchTimeout

      public int getCheckpointBatchTimeout()
    • setCheckpointBatchTimeout

      public void setCheckpointBatchTimeout(int checkpointBatchTimeout)
      Sets the batch timeout between each checkpoint update. Works jointly with checkpointBatchSize.
    • getCredentialType

      public CredentialType getCredentialType()
    • setCredentialType

      public void setCredentialType(CredentialType credentialType)
      Determines the credential strategy to adopt
    • copy

      public EventHubsConfiguration copy()