o
    `jJ                     @   s   d Z ddlmZ edddgZde_ edg dZd	e_ ed
g dg ddZde_ edg dZde_ G dd dZedg dddddejgdZ	de	_ dS )z Other useful structs     )
namedtupleTopicPartitiontopic	partitionzrA topic and partition tuple

Keyword Arguments:
    topic (str): A topic name
    partition (int): A partition id
TopicPartitionReplica)r   r   	broker_idzA topic / partition / broker replica tuple

Keyword Arguments:
    topic (str): A topic name
    partition (int): A partition id
    broker_id (int): The node_id of the broker hosting the replica
OffsetAndMetadata)offsetmetadataleader_epoch)N )defaultsa  Container for committed group offset data.

The Kafka offset commit API allows users to provide additional metadata
(in the form of a string) when an offset is committed. This can be useful
(for example) to store information about which node made the commit,
what time the commit was made, etc.

Keyword Arguments:
    offset (int): The offset to be committed
    metadata (str): Non-null metadata
    leader_epoch (int): The last known epoch from the leader / broker
OffsetAndTimestamp)r	   	timestampr   zAn offset and timestamp tuple

Keyword Arguments:
    offset (int): An offset
    timestamp (int): The timestamp associated to the offset
    leader_epoch (int): The last known epoch from the leader / broker
c                   @   s   e Zd ZdZdZdZdS )MemberStatez
<unjoined>z<rebalancing>z<stable>N)__name__
__module____qualname__UNJOINEDREBALANCINGSTABLE r   r   K/home/djax/ivt_ai_plugin/venv/lib/python3.10/site-packages/kafka/structs.pyr   6   s    r   ConsumerGroupMetadata)group_idgeneration_id	member_idgroup_instance_idstateNr   r   a;  A snapshot of a consumer's group membership.

The first four fields are the KIP-447 fencing identity: pass the snapshot to
KafkaProducer.send_offsets_to_transaction() so the broker can fence stale
consumer instances when committing offsets inside a transaction. The broker
uses member_id + generation_id + group_instance_id to verify the producer is
acting on behalf of the current group generation.

The ``state`` field exposes the live MemberState (it is ignored by the
producer/fencing path). It lets callers observe whether the consumer has
converged on a stable assignment - useful for monitoring and for tests that
wait for a group to finish rebalancing.

Keyword Arguments:
    group_id (str): The consumer group id, or None for manual assignment.
    generation_id (int): The current generation id (-1 if unjoined).
    member_id (str): The current member id ('' if unjoined).
    group_instance_id (str): The static membership instance id, or None.
    state (str): The current MemberState (one of MemberState.UNJOINED,
        MemberState.REBALANCING, MemberState.STABLE).
)
__doc__collectionsr   r   r   r   r   r   r   r   r   r   r   r   <module>   s0    		
