Class JedisRedisCheckpointStore

java.lang.Object
com.azure.messaging.eventhubs.checkpointstore.jedis.JedisRedisCheckpointStore
All Implemented Interfaces:
CheckpointStore

public class JedisRedisCheckpointStore extends Object implements CheckpointStore
Implementation of CheckpointStore that uses Azure Redis Cache, specifically Jedis.
  • Method Details

    • claimOwnership

      public Flux<PartitionOwnership> claimOwnership(List<PartitionOwnership> requestedPartitionOwnerships)
      This method returns the list of partitions that were owned successfully.
      Specified by:
      claimOwnership in interface CheckpointStore
      Parameters:
      requestedPartitionOwnerships - List of partition ownerships from the current instance
      Returns:
      Flux of PartitionOwnership objects
    • listCheckpoints

      public Flux<Checkpoint> listCheckpoints(String fullyQualifiedNamespace, String eventHubName, String consumerGroup)
      This method returns the list of checkpoints from the underlying data store, and if no checkpoints are available, then it returns empty results.
      Specified by:
      listCheckpoints in interface CheckpointStore
      Parameters:
      fullyQualifiedNamespace - The fully qualified namespace of the current instance Event Hub
      eventHubName - The Event Hub name from which checkpoint information is acquired
      consumerGroup - The consumer group name associated with the checkpoint
      Returns:
      Flux of Checkpoint objects
    • listOwnership

      public Flux<PartitionOwnership> listOwnership(String fullyQualifiedNamespace, String eventHubName, String consumerGroup)
      This method returns the list of ownership records from the underlying data store, and if no ownership records are available, then it returns empty results.
      Specified by:
      listOwnership in interface CheckpointStore
      Parameters:
      fullyQualifiedNamespace - The fully qualified namespace of the current instance of Event Hub
      eventHubName - The Event Hub name from which checkpoint information is acquired
      consumerGroup - The consumer group name associated with the checkpoint
      Returns:
      Flux of PartitionOwnership objects
    • updateCheckpoint

      public Mono<Void> updateCheckpoint(Checkpoint checkpoint)
      This method updates the checkpoint in the Jedis resource for a given partition.
      Specified by:
      updateCheckpoint in interface CheckpointStore
      Parameters:
      checkpoint - Checkpoint information for this partition
      Returns:
      Mono that completes if no errors take place