Class/Object

akka.kafka

ConsumerSettings

Related Docs: object ConsumerSettings | package kafka

Permalink

class ConsumerSettings[K, V] extends AnyRef

Settings for consumers. See akka.kafka.consumer section in reference.conf. Note that the companion object provides apply and create functions for convenient construction of the settings, together with the with methods.

The constructor is Internal API.

Source
ConsumerSettings.scala
Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. ConsumerSettings
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  5. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  6. val closeTimeout: FiniteDuration

    Permalink
  7. val commitRefreshInterval: Duration

    Permalink
  8. val commitTimeWarning: FiniteDuration

    Permalink
  9. val commitTimeout: FiniteDuration

    Permalink
  10. val connectionCheckerSettings: ConnectionCheckerSettings

    Permalink
  11. val consumerFactory: (ConsumerSettings[K, V]) ⇒ Consumer[K, V]

    Permalink
  12. def createKafkaConsumer(): Consumer[K, V]

    Permalink

    Create a Kafka Consumer instance from these settings.

    Create a Kafka Consumer instance from these settings.

    This will fail with IllegalStateException if asynchronous enrichment is set up -- always prefer createKafkaConsumerAsync() or createKafkaConsumerCompletionStage().

    Exceptions thrown

    IllegalStateException if asynchronous enrichment is set via withEnrichAsync or withEnrichCompletionStage, you must use createKafkaConsumerAsync or createKafkaConsumerCompletionStage to apply it

  13. def createKafkaConsumerAsync()(implicit executionContext: ExecutionContext): Future[Consumer[K, V]]

    Permalink

    Scala API.

    Scala API.

    Create a Kafka Consumer instance from these settings (without blocking for enriched).

  14. def createKafkaConsumerCompletionStage(executor: Executor): CompletionStage[Consumer[K, V]]

    Permalink

    Java API.

    Java API.

    Create a Kafka Consumer instance from these settings (without blocking for enriched).

  15. val dispatcher: String

    Permalink
  16. val drainingCheckInterval: FiniteDuration

    Permalink
  17. val enrichAsync: Option[(ConsumerSettings[K, V]) ⇒ Future[ConsumerSettings[K, V]]]

    Permalink
  18. def enriched: Future[ConsumerSettings[K, V]]

    Permalink

    Applies enrichAsync to complement these settings from asynchronous sources.

  19. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  20. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  21. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  22. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  23. def getCloseTimeout: Duration

    Permalink
  24. def getMetadataRequestTimeout: Duration

    Permalink
  25. def getOffsetForTimesTimeout: Duration

    Permalink
  26. def getPositionTimeout: Duration

    Permalink
  27. def getProperties: Map[String, AnyRef]

    Permalink

    Get the Kafka consumer settings as map.

  28. def getProperty(key: String): String

    Permalink

    Java API: Get a raw property.

    Java API: Get a raw property. null if it is not defined.

  29. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  30. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  31. val keyDeserializerOpt: Option[Deserializer[K]]

    Permalink
  32. val metadataRequestTimeout: FiniteDuration

    Permalink
  33. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  34. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  35. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  36. val offsetForTimesTimeout: FiniteDuration

    Permalink
  37. val partitionHandlerWarning: FiniteDuration

    Permalink
  38. val pollInterval: FiniteDuration

    Permalink
  39. val pollTimeout: FiniteDuration

    Permalink
  40. val positionTimeout: FiniteDuration

    Permalink
  41. val properties: Map[String, String]

    Permalink
  42. val stopTimeout: FiniteDuration

    Permalink
  43. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  44. def toString(): String

    Permalink
    Definition Classes
    ConsumerSettings → AnyRef → Any
  45. val valueDeserializerOpt: Option[Deserializer[V]]

    Permalink
  46. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  47. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  48. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  49. val waitClosePartition: FiniteDuration

    Permalink
  50. def withBootstrapServers(bootstrapServers: String): ConsumerSettings[K, V]

    Permalink

    A comma-separated list of host/port pairs to use for establishing the initial connection to the Kafka cluster.

  51. def withClientId(clientId: String): ConsumerSettings[K, V]

    Permalink

    An id string to pass to the server when making requests.

    An id string to pass to the server when making requests. The purpose of this is to be able to track the source of requests beyond just ip/port by allowing a logical application name to be included in server-side request logging.

  52. def withCloseTimeout(closeTimeout: Duration): ConsumerSettings[K, V]

    Permalink

    Java API: Set duration to wait for KafkaConsumer.close to finish.

  53. def withCloseTimeout(closeTimeout: FiniteDuration): ConsumerSettings[K, V]

    Permalink

    Set duration to wait for KafkaConsumer.close to finish.

  54. def withCommitRefreshInterval(commitRefreshInterval: Duration): ConsumerSettings[K, V]

    Permalink

    Java API: If set to a finite duration, the consumer will re-send the last committed offsets periodically for all assigned partitions.

    Java API: If set to a finite duration, the consumer will re-send the last committed offsets periodically for all assigned partitions. @see https://issues.apache.org/jira/browse/KAFKA-4682 Set to java.time.Duration.ZERO to switch it off.

    See also

    https://issues.apache.org/jira/browse/KAFKA-4682

  55. def withCommitRefreshInterval(commitRefreshInterval: Duration): ConsumerSettings[K, V]

    Permalink

    If set to a finite duration, the consumer will re-send the last committed offsets periodically for all assigned partitions.

    If set to a finite duration, the consumer will re-send the last committed offsets periodically for all assigned partitions.

    See also

    https://issues.apache.org/jira/browse/KAFKA-4682

  56. def withCommitTimeout(commitTimeout: Duration): ConsumerSettings[K, V]

    Permalink

    Java API: If offset commit requests are not completed within this timeout the returned Future is completed with akka.kafka.CommitTimeoutException.

  57. def withCommitTimeout(commitTimeout: FiniteDuration): ConsumerSettings[K, V]

    Permalink

    If offset commit requests are not completed within this timeout the returned Future is completed with akka.kafka.CommitTimeoutException.

  58. def withCommitWarning(commitTimeWarning: Duration): ConsumerSettings[K, V]

    Permalink

    Java API: If commits take longer than this time a warning is logged

  59. def withCommitWarning(commitTimeWarning: FiniteDuration): ConsumerSettings[K, V]

    Permalink

    If commits take longer than this time a warning is logged

  60. def withConnectionChecker(kafkaConnectionCheckerConfig: ConnectionCheckerSettings): ConsumerSettings[K, V]

    Permalink

    Enable kafka connection checker with provided settings

  61. def withConsumerFactory(factory: (ConsumerSettings[K, V]) ⇒ Consumer[K, V]): ConsumerSettings[K, V]

    Permalink

    Replaces the default Kafka consumer creation logic.

  62. def withDispatcher(dispatcher: String): ConsumerSettings[K, V]

    Permalink

    Fully qualified config path which holds the dispatcher configuration to be used by the akka.kafka.KafkaConsumerActor.

    Fully qualified config path which holds the dispatcher configuration to be used by the akka.kafka.KafkaConsumerActor. Some blocking may occur.

  63. def withDrainingCheckInterval(drainingCheckInterval: Duration): ConsumerSettings[K, V]

    Permalink

    Java API: Check interval for TransactionalProducer when finishing transaction before shutting down consumer

  64. def withDrainingCheckInterval(drainingCheckInterval: FiniteDuration): ConsumerSettings[K, V]

    Permalink

    Scala API: Check interval for TransactionalProducer when finishing transaction before shutting down consumer

  65. def withEnrichAsync(value: (ConsumerSettings[K, V]) ⇒ Future[ConsumerSettings[K, V]]): ConsumerSettings[K, V]

    Permalink

    Scala API.

    Scala API. A hook to allow for resolving some settings asynchronously.

    Since

    2.0.0

  66. def withEnrichCompletionStage(value: Function[ConsumerSettings[K, V], CompletionStage[ConsumerSettings[K, V]]]): ConsumerSettings[K, V]

    Permalink

    Java API.

    Java API. A hook to allow for resolving some settings asynchronously.

    Since

    2.0.0

  67. def withGroupId(groupId: String): ConsumerSettings[K, V]

    Permalink

    A unique string that identifies the consumer group this consumer belongs to.

  68. def withGroupInstanceId(groupInstanceId: String): ConsumerSettings[K, V]

    Permalink

    An id string that marks consumer as a unique static member of the consumer group.

  69. def withMetadataRequestTimeout(metadataRequestTimeout: Duration): ConsumerSettings[K, V]

    Permalink

    Java API

  70. def withMetadataRequestTimeout(metadataRequestTimeout: FiniteDuration): ConsumerSettings[K, V]

    Permalink

    Scala API

  71. def withOffsetForTimesTimeout(offsetForTimesTimeout: Duration): ConsumerSettings[K, V]

    Permalink

    Java API: Limits the blocking on Kafka consumer offsetForTimes calls.

  72. def withOffsetForTimesTimeout(offsetForTimesTimeout: FiniteDuration): ConsumerSettings[K, V]

    Permalink

    Scala API: Limits the blocking on Kafka consumer offsetForTimes calls.

  73. def withPartitionHandlerWarning(partitionHandlerWarning: Duration): ConsumerSettings[K, V]

    Permalink

    Java API

  74. def withPartitionHandlerWarning(partitionHandlerWarning: FiniteDuration): ConsumerSettings[K, V]

    Permalink

    Scala API

  75. def withPollInterval(pollInterval: Duration): ConsumerSettings[K, V]

    Permalink

    Java API: Set the interval from one scheduled poll to the next.

  76. def withPollInterval(pollInterval: FiniteDuration): ConsumerSettings[K, V]

    Permalink

    Set the interval from one scheduled poll to the next.

  77. def withPollTimeout(pollTimeout: Duration): ConsumerSettings[K, V]

    Permalink

    Java API: Set the maximum duration a poll to the Kafka broker is allowed to take.

  78. def withPollTimeout(pollTimeout: FiniteDuration): ConsumerSettings[K, V]

    Permalink

    Set the maximum duration a poll to the Kafka broker is allowed to take.

  79. def withPositionTimeout(positionTimeout: Duration): ConsumerSettings[K, V]

    Permalink

    Java API: Limits the blocking on Kafka consumer position calls.

  80. def withPositionTimeout(positionTimeout: FiniteDuration): ConsumerSettings[K, V]

    Permalink

    Scala API: Limits the blocking on Kafka consumer position calls.

  81. def withProperties(properties: Map[String, String]): ConsumerSettings[K, V]

    Permalink

    Java API: The raw properties of the kafka-clients driver, see constants in org.apache.kafka.clients.consumer.ConsumerConfig.

  82. def withProperties(properties: (String, String)*): ConsumerSettings[K, V]

    Permalink

    Scala API: The raw properties of the kafka-clients driver, see constants in org.apache.kafka.clients.consumer.ConsumerConfig.

  83. def withProperties(properties: Map[String, String]): ConsumerSettings[K, V]

    Permalink

    Scala API: The raw properties of the kafka-clients driver, see constants in org.apache.kafka.clients.consumer.ConsumerConfig.

  84. def withProperty(key: String, value: String): ConsumerSettings[K, V]

    Permalink

    The raw properties of the kafka-clients driver, see constants in org.apache.kafka.clients.consumer.ConsumerConfig.

  85. def withStopTimeout(stopTimeout: Duration): ConsumerSettings[K, V]

    Permalink

    Java API: The stage will await outstanding offset commit requests before shutting down, but if that takes longer than this timeout it will stop forcefully.

  86. def withStopTimeout(stopTimeout: FiniteDuration): ConsumerSettings[K, V]

    Permalink

    The stage will await outstanding offset commit requests before shutting down, but if that takes longer than this timeout it will stop forcefully.

  87. def withWaitClosePartition(waitClosePartition: Duration): ConsumerSettings[K, V]

    Permalink

    Java API: Time to wait for pending requests when a partition is closed.

  88. def withWaitClosePartition(waitClosePartition: FiniteDuration): ConsumerSettings[K, V]

    Permalink

    Time to wait for pending requests when a partition is closed.

Inherited from AnyRef

Inherited from Any

Ungrouped