Class StrictBufferConfigImpl
- java.lang.Object
-
- org.apache.kafka.streams.kstream.internals.suppress.BufferConfigInternal<Suppressed.StrictBufferConfig>
-
- org.apache.kafka.streams.kstream.internals.suppress.StrictBufferConfigImpl
-
- All Implemented Interfaces:
Suppressed.BufferConfig<Suppressed.StrictBufferConfig>
,Suppressed.StrictBufferConfig
public class StrictBufferConfigImpl extends BufferConfigInternal<Suppressed.StrictBufferConfig> implements Suppressed.StrictBufferConfig
-
-
Constructor Summary
Constructors Constructor Description StrictBufferConfigImpl()
StrictBufferConfigImpl(long maxRecords, long maxBytes, BufferFullStrategy bufferFullStrategy)
StrictBufferConfigImpl(long maxRecords, long maxBytes, BufferFullStrategy bufferFullStrategy, Map<String,String> logConfig)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description BufferFullStrategy
bufferFullStrategy()
boolean
equals(Object o)
Map<String,String>
getLogConfig()
int
hashCode()
boolean
isLoggingEnabled()
long
maxBytes()
long
maxRecords()
String
toString()
Suppressed.StrictBufferConfig
withLoggingDisabled()
Disable the changelog for this suppression's internal buffer.Suppressed.StrictBufferConfig
withLoggingEnabled(Map<String,String> config)
Indicates that a changelog topic should be created containing the currently suppressed records.Suppressed.StrictBufferConfig
withMaxBytes(long byteLimit)
Set a size constraint on the buffer, the maximum number of bytes it will use.Suppressed.StrictBufferConfig
withMaxRecords(long recordLimit)
Set a size constraint on the buffer in terms of the maximum number of keys it will store.-
Methods inherited from class org.apache.kafka.streams.kstream.internals.suppress.BufferConfigInternal
emitEarlyWhenFull, shutDownWhenFull, withNoBound
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.apache.kafka.streams.kstream.Suppressed.BufferConfig
emitEarlyWhenFull, shutDownWhenFull, withNoBound
-
-
-
-
Constructor Detail
-
StrictBufferConfigImpl
public StrictBufferConfigImpl(long maxRecords, long maxBytes, BufferFullStrategy bufferFullStrategy, Map<String,String> logConfig)
-
StrictBufferConfigImpl
public StrictBufferConfigImpl(long maxRecords, long maxBytes, BufferFullStrategy bufferFullStrategy)
-
StrictBufferConfigImpl
public StrictBufferConfigImpl()
-
-
Method Detail
-
withMaxRecords
public Suppressed.StrictBufferConfig withMaxRecords(long recordLimit)
Description copied from interface:Suppressed.BufferConfig
Set a size constraint on the buffer in terms of the maximum number of keys it will store.- Specified by:
withMaxRecords
in interfaceSuppressed.BufferConfig<Suppressed.StrictBufferConfig>
-
withMaxBytes
public Suppressed.StrictBufferConfig withMaxBytes(long byteLimit)
Description copied from interface:Suppressed.BufferConfig
Set a size constraint on the buffer, the maximum number of bytes it will use.- Specified by:
withMaxBytes
in interfaceSuppressed.BufferConfig<Suppressed.StrictBufferConfig>
-
maxRecords
public long maxRecords()
- Specified by:
maxRecords
in classBufferConfigInternal<Suppressed.StrictBufferConfig>
-
maxBytes
public long maxBytes()
- Specified by:
maxBytes
in classBufferConfigInternal<Suppressed.StrictBufferConfig>
-
bufferFullStrategy
public BufferFullStrategy bufferFullStrategy()
- Specified by:
bufferFullStrategy
in classBufferConfigInternal<Suppressed.StrictBufferConfig>
-
withLoggingDisabled
public Suppressed.StrictBufferConfig withLoggingDisabled()
Description copied from interface:Suppressed.BufferConfig
Disable the changelog for this suppression's internal buffer. This will turn off fault-tolerance for the suppression, and will result in data loss in the event of a rebalance. By default the changelog is enabled.- Specified by:
withLoggingDisabled
in interfaceSuppressed.BufferConfig<Suppressed.StrictBufferConfig>
- Returns:
- this
-
withLoggingEnabled
public Suppressed.StrictBufferConfig withLoggingEnabled(Map<String,String> config)
Description copied from interface:Suppressed.BufferConfig
Indicates that a changelog topic should be created containing the currently suppressed records. Due to the short-lived nature of records in this topic it is likely more compactable than changelog topics for KTables.- Specified by:
withLoggingEnabled
in interfaceSuppressed.BufferConfig<Suppressed.StrictBufferConfig>
- Parameters:
config
- Configs that should be applied to the changelog. Note: Any unrecognized configs will be ignored.- Returns:
- this
-
isLoggingEnabled
public boolean isLoggingEnabled()
- Specified by:
isLoggingEnabled
in classBufferConfigInternal<Suppressed.StrictBufferConfig>
-
getLogConfig
public Map<String,String> getLogConfig()
- Specified by:
getLogConfig
in classBufferConfigInternal<Suppressed.StrictBufferConfig>
-
-