pub struct ConsumerGroupDescription { /* private fields */ }Expand description
A detailed description of a single consumer group in the cluster.
Implementations§
Source§impl ConsumerGroupDescription
impl ConsumerGroupDescription
Sourcepub fn new(
group_id: impl Into<String>,
is_simple_consumer_group: bool,
members: Vec<MemberDescription>,
partition_assignor: impl Into<String>,
group_type: GroupType,
group_state: GroupState,
coordinator: Option<Node>,
authorized_operations: Option<BTreeSet<AclOperation>>,
group_epoch: Option<i32>,
target_assignment_epoch: Option<i32>,
) -> Self
pub fn new( group_id: impl Into<String>, is_simple_consumer_group: bool, members: Vec<MemberDescription>, partition_assignor: impl Into<String>, group_type: GroupType, group_state: GroupState, coordinator: Option<Node>, authorized_operations: Option<BTreeSet<AclOperation>>, group_epoch: Option<i32>, target_assignment_epoch: Option<i32>, ) -> Self
Creates a consumer group description with all fields.
§Arguments
group_id- the id of the consumer group.is_simple_consumer_group- whether the group is a simple consumer group.members- the members of the group.partition_assignor- the name of the partition assignor.group_type- the group protocol type.group_state- the group state.coordinator- the group coordinator, orNoneif not known.authorized_operations- the authorized operations for this group, orNoneif not known.group_epoch- the epoch of the group, orNonefor a classic group.target_assignment_epoch- the epoch of the target assignment, orNonefor a classic group.
Sourcepub fn is_simple_consumer_group(&self) -> bool
pub fn is_simple_consumer_group(&self) -> bool
Returns whether the consumer group is simple.
Sourcepub fn members(&self) -> &[MemberDescription]
pub fn members(&self) -> &[MemberDescription]
Returns the members of the consumer group.
Sourcepub fn partition_assignor(&self) -> &str
pub fn partition_assignor(&self) -> &str
Returns the consumer group partition assignor.
Sourcepub fn group_state(&self) -> GroupState
pub fn group_state(&self) -> GroupState
Returns the group state, or GroupState::Unknown if the state is too new for us to
parse.
Sourcepub fn coordinator(&self) -> Option<&Node>
pub fn coordinator(&self) -> Option<&Node>
Returns the consumer group coordinator, or None if not known.
Returns the authorized operations for this group, or None if that information is
not known.
Sourcepub fn group_epoch(&self) -> Option<i32>
pub fn group_epoch(&self) -> Option<i32>
Returns the epoch of the consumer group. The optional is set to an integer if it is a
GroupType::Consumer group, and to None if it is a GroupType::Classic group.
Sourcepub fn target_assignment_epoch(&self) -> Option<i32>
pub fn target_assignment_epoch(&self) -> Option<i32>
Returns the epoch of the target assignment. The optional is set to an integer if it is a
GroupType::Consumer group, and to None if it is a GroupType::Classic group.
Trait Implementations§
Source§impl Clone for ConsumerGroupDescription
impl Clone for ConsumerGroupDescription
Source§fn clone(&self) -> ConsumerGroupDescription
fn clone(&self) -> ConsumerGroupDescription
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ConsumerGroupDescription
impl Debug for ConsumerGroupDescription
Source§impl Display for ConsumerGroupDescription
impl Display for ConsumerGroupDescription
Source§impl Hash for ConsumerGroupDescription
impl Hash for ConsumerGroupDescription
Source§impl PartialEq for ConsumerGroupDescription
impl PartialEq for ConsumerGroupDescription
impl Eq for ConsumerGroupDescription
impl StructuralPartialEq for ConsumerGroupDescription
Auto Trait Implementations§
impl Freeze for ConsumerGroupDescription
impl RefUnwindSafe for ConsumerGroupDescription
impl Send for ConsumerGroupDescription
impl Sync for ConsumerGroupDescription
impl Unpin for ConsumerGroupDescription
impl UnsafeUnpin for ConsumerGroupDescription
impl UnwindSafe for ConsumerGroupDescription
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.