← ZIO Kafka docs

Subscription

zio.kafka.consumer.Subscription
See theSubscription companion trait
object Subscription

Attributes

Companion
trait
Source
Subscription.scala
Graph
Supertypes
trait Sum
trait Mirror
class Object
trait Matchable
class Any
Self type

Members list

Type members

Classlikes

final case class Manual(topicPartitions: Set[TopicPartition]) extends Subscription

Attributes

Source
Subscription.scala
Supertypes
trait Serializable
trait Product
trait Equals
trait Subscription
class Object
trait Matchable
class Any
Show all
final case class Pattern(pattern: Regex) extends Subscription

Attributes

Source
Subscription.scala
Supertypes
trait Serializable
trait Product
trait Equals
trait Subscription
class Object
trait Matchable
class Any
Show all
final case class Topics(topics: Set[String]) extends Subscription

Attributes

Source
Subscription.scala
Supertypes
trait Serializable
trait Product
trait Equals
trait Subscription
class Object
trait Matchable
class Any
Show all

Inherited and Abstract types

The names of the product elements.

The names of the product elements.

Attributes

Inherited from:
Mirror
Source
Mirror.scala

The name of the type.

The name of the type.

Attributes

Inherited from:
Mirror
Source
Mirror.scala

Value members

Concrete methods

def manual(topicPartitions: (String, Int)*): Manual

Create a manual subscription to a fixed set of topic-partitions

Create a manual subscription to a fixed set of topic-partitions

A consumer with this type of subscription does not perform consumer rebalancing

Value parameters

topicPartitions

Tuples of topic and partition

Attributes

Source
Subscription.scala
def manual(topic: String, partition: Int): Manual

Create a subscription to a single topic-partition

Create a subscription to a single topic-partition

A consumer with this type of subscription does not perform consumer rebalancing

Attributes

Source
Subscription.scala
def pattern(pattern: Regex): Subscription

Create a subscription for all topics matching the given pattern

Create a subscription for all topics matching the given pattern

Value parameters

pattern

Pattern

Attributes

Source
Subscription.scala
def pattern(pattern: String): Task[Subscription]

Create a subscription for all topics matching the given pattern

Create a subscription for all topics matching the given pattern

Value parameters

pattern

Pattern to be converted to a Regex

Attributes

Returns

The created subscription or failure when the pattern is invalid

Source
Subscription.scala
def pattern(pattern: Pattern): Subscription

Create a subscription for all topics matching the given pattern

Create a subscription for all topics matching the given pattern

Value parameters

pattern

Pattern

Attributes

Source
Subscription.scala
def topics(name: String, names: String*): Subscription

Create a subscription for one or more topics

Create a subscription for one or more topics

Value parameters

name

Topic to subscribe to

names

Additional topics to subscribe to

Attributes

Source
Subscription.scala