faust.types.topics¶
-
class
faust.types.topics.TopicT(app: faust.types.topics.AppT, *, topics: Sequence[str] = None, pattern: Union[str, Pattern[~AnyStr]] = None, key_type: faust.types.topics.ModelArg = None, value_type: faust.types.topics.ModelArg = None, is_iterator: bool = False, partitions: int = None, retention: Union[datetime.timedelta, float, str] = None, compacting: bool = None, deleting: bool = None, replicas: int = None, acks: bool = True, internal: bool = False, config: Mapping[str, Any] = None, queue: mode.utils.queues.ThrowableQueue = None, key_serializer: Union[faust.types.codecs.CodecT, str, NoneType] = None, value_serializer: Union[faust.types.codecs.CodecT, str, NoneType] = None, maxsize: int = None, root: faust.types.channels.ChannelT = None, active_partitions: Set[faust.types.tuples.TP] = None, loop: asyncio.events.AbstractEventLoop = None) → None[source]¶ -
topics= None¶ Iterable/Sequence of topic names to subscribe to.
-
retention= None¶ Topic retention setting – expiry time in seconds for messages in the topic.
-
compacting= None¶ Flag that when enabled means the topic can be “compacted” – if the topic is a log of key/value pairs, the broker can delete old values for the same key.
-
replicas= None¶ Number of replicas for topic.
-
config= None¶ Additional configuration as a mapping.
-
acks= None¶ Enable acks for this topic.
-
internal= None¶ Mark topic as internal – it’s owned by us and we are allowed to create or delete the topic as necessary.
-
pattern¶ or instead of
topics, a regular expression used to match topics we want to subscribe to. :rtype:Optional[Pattern[AnyStr]]
-
partitions¶
-
derive_topic(*, topics: Sequence[str] = None, key_type: faust.types.topics.ModelArg = None, value_type: faust.types.topics.ModelArg = None, partitions: int = None, retention: Union[datetime.timedelta, float, str] = None, compacting: bool = None, deleting: bool = None, internal: bool = False, config: Mapping[str, Any] = None, prefix: str = '', suffix: str = '', **kwargs) → faust.types.topics.TopicT[source]¶ Return type: TopicT[]
-