Class StoreQueryParameters<T>

java.lang.Object
org.apache.kafka.streams.StoreQueryParameters<T>

public class StoreQueryParameters<T> extends Object
StoreQueryParameters allows you to pass a variety of parameters when fetching a store for interactive query.
  • Method Details Link icon

    • fromNameAndType Link icon

      public static <T> StoreQueryParameters<T> fromNameAndType(String storeName, QueryableStoreType<T> queryableStoreType)
    • withPartition Link icon

      public StoreQueryParameters<T> withPartition(Integer partition)
      Set a specific partition that should be queried exclusively.
      Parameters:
      partition - The specific integer partition to be fetched from the stores list by using StoreQueryParameters.
      Returns:
      StoreQueryParameters a new StoreQueryParameters instance configured with the specified partition
    • enableStaleStores Link icon

      public StoreQueryParameters<T> enableStaleStores()
      Enable querying of stale state stores, i.e., allow to query active tasks during restore as well as standby tasks.
      Returns:
      StoreQueryParameters a new StoreQueryParameters instance configured with serving from stale stores enabled
    • storeName Link icon

      public String storeName()
      Get the name of the state store that should be queried.
      Returns:
      String state store name
    • queryableStoreType Link icon

      public QueryableStoreType<T> queryableStoreType()
      Get the queryable store type for which key is queried by the user.
      Returns:
      QueryableStoreType type of queryable store
    • partition Link icon

      public Integer partition()
      Get the store partition that will be queried. If the method returns null, it would mean that no specific partition has been requested, so all the local partitions for the store will be queried.
      Returns:
      Integer partition
    • staleStoresEnabled Link icon

      public boolean staleStoresEnabled()
      Get the flag staleStores. If true, include standbys and recovering stores along with running stores.
      Returns:
      boolean staleStores
    • equals Link icon

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • toString Link icon

      public String toString()
      Overrides:
      toString in class Object
    • hashCode Link icon

      public int hashCode()
      Overrides:
      hashCode in class Object