Package org.apache.kafka.streams.kstream
Class Joined<K,VLeft,VRight>
java.lang.Object
org.apache.kafka.streams.kstream.Joined<K,VLeft,VRight>
- Type Parameters:
K
- type of record keyVLeft
- type of left record valueVRight
- type of right record value
The
Joined
class represents optional params that can be passed to
KStream#join(KTable,...)
and
KStream#leftJoin(KTable,...)
operations.-
Method Summary
Modifier and TypeMethodDescriptionstatic <K,
VLeft, VRight>
Joined<K, VLeft, VRight> Create an instance ofJoined
with base name for all components of the join, this may include any repartition topics created to complete the join.Deprecated.Since 4.0 and should not be used any longer.keySerde()
Deprecated.Since 4.0 and should not be used any longer.static <K,
VLeft, VRight>
Joined<K, VLeft, VRight> Create an instance ofJoined
with a keySerde
.Deprecated.Since 4.0 and should not be used any longer.static <K,
VLeft, VRight>
Joined<K, VLeft, VRight> otherValueSerde
(Serde<VRight> rightValueSerde) Create an instance ofJoined
with aother valueSerde
.Deprecated.Since 4.0 and should not be used any longer.static <K,
VLeft, VRight>
Joined<K, VLeft, VRight> valueSerde
(Serde<VLeft> leftValueSerde) Create an instance ofJoined
with a valueSerde
.static <K,
VLeft, VRight>
Joined<K, VLeft, VRight> Create an instance ofJoined
with key, value, and otherValueSerde
instances.static <K,
VLeft, VRight>
Joined<K, VLeft, VRight> Create an instance ofJoined
with key, value, and otherValueSerde
instances.static <K,
VLeft, VRight>
Joined<K, VLeft, VRight> with
(Serde<K> keySerde, Serde<VLeft> leftValueSerde, Serde<VRight> rightValueSerde, String name, Duration gracePeriod) Create an instance ofJoined
with key, value, and otherValueSerde
instances.withGracePeriod
(Duration gracePeriod) Set the grace period on the stream side of the join.withKeySerde
(Serde<K> keySerde) Set the keySerde
to be used.Set the base name used for all components of the join, this may include any repartition topics created to complete the join.withOtherValueSerde
(Serde<VRight> rightValueSerde) Set the otherValueSerde
to be used.withValueSerde
(Serde<VLeft> leftValueSerde) Set the valueSerde
to be used.
-
Method Details
-
with
public static <K,VLeft, Joined<K,VRight> VLeft, withVRight> (Serde<K> keySerde, Serde<VLeft> leftValueSerde, Serde<VRight> rightValueSerde) Create an instance ofJoined
with key, value, and otherValueSerde
instances.null
values are accepted and will be replaced by the default serdes as defined in config.- Type Parameters:
K
- key typeVLeft
- left value typeVRight
- right value type- Parameters:
keySerde
- the key serde to use. Ifnull
the default key serde from config will be usedleftValueSerde
- the value serde to use. Ifnull
the default value serde from config will be usedrightValueSerde
- the otherValue serde to use. Ifnull
the default value serde from config will be used- Returns:
- new
Joined
instance with the provided serdes
-
with
public static <K,VLeft, Joined<K,VRight> VLeft, withVRight> (Serde<K> keySerde, Serde<VLeft> leftValueSerde, Serde<VRight> rightValueSerde, String name) Create an instance ofJoined
with key, value, and otherValueSerde
instances.null
values are accepted and will be replaced by the default serdes as defined in config.- Type Parameters:
K
- key typeVLeft
- left value typeVRight
- right value type- Parameters:
keySerde
- the key serde to use. Ifnull
the default key serde from config will be usedleftValueSerde
- the left value serde to use. Ifnull
the default value serde from config will be usedrightValueSerde
- the right value serde to use. Ifnull
the default value serde from config will be usedname
- the name used as the base for naming components of the join including any repartition topics- Returns:
- new
Joined
instance with the provided serdes
-
with
public static <K,VLeft, Joined<K,VRight> VLeft, withVRight> (Serde<K> keySerde, Serde<VLeft> leftValueSerde, Serde<VRight> rightValueSerde, String name, Duration gracePeriod) Create an instance ofJoined
with key, value, and otherValueSerde
instances.null
values are accepted and will be replaced by the default serdes as defined in config.- Type Parameters:
K
- key typeVLeft
- value value typeVRight
- right value type- Parameters:
keySerde
- the key serde to use. Ifnull
the default key serde from config will be usedleftValueSerde
- the left value serde to use. Ifnull
the default value serde from config will be usedrightValueSerde
- the right value serde to use. Ifnull
the default value serde from config will be usedname
- the name used as the base for naming components of the join including any repartition topicsgracePeriod
- stream buffer time- Returns:
- new
Joined
instance with the provided serdes
-
keySerde
Create an instance ofJoined
with a keySerde
.null
values are accepted and will be replaced by the default key serde as defined in config.- Type Parameters:
K
- key typeVLeft
- value value typeVRight
- right value type- Parameters:
keySerde
- the key serde to use. Ifnull
the default key serde from config will be used- Returns:
- new
Joined
instance configured with the keySerde
-
valueSerde
Create an instance ofJoined
with a valueSerde
.null
values are accepted and will be replaced by the default value serde as defined in config.- Type Parameters:
K
- key typeVLeft
- left value typeVRight
- right value type- Parameters:
leftValueSerde
- the left value serde to use. Ifnull
the default value serde from config will be used- Returns:
- new
Joined
instance configured with the valueSerde
-
otherValueSerde
public static <K,VLeft, Joined<K,VRight> VLeft, otherValueSerdeVRight> (Serde<VRight> rightValueSerde) Create an instance ofJoined
with aother valueSerde
.null
values are accepted and will be replaced by the default value serde as defined in config.- Type Parameters:
K
- key typeVLeft
- value typeVRight
- right value type- Parameters:
rightValueSerde
- the right value serde to use. Ifnull
the default value serde from config will be used- Returns:
- new
Joined
instance configured with the otherValueSerde
-
as
Create an instance ofJoined
with base name for all components of the join, this may include any repartition topics created to complete the join.- Type Parameters:
K
- key typeVLeft
- left value typeVRight
- right value type- Parameters:
name
- the name used as the base for naming components of the join including any repartition topics- Returns:
- new
Joined
instance configured with the name
-
withKeySerde
Set the keySerde
to be used. Null values are accepted and will be replaced by the default key serde as defined in config- Parameters:
keySerde
- the key serde to use. If null the default key serde from config will be used- Returns:
- new
Joined
instance configured with thename
-
withValueSerde
Set the valueSerde
to be used. Null values are accepted and will be replaced by the default value serde as defined in config- Parameters:
leftValueSerde
- the left value serde to use. If null the default value serde from config will be used- Returns:
- new
Joined
instance configured with thevalueSerde
-
withOtherValueSerde
Set the otherValueSerde
to be used. Null values are accepted and will be replaced by the default value serde as defined in config- Parameters:
rightValueSerde
- the right value serde to use. If null the default value serde from config will be used- Returns:
- new
Joined
instance configured with thevalueSerde
-
withName
Set the base name used for all components of the join, this may include any repartition topics created to complete the join.- Parameters:
name
- the name used as the base for naming components of the join including any repartition topics- Returns:
- new
Joined
instance configured with thename
-
withGracePeriod
Set the grace period on the stream side of the join. Records will enter a buffer before being processed. Out of order records in the grace period will be processed in timestamp order. Late records, out of the grace period, will be executed right as they come in, if it is past the table history retention this could result in a null join. Long gaps in stream side arriving records will cause records to be delayed in processing.- Parameters:
gracePeriod
- the duration of the grace period. Must be less than the joining table's history retention.- Returns:
- new
Joined
instance configured with the gracePeriod
-
gracePeriod
Deprecated.Since 4.0 and should not be used any longer. -
keySerde
Deprecated.Since 4.0 and should not be used any longer. -
valueSerde
Deprecated.Since 4.0 and should not be used any longer. -
otherValueSerde
Deprecated.Since 4.0 and should not be used any longer.
-