Skip to main content

Error

Enum Error 

Source
#[non_exhaustive]
pub enum Error {
Show 168 variants KafkaError(KafkaError), LocalIllegalArgument(LocalIllegalArgumentError), LocalIllegalState(LocalIllegalStateError), LocalConcurrentModification(LocalConcurrentModificationError), LocalTimeout(LocalTimeoutError), LocalUnsupportedOperation(LocalUnsupportedOperationError), LocalCallback(LocalCallbackError), Api(ApiError), Authentication(AuthenticationError), Authorization(AuthorizationError), AuthorizerNotReady(AuthorizerNotReadyError), BootstrapResolution(BootstrapResolutionError), BrokerIdNotRegistered(BrokerIdNotRegisteredError), BrokerNotAvailable(BrokerNotAvailableError), ProducerBufferExhausted(ProducerBufferExhaustedError), ClusterAuthorization(ClusterAuthorizationError), ConcurrentTransactions(ConcurrentTransactionsError), ControllerIdNotRegistered(ControllerIdNotRegisteredError), ControllerMoved(ControllerMovedError), CoordinatorLoadInProgress(CoordinatorLoadInProgressError), CoordinatorNotAvailable(CoordinatorNotAvailableError), CorrelationIdMismatch(CorrelationIdMismatchError), CorruptRecord(CorruptRecordError), DelegationTokenAuthorization(DelegationTokenAuthorizationError), DelegationTokenDisabled(DelegationTokenDisabledError), DelegationTokenExpired(DelegationTokenExpiredError), DelegationTokenNotFound(DelegationTokenNotFoundError), DelegationTokenOwnerMismatch(DelegationTokenOwnerMismatchError), Disconnect(DisconnectError), DuplicateBrokerRegistration(DuplicateBrokerRegistrationError), DuplicateResource(DuplicateResourceError), DuplicateSequence(DuplicateSequenceError), DuplicateVoter(DuplicateVoterError), ElectionNotNeeded(ElectionNotNeededError), EligibleLeadersNotAvailable(EligibleLeadersNotAvailableError), FeatureUpdateFailed(FeatureUpdateFailedError), FencedInstanceId(FencedInstanceIdError), FencedLeaderEpoch(FencedLeaderEpochError), FencedMemberEpoch(FencedMemberEpochError), FencedStateEpoch(FencedStateEpochError), FetchSessionIdNotFound(FetchSessionIdNotFoundError), FetchSessionTopicId(FetchSessionTopicIdError), GroupAuthorization(GroupAuthorizationError), GroupDeletionFailed(GroupDeletionFailedError), GroupIdNotFound(GroupIdNotFoundError), GroupMaxSizeReached(GroupMaxSizeReachedError), GroupNotEmpty(GroupNotEmptyError), GroupSubscribedToTopic(GroupSubscribedToTopicError), IllegalGeneration(IllegalGenerationError), IllegalSaslState(IllegalSaslStateError), InconsistentClusterId(InconsistentClusterIdError), InconsistentGroupProtocol(InconsistentGroupProtocolError), InconsistentTopicId(InconsistentTopicIdError), InconsistentVoterSet(InconsistentVoterSetError), IneligibleReplica(IneligibleReplicaError), Interrupt(InterruptError), InvalidCommitOffsetSize(InvalidCommitOffsetSizeError), InvalidConfiguration(InvalidConfigurationError), InvalidFetchSessionEpoch(InvalidFetchSessionEpochError), InvalidFetchSize(InvalidFetchSizeError), InvalidGroupId(InvalidGroupIdError), InvalidOffset(InvalidOffsetError), InvalidPartitions(InvalidPartitionsError), InvalidPidMapping(InvalidPidMappingError), InvalidPrincipalType(InvalidPrincipalTypeError), InvalidProducerEpoch(InvalidProducerEpochError), InvalidRecord(InvalidRecordError), InvalidRecordState(InvalidRecordStateError), InvalidRegistration(InvalidRegistrationError), InvalidRegularExpression(InvalidRegularExpression), InvalidReplicaAssignment(InvalidReplicaAssignmentError), InvalidReplicationFactor(InvalidReplicationFactorError), InvalidRequest(InvalidRequestError), InvalidRequiredAcks(InvalidRequiredAcksError), InvalidSessionTimeout(InvalidSessionTimeoutError), InvalidShareSessionEpoch(InvalidShareSessionEpochError), InvalidTimestamp(InvalidTimestampError), InvalidTopic(InvalidTopicError), InvalidTxnState(InvalidTxnStateError), InvalidTxnTimeout(InvalidTxnTimeoutError), InvalidUpdateVersion(InvalidUpdateVersionError), InvalidVoterKey(InvalidVoterKeyError), KafkaStorage(KafkaStorageError), LeaderNotAvailable(LeaderNotAvailableError), ListenerNotFound(ListenerNotFoundError), LogDirNotFound(LogDirNotFoundError), MemberIdRequired(MemberIdRequiredError), MismatchedEndpointType(MismatchedEndpointTypeError), Network(NetworkError), NewLeaderElected(NewLeaderElectedError), NoReassignmentInProgress(NoReassignmentInProgressError), NotController(NotControllerError), NotCoordinator(NotCoordinatorError), NotEnoughReplicas(NotEnoughReplicasError), NotEnoughReplicasAfterAppend(NotEnoughReplicasAfterAppendError), NotLeaderOrFollower(NotLeaderOrFollowerError), OffsetMetadataTooLarge(OffsetMetadataTooLarge), OffsetMovedToTieredStorage(OffsetMovedToTieredStorageError), OffsetNotAvailable(OffsetNotAvailableError), OffsetOutOfRange(OffsetOutOfRangeError), OperationNotAttempted(OperationNotAttemptedError), OutOfOrderSequence(OutOfOrderSequenceError), PolicyViolation(PolicyViolationError), PositionOutOfRange(PositionOutOfRangeError), PreferredLeaderNotAvailable(PreferredLeaderNotAvailableError), PrincipalDeserialization(PrincipalDeserializationError), ProducerFenced(ProducerFencedError), QuotaViolation(Box<QuotaViolationError>), ReassignmentInProgress(ReassignmentInProgressError), RebalanceInProgress(RebalanceInProgressError), RebootstrapRequired(RebootstrapRequiredError), RecordBatchTooLarge(RecordBatchTooLargeError), RecordDeserialization(Box<RecordDeserializationError>), RecordTooLarge(RecordTooLargeError), InvalidReceive(InvalidReceiveError), Config(ConfigError), ConsumerRetriableCommitFailed(ConsumerRetriableCommitFailedError), ConsumerCommitFailed(ConsumerCommitFailedError), ConsumerNoOffsetForPartition(ConsumerNoOffsetForPartitionError), ConsumerOffsetOutOfRange(ConsumerOffsetOutOfRangeError), ConsumerLogTruncation(Box<ConsumerLogTruncationError>), ReplicaNotAvailable(ReplicaNotAvailableError), ResourceNotFound(ResourceNotFoundError), SaslAuthentication(SaslAuthenticationError), Schema(SchemaError), SecurityDisabled(SecurityDisabledError), Serialization(SerializationError), ShareSessionLimitReached(ShareSessionLimitReachedError), ShareSessionNotFound(ShareSessionNotFoundError), SnapshotNotFound(SnapshotNotFoundError), SslAuthentication(SslAuthenticationError), StaleBrokerEpoch(StaleBrokerEpochError), StaleMemberEpoch(StaleMemberEpochError), StreamsInvalidTopology(StreamsInvalidTopologyError), StreamsInvalidTopologyEpoch(StreamsInvalidTopologyEpochError), StreamsTopologyDescriptionUpdateFailed(StreamsTopologyDescriptionUpdateFailedError), StreamsTopologyFenced(StreamsTopologyFencedError), TelemetryTooLarge(TelemetryTooLargeError), ThrottlingQuotaExceeded(ThrottlingQuotaExceededError), Timeout(TimeoutError), TopicAuthorization(TopicAuthorizationError), TopicDeletionDisabled(TopicDeletionDisabledError), TopicExists(TopicExistsError), TransactionAbortable(TransactionAbortableError), TransactionAborted(TransactionAbortedError), TransactionCoordinatorFenced(TransactionCoordinatorFencedError), TransactionalIdAuthorization(TransactionalIdAuthorizationError), TransactionalIdNotFound(TransactionalIdNotFoundError), UnacceptableCredential(UnacceptableCredentialError), UnknownControllerId(UnknownControllerIdError), UnknownLeaderEpoch(UnknownLeaderEpochError), UnknownMemberId(UnknownMemberIdError), UnknownProducerId(UnknownProducerIdError), UnknownServer(UnknownServerError), UnknownSubscriptionId(UnknownSubscriptionIdError), UnknownTopicId(UnknownTopicIdError), UnknownTopicOrPartition(UnknownTopicOrPartitionError), UnreleasedInstanceId(UnreleasedInstanceIdError), UnstableOffsetCommit(UnstableOffsetCommitError), UnsupportedAssignor(UnsupportedAssignorError), UnsupportedByAuthentication(UnsupportedByAuthenticationError), UnsupportedCompressionType(UnsupportedCompressionTypeError), UnsupportedEndpointType(UnsupportedEndpointTypeError), UnsupportedForMessageFormat(UnsupportedForMessageFormatError), UnsupportedSaslMechanism(UnsupportedSaslMechanismError), UnsupportedVersion(UnsupportedVersionError), VoterNotFound(VoterNotFoundError), Wakeup(WakeupError),
}
Expand description

Unified error type for polymorphic error handling — this crate’s top-level error, returned by every fallible API.

This enum wraps the error struct hierarchy so that any error can be stored and returned through a single type. Most variants hold a specific error struct that embeds KafkaError as its base; KafkaError holds a bare one, standing for Java’s KafkaException with no subclass.

It also carries the generic programming errors that Java keeps OUTSIDE the KafkaException hierarchy (LocalIllegalArgument, LocalIllegalState, LocalConcurrentModification); flattening two Java families into one enum is what makes is_kafka_error necessary.

Classify by predicate, not by variant or code. Java callers write e instanceof TopicAuthorizationException; Rust callers write e.is_topic_authorization_error(). Every variant has such a predicate, and every intermediate Java class has one too. Prefer them to matches!(e, Error::TopicAuthorization(_)). A predicate means “this class or a subclass”, like instanceof, so it still matches a subclass a later Java release adds, whereas a variant match would miss it. There is no public numeric error code: the wire-level Errors enum lives in common.protocol, a package Java marks “not a supported API”, so the crate keeps it pub(crate). The C bindings expose the class as the kafka_common_Error_e enum instead.

message() and is_retriable_error() are delegated to the inner KafkaError base. request_utils::RequestUtils::is_fatal_error and is_transaction_abortable_error() live only here: KafkaError is Java’s KafkaException, which has neither, so these librdkafka-style predicates belong on this enum rather than on the Java-shaped base.

This type is used in Result return types and Option storage where any kind of Kafka error may occur.

Variants (Non-exhaustive)§

This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
§

KafkaError(KafkaError)

A plain Kafka error carrying only the base fields — Java’s bare KafkaException, with no subclass-specific context.

§

LocalIllegalArgument(LocalIllegalArgumentError)

Illegal argument error — an invalid argument was provided to a method.

Java’s IllegalArgumentException.

§

LocalIllegalState(LocalIllegalStateError)

Illegal state error — a method was called in an invalid state.

Java’s IllegalStateException.

§

LocalConcurrentModification(LocalConcurrentModificationError)

Concurrent modification error — the consumer was accessed from more than one thread.

Java’s java.util.ConcurrentModificationException, thrown by KafkaConsumer.acquire() (“KafkaConsumer is not safe for multi-threaded access”). Like LocalIllegalState, it is a plain RuntimeException — neither an ApiException nor a KafkaException — so it is never retriable and never fatal.

§

LocalTimeout(LocalTimeoutError)

A wait on a future timed out.

Java’s java.util.concurrent.TimeoutException raised by Future.get(timeout, unit). Distinct from Timeout, which is org.apache.kafka.common.errors.TimeoutException — a RetriableException. This one sits beside KafkaException, so it is never retriable, never an api error and carries no wire code.

§

LocalUnsupportedOperation(LocalUnsupportedOperationError)

Unsupported operation error — the requested operation is not supported.

Java’s java.lang.UnsupportedOperationException, thrown where Java leaves an operation unimplemented (MockAdminClient’s “Not implemented yet” methods, MockConsumer.offsetsForTimes) or rejects it (Compression.decompressionOutputSize). Like LocalIllegalState it is a plain RuntimeException — neither an ApiException nor a KafkaException — so it is never retriable and never fatal. Distinct from UnsupportedVersion, the wire-level ApiException for a broker lacking an API version.

§

LocalCallback(LocalCallbackError)

An error raised by a callback written in another language.

No Java class: it stands in for the foreign error, which cannot cross the FFI boundary, and carries an opaque pointer the binding uses to find the original again. Outside the Kafka hierarchy, like LocalIllegalState, so the client wraps it as Java wraps a listener’s foreign Throwable.

§

Api(ApiError)

See ApiError.

§

Authentication(AuthenticationError)

§

Authorization(AuthorizationError)

§

AuthorizerNotReady(AuthorizerNotReadyError)

§

BootstrapResolution(BootstrapResolutionError)

§

BrokerIdNotRegistered(BrokerIdNotRegisteredError)

§

BrokerNotAvailable(BrokerNotAvailableError)

§

ProducerBufferExhausted(ProducerBufferExhaustedError)

§

ClusterAuthorization(ClusterAuthorizationError)

§

ConcurrentTransactions(ConcurrentTransactionsError)

§

ControllerIdNotRegistered(ControllerIdNotRegisteredError)

§

ControllerMoved(ControllerMovedError)

§

CoordinatorLoadInProgress(CoordinatorLoadInProgressError)

§

CoordinatorNotAvailable(CoordinatorNotAvailableError)

§

CorrelationIdMismatch(CorrelationIdMismatchError)

See CorrelationIdMismatchError.

Lives in common.requests, not common.errors, and extends IllegalStateException rather than KafkaException — so like LocalIllegalState it answers false to every predicate.

§

CorruptRecord(CorruptRecordError)

§

DelegationTokenAuthorization(DelegationTokenAuthorizationError)

§

DelegationTokenDisabled(DelegationTokenDisabledError)

§

DelegationTokenExpired(DelegationTokenExpiredError)

§

DelegationTokenNotFound(DelegationTokenNotFoundError)

§

DelegationTokenOwnerMismatch(DelegationTokenOwnerMismatchError)

§

Disconnect(DisconnectError)

§

DuplicateBrokerRegistration(DuplicateBrokerRegistrationError)

§

DuplicateResource(DuplicateResourceError)

§

DuplicateSequence(DuplicateSequenceError)

§

DuplicateVoter(DuplicateVoterError)

§

ElectionNotNeeded(ElectionNotNeededError)

§

EligibleLeadersNotAvailable(EligibleLeadersNotAvailableError)

§

FeatureUpdateFailed(FeatureUpdateFailedError)

§

FencedInstanceId(FencedInstanceIdError)

§

FencedLeaderEpoch(FencedLeaderEpochError)

§

FencedMemberEpoch(FencedMemberEpochError)

§

FencedStateEpoch(FencedStateEpochError)

§

FetchSessionIdNotFound(FetchSessionIdNotFoundError)

§

FetchSessionTopicId(FetchSessionTopicIdError)

§

GroupAuthorization(GroupAuthorizationError)

§

GroupDeletionFailed(GroupDeletionFailedError)

§

GroupIdNotFound(GroupIdNotFoundError)

§

GroupMaxSizeReached(GroupMaxSizeReachedError)

§

GroupNotEmpty(GroupNotEmptyError)

§

GroupSubscribedToTopic(GroupSubscribedToTopicError)

§

IllegalGeneration(IllegalGenerationError)

§

IllegalSaslState(IllegalSaslStateError)

§

InconsistentClusterId(InconsistentClusterIdError)

§

InconsistentGroupProtocol(InconsistentGroupProtocolError)

§

InconsistentTopicId(InconsistentTopicIdError)

§

InconsistentVoterSet(InconsistentVoterSetError)

§

IneligibleReplica(IneligibleReplicaError)

§

Interrupt(InterruptError)

§

InvalidCommitOffsetSize(InvalidCommitOffsetSizeError)

§

InvalidConfiguration(InvalidConfigurationError)

§

InvalidFetchSessionEpoch(InvalidFetchSessionEpochError)

§

InvalidFetchSize(InvalidFetchSizeError)

§

InvalidGroupId(InvalidGroupIdError)

§

InvalidOffset(InvalidOffsetError)

§

InvalidPartitions(InvalidPartitionsError)

§

InvalidPidMapping(InvalidPidMappingError)

§

InvalidPrincipalType(InvalidPrincipalTypeError)

§

InvalidProducerEpoch(InvalidProducerEpochError)

§

InvalidRecord(InvalidRecordError)

§

InvalidRecordState(InvalidRecordStateError)

§

InvalidRegistration(InvalidRegistrationError)

§

InvalidRegularExpression(InvalidRegularExpression)

§

InvalidReplicaAssignment(InvalidReplicaAssignmentError)

§

InvalidReplicationFactor(InvalidReplicationFactorError)

§

InvalidRequest(InvalidRequestError)

§

InvalidRequiredAcks(InvalidRequiredAcksError)

§

InvalidSessionTimeout(InvalidSessionTimeoutError)

§

InvalidShareSessionEpoch(InvalidShareSessionEpochError)

§

InvalidTimestamp(InvalidTimestampError)

§

InvalidTopic(InvalidTopicError)

§

InvalidTxnState(InvalidTxnStateError)

§

InvalidTxnTimeout(InvalidTxnTimeoutError)

§

InvalidUpdateVersion(InvalidUpdateVersionError)

§

InvalidVoterKey(InvalidVoterKeyError)

§

KafkaStorage(KafkaStorageError)

§

LeaderNotAvailable(LeaderNotAvailableError)

§

ListenerNotFound(ListenerNotFoundError)

§

LogDirNotFound(LogDirNotFoundError)

§

MemberIdRequired(MemberIdRequiredError)

§

MismatchedEndpointType(MismatchedEndpointTypeError)

§

Network(NetworkError)

§

NewLeaderElected(NewLeaderElectedError)

§

NoReassignmentInProgress(NoReassignmentInProgressError)

§

NotController(NotControllerError)

§

NotCoordinator(NotCoordinatorError)

§

NotEnoughReplicas(NotEnoughReplicasError)

§

NotEnoughReplicasAfterAppend(NotEnoughReplicasAfterAppendError)

§

NotLeaderOrFollower(NotLeaderOrFollowerError)

§

OffsetMetadataTooLarge(OffsetMetadataTooLarge)

§

OffsetMovedToTieredStorage(OffsetMovedToTieredStorageError)

§

OffsetNotAvailable(OffsetNotAvailableError)

§

OffsetOutOfRange(OffsetOutOfRangeError)

§

OperationNotAttempted(OperationNotAttemptedError)

§

OutOfOrderSequence(OutOfOrderSequenceError)

§

PolicyViolation(PolicyViolationError)

§

PositionOutOfRange(PositionOutOfRangeError)

§

PreferredLeaderNotAvailable(PreferredLeaderNotAvailableError)

§

PrincipalDeserialization(PrincipalDeserializationError)

§

ProducerFenced(ProducerFencedError)

§

QuotaViolation(Box<QuotaViolationError>)

See QuotaViolationError.

Boxed for the same reason as RecordDeserialization: it carries a whole MetricName (three Strings and a BTreeMap), which unboxed makes it the largest payload in the enum at 120 bytes and pushes Error — and with it every Result<_, Error> in the crate — past clippy’s 128-byte result_large_err threshold.

§

ReassignmentInProgress(ReassignmentInProgressError)

§

RebalanceInProgress(RebalanceInProgressError)

§

RebootstrapRequired(RebootstrapRequiredError)

§

RecordBatchTooLarge(RecordBatchTooLargeError)

§

RecordDeserialization(Box<RecordDeserializationError>)

See RecordDeserializationError.

Boxed: it carries the full record context (partition, offsets, key/value buffers, headers), which unboxed pushes Error — and every Result<_, Error> — past clippy’s 128-byte result_large_err threshold.

§

RecordTooLarge(RecordTooLargeError)

§

InvalidReceive(InvalidReceiveError)

See InvalidReceiveError.

§

Config(ConfigError)

§

ConsumerRetriableCommitFailed(ConsumerRetriableCommitFailedError)

§

ConsumerCommitFailed(ConsumerCommitFailedError)

§

ConsumerNoOffsetForPartition(ConsumerNoOffsetForPartitionError)

§

ConsumerOffsetOutOfRange(ConsumerOffsetOutOfRangeError)

§

ConsumerLogTruncation(Box<ConsumerLogTruncationError>)

See ConsumerLogTruncationError.

Boxed: it carries two maps, and unboxed it made Error — and therefore every Result<_, Error> in the crate — exceed 128 bytes.

§

ReplicaNotAvailable(ReplicaNotAvailableError)

§

ResourceNotFound(ResourceNotFoundError)

§

SaslAuthentication(SaslAuthenticationError)

§

Schema(SchemaError)

See SchemaError.

Lives in common.protocol.types, not common.errors.

§

SecurityDisabled(SecurityDisabledError)

§

Serialization(SerializationError)

§

ShareSessionLimitReached(ShareSessionLimitReachedError)

§

ShareSessionNotFound(ShareSessionNotFoundError)

§

SnapshotNotFound(SnapshotNotFoundError)

§

SslAuthentication(SslAuthenticationError)

§

StaleBrokerEpoch(StaleBrokerEpochError)

§

StaleMemberEpoch(StaleMemberEpochError)

§

StreamsInvalidTopology(StreamsInvalidTopologyError)

§

StreamsInvalidTopologyEpoch(StreamsInvalidTopologyEpochError)

§

StreamsTopologyDescriptionUpdateFailed(StreamsTopologyDescriptionUpdateFailedError)

§

StreamsTopologyFenced(StreamsTopologyFencedError)

§

TelemetryTooLarge(TelemetryTooLargeError)

§

ThrottlingQuotaExceeded(ThrottlingQuotaExceededError)

§

Timeout(TimeoutError)

§

TopicAuthorization(TopicAuthorizationError)

§

TopicDeletionDisabled(TopicDeletionDisabledError)

§

TopicExists(TopicExistsError)

§

TransactionAbortable(TransactionAbortableError)

§

TransactionAborted(TransactionAbortedError)

§

TransactionCoordinatorFenced(TransactionCoordinatorFencedError)

§

TransactionalIdAuthorization(TransactionalIdAuthorizationError)

§

TransactionalIdNotFound(TransactionalIdNotFoundError)

§

UnacceptableCredential(UnacceptableCredentialError)

§

UnknownControllerId(UnknownControllerIdError)

§

UnknownLeaderEpoch(UnknownLeaderEpochError)

§

UnknownMemberId(UnknownMemberIdError)

§

UnknownProducerId(UnknownProducerIdError)

§

UnknownServer(UnknownServerError)

§

UnknownSubscriptionId(UnknownSubscriptionIdError)

§

UnknownTopicId(UnknownTopicIdError)

§

UnknownTopicOrPartition(UnknownTopicOrPartitionError)

§

UnreleasedInstanceId(UnreleasedInstanceIdError)

§

UnstableOffsetCommit(UnstableOffsetCommitError)

§

UnsupportedAssignor(UnsupportedAssignorError)

§

UnsupportedByAuthentication(UnsupportedByAuthenticationError)

§

UnsupportedCompressionType(UnsupportedCompressionTypeError)

§

UnsupportedEndpointType(UnsupportedEndpointTypeError)

§

UnsupportedForMessageFormat(UnsupportedForMessageFormatError)

§

UnsupportedSaslMechanism(UnsupportedSaslMechanismError)

§

UnsupportedVersion(UnsupportedVersionError)

§

VoterNotFound(VoterNotFoundError)

§

Wakeup(WakeupError)

Implementations§

Source§

impl Error

Source

pub fn kafka() -> Self

Creates a bare Kafka error with no message, Java’s no-arg new KafkaException().

The four kafka* constructors translate KafkaException’s four constructors. Their parameter-name intersection is empty and the no-arg form matches it, so this one keeps the plain name and the others are suffixed with their parameters.

This is deliberately NOT new with Errors::UnknownServerError: that constructor resolves the code to the class Java associates with it and yields UnknownServer, an ApiException. Java’s bare KafkaException is a sibling of ApiException, not a subclass, so it belongs in the KafkaError variant. The difference is observable: is_api_error answers false here and true there, and callers such as KafkaProducer.doSend dispatch on exactly that (catch (ApiException e) returns a failed future, catch (KafkaException e) rethrows).

The wire code stays Errors::UnknownServerError because a client-constructed KafkaException has no protocol code of its own.

Java’s no-arg form leaves the message null; Rust reports the code’s default message instead, since KafkaError stores the code rather than deriving it from a subclass and always has one to fall back on.

Source

pub fn kafka_message(message: impl Into<String>) -> Self

Creates a bare Kafka error, Java’s new KafkaException(String message).

See kafka for why this does not go through with_message.

§Arguments
  • message - the error message
Source

pub fn kafka_source(source: Error) -> Self

Creates a bare Kafka error carrying only the error that caused it, Java’s new KafkaException(Throwable cause).

See kafka for why this does not go through with_message.

§Arguments
  • source - the error that caused this one, returned by source
Source

pub fn kafka_message_source(message: impl Into<String>, source: Error) -> Self

Creates a bare Kafka error carrying the error that caused it, Java’s new KafkaException(String message, Throwable cause).

See kafka for why this does not go through with_message.

§Arguments
  • message - the error message
  • source - the error that caused this one, returned by source
Source

pub fn topic_authorization(topics: HashSet<String>) -> Self

Creates a topic authorization error, Java’s new TopicAuthorizationException(unauthorizedTopics).

The pair intersects on {unauthorizedTopics}, which is exactly this overload, so it keeps the plain name.

§Arguments
  • topics - the topics the client is not authorized to access
Source

pub fn topic_authorization_message( topics: HashSet<String>, message: impl Into<String>, ) -> Self

Creates a topic authorization error carrying a custom message, Java’s new TopicAuthorizationException(message, unauthorizedTopics).

§Arguments
  • topics - the topics the client is not authorized to access
  • message - the error message
Source

pub fn invalid_topics(topics: HashSet<String>) -> Self

Creates an invalid topic error, Java’s new InvalidTopicException(invalidTopics).

The pair intersects on {invalidTopics}, which is exactly this overload, so it keeps the plain name.

§Arguments
  • topics - the invalid topic names
Source

pub fn invalid_topics_message( topics: HashSet<String>, message: impl Into<String>, ) -> Self

Creates an invalid topic error carrying a custom message, Java’s new InvalidTopicException(message, invalidTopics), and the new InvalidTopicException(String message) form when topics is empty.

§Arguments
  • topics - the invalid topic names, possibly empty
  • message - the error message
Source

pub fn group_authorization(group_id: impl Into<String>) -> Self

Creates a group authorization error for a group ID, formatting the group into the message, Java’s GroupAuthorizationException.forGroupId(groupId).

§Arguments
  • group_id - the group the client is not authorized to access
Source

pub fn group_authorization_with_message( group_id: impl Into<String>, message: impl Into<String>, ) -> Self

Creates a group authorization error carrying a custom message, Java’s new GroupAuthorizationException(message, groupId).

§Arguments
  • group_id - the group the client is not authorized to access
  • message - the error message
Source

pub fn invalid_group_id(message: impl Into<String>) -> Self

Creates an invalid group ID error, Java’s InvalidGroupIdException (an ApiException carrying the code Errors::InvalidGroupId).

Returned by group-management and offset-commit APIs when the consumer was constructed without a valid group.id.

§Arguments
  • message - the error message
Source

pub fn throttling_quota_exceeded( throttle_time_ms: i32, message: impl Into<String>, ) -> Self

Creates a throttling quota exceeded error, Java’s ThrottlingQuotaExceededException(int, String).

§Arguments
  • throttle_time_ms - how long, in milliseconds, the client is throttled
  • message - the error message
Source

pub fn throttle_time_ms(&self) -> Option<i32>

Returns the throttle time carried by a ThrottlingQuotaExceeded error, Java’s ThrottlingQuotaExceededException.throttleTimeMs(), or None for any other error.

Source

pub fn buffer_exhausted(message: impl Into<String>) -> Self

Creates a buffer exhausted error, Java’s BufferExhaustedException.

§Arguments
  • message - the error message
Source

pub fn local_illegal_argument(message: impl Into<String>) -> Self

Creates an illegal argument error, Java’s IllegalArgumentException.

§Arguments
  • message - the error message
Source

pub fn config_message(message: impl Into<String>) -> Self

Creates a configuration error, Java’s ConfigException(message): an invalid config value.

Unlike local_illegal_argument this is inside the KafkaException hierarchy, so is_kafka_error is true for it.

§Arguments
  • message - the error message
Source

pub fn config_name_value(name: impl Display, value: impl Display) -> Self

Creates a configuration error naming the offending value and key, in Java’s ConfigException(name, value) format.

§Arguments
  • name - the name of the configuration
  • value - the value of the configuration
Source

pub fn config_name_value_message( name: impl Display, value: impl Display, message: impl Display, ) -> Self

Creates a configuration error naming the value, key, and a detail message, in Java’s ConfigException(name, value, message) format.

§Arguments
  • name - the name of the configuration
  • value - the value of the configuration
  • message - why the value is invalid
Source

pub fn local_illegal_state(message: impl Into<String>) -> Self

Creates an illegal state error, Java’s IllegalStateException.

§Arguments
  • message - the error message
Source

pub fn local_unsupported_operation(message: impl Into<String>) -> Self

Creates an unsupported operation error, Java’s java.lang.UnsupportedOperationException.

Use Error::unsupported_version instead for org.apache.kafka.common.errors.UnsupportedVersionException, the wire-level class for an API version the broker does not support.

§Arguments
  • message - the error message
Source

pub fn timeout(message: impl Into<String>) -> Self

Creates a timeout error, Java’s org.apache.kafka.common.errors.TimeoutException.

§Arguments
  • message - the error message
Source

pub fn record_too_large(message: impl Into<String>) -> Self

Creates a record too large error, Java’s RecordTooLargeException.

§Arguments
  • message - the error message
Source

pub fn correlation_id_mismatch( message: impl Into<String>, request_correlation_id: i32, response_correlation_id: i32, ) -> Self

Creates a correlation-id mismatch error, Java’s CorrelationIdMismatchException(String, int, int): an IllegalStateException, so outside the KafkaException hierarchy.

§Arguments
  • message - the error message
  • request_correlation_id - the correlation id of the request sent
  • response_correlation_id - the correlation id the response carried
Source

pub fn invalid_receive(message: impl Into<String>) -> Self

Creates an invalid-receive error, Java’s InvalidReceiveException(String).

The class is not public API (common.network), so this constructor is how code outside the crate, such as a test backend decoding an error sent over the wire, builds the variant.

§Arguments
  • message - the error message
Source

pub fn schema(message: impl Into<String>) -> Self

Creates a protocol-schema error, Java’s SchemaException(String).

§Arguments
  • message - the error message
Source

pub fn schema_source(message: impl Into<String>, source: Error) -> Self

Creates a protocol-schema error carrying the failure that caused it, Java’s SchemaException(String, Throwable), used by NetworkClient.parseResponse to wrap a buffer underflow.

The pair intersects on {message}, which is exactly schema, so that one keeps the plain name and this is suffixed with the parameter beyond it.

§Arguments
  • message - the error message
  • source - the error that caused this one, returned by source
Source

pub fn serialization(message: impl Into<String>) -> Self

Creates a serialization error, Java’s SerializationException.

§Arguments
  • message - the error message
Source

pub fn unsupported_version(message: impl Into<String>) -> Self

Creates an unsupported version error, Java’s UnsupportedVersionException.

§Arguments
  • message - the error message
Source

pub fn wakeup(message: impl Into<String>) -> Self

Creates a wakeup error, Java’s WakeupException.

Returned from blocking Consumer operations (poll, commit_sync, position, etc.) when wakeup() is invoked from another task.

§Arguments
  • message - the error message
Source

pub fn local_concurrent_modification(message: impl Into<String>) -> Self

Creates a concurrent modification error, Java’s ConcurrentModificationException, which KafkaConsumer.acquire() throws when the consumer is accessed from more than one thread.

§Arguments
  • message - the error message
Source

pub fn local_timeout(message: impl Into<String>) -> Self

Creates a timed-out-waiting-on-a-future error, Java’s java.util.concurrent.TimeoutException from Future.get(timeout, unit).

Use Error::timeout instead for org.apache.kafka.common.errors.TimeoutException, the retriable Kafka class the broker reports.

§Arguments
  • message - the error message
Source

pub fn local_callback(message: impl Into<String>, opaque: *mut c_void) -> Self

Creates the error a callback written in another language reports when it raised one of that language’s errors. See LocalCallbackError.

§Arguments
  • message - the foreign error’s text, for the client’s logs
  • opaque - the binding’s pointer to the foreign error, never dereferenced by Rust and not owned by the error
Source

pub fn transaction_aborted() -> Self

Creates a transaction aborted error with Java’s default message, Java’s no-arg TransactionAbortedException(), whose message is "Failing batch since transaction was aborted".

The pair’s parameter-name intersection is empty and this overload matches it, so it keeps the plain name.

Source

pub fn transaction_aborted_message(message: impl Into<String>) -> Self

Creates a transaction aborted error with a custom message, Java’s TransactionAbortedException(String).

§Arguments
  • message - the error message
Source

pub fn record_batch_too_large(message: impl Into<String>) -> Self

Creates a record batch too large error, Java’s RecordBatchTooLargeException.

§Arguments
  • message - the error message
Source

pub fn kafka_error(&self) -> Option<&KafkaError>

Returns the base KafkaError common to all variants, or None for variants that do not carry one (e.g. LocalIllegalArgument, LocalIllegalState).

Source

pub fn message(&self) -> &str

Returns the error message, Java’s Throwable.getMessage().

A message-only error returns the text it was constructed with, and a payload wrapping a KafkaError returns its custom message if set, otherwise the default text for its error code.

This is NOT what to_string() produces. std::fmt::Display translates Throwable.toString(), which Java renders as getClass().getName() + ": " + getLocalizedMessage(), so Display carries a class-name prefix and, for some payloads, extra subclass state. Use this method for log fields and equality assertions; use Display when rendering the error to a human.

Source

pub fn source(&self) -> Option<&Error>

Returns the error that caused this one, Java’s Throwable.getCause(), or None when there is none.

getCause() lives on Throwable, so every error can carry a cause: this answers for all of them. None is the common case, as Java’s null default.

std::error::Error::source returns the same value, so the standard library’s chain-walking works on any Error.

Source

pub fn is_kafka_error(&self) -> bool

Returns whether this is a Kafka error rather than a generic programming error.

This enum flattens two families that Java keeps apart by class hierarchy: Kafka’s own KafkaException tree, and the generic java.lang / java.util runtime exceptions that sit beside it as siblings rather than below it (KafkaException extends RuntimeException). This predicate recovers that distinction, mirroring Java’s t instanceof KafkaException.

Returns false for exactly the generic variants — the ones raised by misuse of the client rather than by Kafka itself: LocalIllegalArgument, LocalIllegalState, LocalConcurrentModification, LocalTimeout and LocalUnsupportedOperation, plus LocalCallback, a foreign callback’s error, which the client wraps as Java wraps a listener’s foreign Throwable.

Everything else returns true: the ApiException subtypes, Serialization, Wakeup and the bare KafkaError all map to KafkaException subclasses.

This is not a test for the KafkaError variant. That variant means “a bare KafkaException, no subclass”; this asks “inside the KafkaException hierarchy at all”, which is true of Timeout, TopicAuthorization and most other variants too. Java has no instanceof test for “a bare KafkaException and no subclass” either.

Beware the polarity difference against is_api_error: both return true for the in-hierarchy case, but they are not the same test — Serialization and Wakeup are Kafka errors that are NOT ApiExceptions, so they return true here and false there.

Two call sites depend on this: org.apache.kafka.clients.consumer.internals.ConsumerUtils#maybeWrapAsKafkaException — a Kafka error passes through unchanged, a generic one gets wrapped in a new KafkaException(message, t) — and FetchCollector, whose Java catch (KafkaException e) cannot catch a generic error, so those propagate where Kafka errors are swallowed.

Source

pub fn is_api_error(&self) -> bool

Returns whether this error’s Java class is ApiException or extends it.

In Java, ApiException is a subclass of KafkaException representing errors from the Kafka API. In KafkaProducer.doSend(), ApiExceptions are caught and returned via a failed future (with callback invocation), while other exceptions propagate directly.

true for every payload whose extends: list names is_api_error — which is every class carrying a protocol code, since Errors.java only names ApiException subclasses, plus the code-less concrete bases Api, Authentication and Authorization. Examples: InvalidTopic, RecordTooLarge, Timeout, TopicAuthorization, GroupAuthorization, ThrottlingQuotaExceeded and ProducerBufferExhausted.

false for the bare KafkaError — KafkaException is ApiException’s parent, not an instance of it, and since Error::new resolves every code to its own class that variant is now reached only for Errors::None and for Error::kafka. Also false for LocalIllegalArgument and LocalIllegalState (plain RuntimeExceptions), LocalConcurrentModification, and for Serialization / Wakeup, which extend KafkaException directly without passing through ApiException.

Not to be confused with is_kafka_error, which asks the broader question.

Source

pub fn is_retriable_error(&self) -> bool

Returns whether this error’s Java class extends RetriableException — i.e. whether re-sending the failed request can succeed.

The answer belongs to the payload, not to the enum: each error class names is_retriable_error in its extends: list, so the covered set is exactly the classes whose Java ancestry passes through RetriableException — directly, or via RefreshRetriableException, InvalidMetadataException or TimeoutException. Timeout is retriable (Java’s TimeoutException extends RetriableException), as are ThrottlingQuotaExceeded and ProducerBufferExhausted (through BufferExhaustedException extends TimeoutException).

Since Error::new resolves every code to its own class, the set of codes answering true is pinned in both directions — against the Java extends chain, over every code — by errors.rs’s test_retriable_errors_match_java_hierarchy.

The bare KafkaError answers false (KafkaException is not a RetriableException), and so do LocalIllegalArgument and LocalIllegalState.

Source

pub fn is_refresh_retriable_error(&self) -> bool

Returns whether this error’s Java class extends RefreshRetriableException — retriable, and a metadata / coordinator refresh is what clears it.

Fifteen payloads name it in their extends: list: the thirteen that also answer is_invalid_metadata_error (InvalidMetadataException extends RefreshRetriableException), plus CoordinatorNotAvailable and NotCoordinator. All fifteen carry a protocol code, so the set is pinned in both directions over every code by errors.rs’s test_hierarchy_predicates_match_java.

The bare KafkaError answers false, as do the payloads carrying no protocol code.

Source

pub fn is_timeout_error(&self) -> bool

Returns whether this error’s Java class extends TimeoutException.

Wider than the Timeout variant: BufferExhaustedException extends TimeoutException, so ProducerBufferExhausted answers true here too — matching Java, where catch (TimeoutException e) catches a buffer-pool exhaustion. To exclude that case, as a Java caller would with a preceding catch (BufferExhaustedException e), also test is_producer_buffer_exhausted_error.

Nested inside is_retriable_error.

Source

pub fn is_invalid_metadata_error(&self) -> bool

Returns whether this error’s Java class extends InvalidMetadataException — the client’s cached metadata may be stale.

Nested inside is_refresh_retriable_error, which is nested inside is_retriable_error. Thirteen payloads name it, all of them code-carrying; the set is pinned in both directions over every code by errors.rs’s test_hierarchy_predicates_match_java.

Source

pub fn is_invalid_configuration_error(&self) -> bool

Returns whether this error’s Java class extends InvalidConfigurationException.

Wider than its name suggests: in Kafka 4.2 both AuthenticationException and AuthorizationException extend InvalidConfigurationException rather than ApiException directly, so every error answering true to is_authentication_error or is_authorization_error answers true here too. The remaining members are the configuration errors proper — Errors::InvalidConfig, Errors::InvalidReplicationFactor, Errors::InvalidRequiredAcks, Errors::InvalidTopicError, Errors::RecordListTooLarge, Errors::UnsupportedForMessageFormat and Errors::UnsupportedVersion.

Source

pub fn is_application_recoverable_error(&self) -> bool

Returns whether this error’s Java class extends ApplicationRecoverableException — the application can recover, but only by re-initialising its producer or rejoining its group; the current epoch or session is gone.

6 codes, covering the transaction and group-membership fencing paths: Errors::FencedInstanceId, Errors::IllegalGeneration, Errors::InvalidProducerEpoch, Errors::InvalidProducerIdMapping, Errors::ProducerFenced and Errors::UnknownMemberId.

Source

pub fn is_invalid_offset_error(&self) -> bool

Returns whether this error’s Java class extends InvalidOffsetException.

Errors::OffsetOutOfRange is the only member carrying a protocol code; the sibling NoOffsetForPartitionException is raised client-side.

Source

pub fn is_out_of_order_sequence_error(&self) -> bool

Returns whether this error’s Java class extends OutOfOrderSequenceException.

Two codes: Errors::OutOfOrderSequenceNumber itself and Errors::UnknownProducerId, its only subclass.

Source

pub fn is_consumer_invalid_offset_error(&self) -> bool

Returns whether this error’s Java class extends org.apache.kafka.clients.consumer.InvalidOffsetException — no offset is usable for the partition.

Covers ConsumerNoOffsetForPartition, ConsumerOffsetOutOfRange and ConsumerLogTruncation — the Consumer prefix marks the clients.consumer package’s classes, so it is part of the variant name.

Distinct from is_invalid_offset_error, which tests common.errors.InvalidOffsetException — a different Java class with a different parent (ApiException rather than KafkaException). The wire code OFFSET_OUT_OF_RANGE produces that one; KafkaConsumer::poll raises these.

Source

pub fn is_consumer_offset_out_of_range_error(&self) -> bool

Returns whether this error’s Java class extends org.apache.kafka.clients.consumer.OffsetOutOfRangeException.

Wider than the ConsumerOffsetOutOfRange variant: LogTruncationException extends that class, so ConsumerLogTruncation answers true too — matching Java, where catch (OffsetOutOfRangeException e) catches a log truncation.

Nested inside is_consumer_invalid_offset_error. Distinct from is_invalid_offset_error, which tests the common.errors class of the same name.

Source

pub fn is_serialization_error(&self) -> bool

Returns whether this error’s Java class extends SerializationException.

No protocol code maps here — SerializationException and its subclass RecordDeserializationException are raised client-side — so only Serialization answers true. Note it is a KafkaException but NOT an ApiException, so is_api_error is false for it.

Source

pub fn is_authentication_error(&self) -> bool

Returns whether this error’s Java class extends AuthenticationException.

Five payloads name it in their extends: list: Authentication — the concrete base class, which has no entry in Errors of its own but inherits Errors::InvalidConfig from InvalidConfigurationException — plus SaslAuthentication, SslAuthentication, IllegalSaslState and UnsupportedSaslMechanism. Three of them carry a code (SASL_AUTHENTICATION_FAILED, ILLEGAL_SASL_STATE, UNSUPPORTED_SASL_MECHANISM) and that code set is pinned in both directions over every code by errors.rs’s test_hierarchy_predicates_match_java.

A handshake failure detected locally is carried inside an io::Error (common::network::authentication_io_error) as the class it was raised as — SaslAuthentication for rejected credentials, SslAuthentication for a rejected certificate — and reaches the application, and the producer’s transaction manager, unchanged; each answers true here, and so to request_utils::RequestUtils::is_fatal_error.

Nested inside is_invalid_configuration_error.

Source

pub fn is_authorization_error(&self) -> bool

Returns whether this error’s Java class extends AuthorizationException.

Six payloads name it in their extends: list: Authorization — the concrete base class, which has no entry in Errors of its own but inherits Errors::InvalidConfig from InvalidConfigurationException — plus the five that do carry one, TopicAuthorization, GroupAuthorization, ClusterAuthorization, TransactionalIdAuthorization and DelegationTokenAuthorization. Those five codes are pinned in both directions over every code by errors.rs’s test_hierarchy_predicates_match_java; the bare KafkaError answers false.

Nested inside is_invalid_configuration_error.

Source

pub fn is_local_illegal_argument_error(&self) -> bool

Returns whether this error’s Java class is, or extends, java.lang.IllegalArgumentException.

Prefer this to matching Error::LocalIllegalArgument: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_local_illegal_state_error(&self) -> bool

Returns whether this error’s Java class is, or extends, java.lang.IllegalStateException.

Prefer this to matching Error::LocalIllegalState: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_local_concurrent_modification_error(&self) -> bool

Returns whether this error’s Java class is, or extends, java.util.ConcurrentModificationException.

Prefer this to matching Error::LocalConcurrentModification: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_local_timeout_error(&self) -> bool

Returns whether this error’s Java class is, or extends, java.util.concurrent.TimeoutException.

Prefer this to matching Error::LocalTimeout: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_local_unsupported_operation_error(&self) -> bool

Returns whether this error’s Java class is, or extends, java.lang.UnsupportedOperationException.

Covers exactly Error::LocalUnsupportedOperation, a plain RuntimeException beside KafkaException: it answers false to is_kafka_error, is_api_error and is_retriable_error, and, unlike is_unsupported_version_error (the wire-level UnsupportedVersionException), it is not fatal.

Prefer this to matching Error::LocalUnsupportedOperation: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_local_callback_error(&self) -> bool

Returns whether this is an error raised by a callback written in another language (Error::LocalCallback; no Java class).

Covers exactly that variant. Like the java.lang runtime errors it is outside the Kafka hierarchy: is_kafka_error and every other predicate answer false for it.

Source

pub fn is_authorizer_not_ready_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.AuthorizerNotReadyException.

Prefer this to matching Error::AuthorizerNotReady: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_bootstrap_resolution_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.BootstrapResolutionException.

Prefer this to matching Error::BootstrapResolution: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_broker_id_not_registered_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.BrokerIdNotRegisteredException.

Prefer this to matching Error::BrokerIdNotRegistered: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_broker_not_available_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.BrokerNotAvailableException.

Prefer this to matching Error::BrokerNotAvailable: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_producer_buffer_exhausted_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.clients.producer.BufferExhaustedException.

Prefer this to matching Error::ProducerBufferExhausted: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_cluster_authorization_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.ClusterAuthorizationException.

Prefer this to matching Error::ClusterAuthorization: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_concurrent_transactions_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.ConcurrentTransactionsException.

Prefer this to matching Error::ConcurrentTransactions: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_controller_id_not_registered_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.ControllerIdNotRegisteredException.

Prefer this to matching Error::ControllerIdNotRegistered: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_controller_moved_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.ControllerMovedException.

Prefer this to matching Error::ControllerMoved: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_coordinator_load_in_progress_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.CoordinatorLoadInProgressException.

Prefer this to matching Error::CoordinatorLoadInProgress: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_coordinator_not_available_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.CoordinatorNotAvailableException.

Prefer this to matching Error::CoordinatorNotAvailable: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_correlation_id_mismatch_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.requests.CorrelationIdMismatchException.

Prefer this to matching Error::CorrelationIdMismatch: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_corrupt_record_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.CorruptRecordException.

Prefer this to matching Error::CorruptRecord: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_delegation_token_authorization_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.DelegationTokenAuthorizationException.

Prefer this to matching Error::DelegationTokenAuthorization: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_delegation_token_disabled_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.DelegationTokenDisabledException.

Prefer this to matching Error::DelegationTokenDisabled: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_delegation_token_expired_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.DelegationTokenExpiredException.

Prefer this to matching Error::DelegationTokenExpired: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_delegation_token_not_found_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.DelegationTokenNotFoundException.

Prefer this to matching Error::DelegationTokenNotFound: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_delegation_token_owner_mismatch_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.DelegationTokenOwnerMismatchException.

Prefer this to matching Error::DelegationTokenOwnerMismatch: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_disconnect_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.DisconnectException.

Prefer this to matching Error::Disconnect: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_duplicate_broker_registration_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.DuplicateBrokerRegistrationException.

Prefer this to matching Error::DuplicateBrokerRegistration: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_duplicate_resource_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.DuplicateResourceException.

Prefer this to matching Error::DuplicateResource: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_duplicate_sequence_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.DuplicateSequenceException.

Prefer this to matching Error::DuplicateSequence: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_duplicate_voter_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.DuplicateVoterException.

Prefer this to matching Error::DuplicateVoter: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_election_not_needed_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.ElectionNotNeededException.

Prefer this to matching Error::ElectionNotNeeded: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_eligible_leaders_not_available_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.EligibleLeadersNotAvailableException.

Prefer this to matching Error::EligibleLeadersNotAvailable: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_feature_update_failed_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.FeatureUpdateFailedException.

Prefer this to matching Error::FeatureUpdateFailed: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_fenced_instance_id_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.FencedInstanceIdException.

Prefer this to matching Error::FencedInstanceId: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_fenced_leader_epoch_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.FencedLeaderEpochException.

Prefer this to matching Error::FencedLeaderEpoch: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_fenced_member_epoch_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.FencedMemberEpochException.

Prefer this to matching Error::FencedMemberEpoch: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_fenced_state_epoch_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.FencedStateEpochException.

Prefer this to matching Error::FencedStateEpoch: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_fetch_session_id_not_found_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.FetchSessionIdNotFoundException.

Prefer this to matching Error::FetchSessionIdNotFound: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_fetch_session_topic_id_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.FetchSessionTopicIdException.

Prefer this to matching Error::FetchSessionTopicId: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_group_authorization_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.GroupAuthorizationException.

Prefer this to matching Error::GroupAuthorization: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_group_deletion_failed_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.GroupDeletionFailedException.

Prefer this to matching Error::GroupDeletionFailed: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_group_id_not_found_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.GroupIdNotFoundException.

Prefer this to matching Error::GroupIdNotFound: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_group_max_size_reached_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.GroupMaxSizeReachedException.

Prefer this to matching Error::GroupMaxSizeReached: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_group_not_empty_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.GroupNotEmptyException.

Prefer this to matching Error::GroupNotEmpty: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_group_subscribed_to_topic_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.GroupSubscribedToTopicException.

Prefer this to matching Error::GroupSubscribedToTopic: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_illegal_generation_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.IllegalGenerationException.

Prefer this to matching Error::IllegalGeneration: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_illegal_sasl_state_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.IllegalSaslStateException.

Prefer this to matching Error::IllegalSaslState: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_inconsistent_cluster_id_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InconsistentClusterIdException.

Prefer this to matching Error::InconsistentClusterId: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_inconsistent_group_protocol_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InconsistentGroupProtocolException.

Prefer this to matching Error::InconsistentGroupProtocol: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_inconsistent_topic_id_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InconsistentTopicIdException.

Prefer this to matching Error::InconsistentTopicId: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_inconsistent_voter_set_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InconsistentVoterSetException.

Prefer this to matching Error::InconsistentVoterSet: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_ineligible_replica_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.IneligibleReplicaException.

Prefer this to matching Error::IneligibleReplica: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_interrupt_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InterruptException.

Prefer this to matching Error::Interrupt: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_commit_offset_size_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidCommitOffsetSizeException.

Prefer this to matching Error::InvalidCommitOffsetSize: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_fetch_session_epoch_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidFetchSessionEpochException.

Prefer this to matching Error::InvalidFetchSessionEpoch: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_fetch_size_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidFetchSizeException.

Prefer this to matching Error::InvalidFetchSize: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_group_id_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidGroupIdException.

Prefer this to matching Error::InvalidGroupId: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_partitions_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidPartitionsException.

Prefer this to matching Error::InvalidPartitions: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_pid_mapping_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidPidMappingException.

Prefer this to matching Error::InvalidPidMapping: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_principal_type_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidPrincipalTypeException.

Prefer this to matching Error::InvalidPrincipalType: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_producer_epoch_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidProducerEpochException.

Prefer this to matching Error::InvalidProducerEpoch: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_record_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.InvalidRecordException.

Prefer this to matching Error::InvalidRecord: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_record_state_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidRecordStateException.

Prefer this to matching Error::InvalidRecordState: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_registration_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidRegistrationException.

Prefer this to matching Error::InvalidRegistration: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_regular_expression_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidRegularExpression.

Prefer this to matching Error::InvalidRegularExpression: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_replica_assignment_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidReplicaAssignmentException.

Prefer this to matching Error::InvalidReplicaAssignment: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_replication_factor_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidReplicationFactorException.

Prefer this to matching Error::InvalidReplicationFactor: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_request_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidRequestException.

Prefer this to matching Error::InvalidRequest: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_required_acks_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidRequiredAcksException.

Prefer this to matching Error::InvalidRequiredAcks: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_session_timeout_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidSessionTimeoutException.

Prefer this to matching Error::InvalidSessionTimeout: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_share_session_epoch_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidShareSessionEpochException.

Prefer this to matching Error::InvalidShareSessionEpoch: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_timestamp_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidTimestampException.

Prefer this to matching Error::InvalidTimestamp: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_topic_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidTopicException.

Prefer this to matching Error::InvalidTopic: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_txn_state_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidTxnStateException.

Prefer this to matching Error::InvalidTxnState: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_txn_timeout_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidTxnTimeoutException.

Prefer this to matching Error::InvalidTxnTimeout: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_update_version_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidUpdateVersionException.

Prefer this to matching Error::InvalidUpdateVersion: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_voter_key_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.InvalidVoterKeyException.

Prefer this to matching Error::InvalidVoterKey: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_kafka_storage_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.KafkaStorageException.

Prefer this to matching Error::KafkaStorage: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_leader_not_available_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.LeaderNotAvailableException.

Prefer this to matching Error::LeaderNotAvailable: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_listener_not_found_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.ListenerNotFoundException.

Prefer this to matching Error::ListenerNotFound: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_log_dir_not_found_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.LogDirNotFoundException.

Prefer this to matching Error::LogDirNotFound: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_member_id_required_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.MemberIdRequiredException.

Prefer this to matching Error::MemberIdRequired: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_mismatched_endpoint_type_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.MismatchedEndpointTypeException.

Prefer this to matching Error::MismatchedEndpointType: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_network_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.NetworkException.

Prefer this to matching Error::Network: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_new_leader_elected_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.NewLeaderElectedException.

Prefer this to matching Error::NewLeaderElected: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_no_reassignment_in_progress_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.NoReassignmentInProgressException.

Prefer this to matching Error::NoReassignmentInProgress: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_not_controller_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.NotControllerException.

Prefer this to matching Error::NotController: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_not_coordinator_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.NotCoordinatorException.

Prefer this to matching Error::NotCoordinator: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_not_enough_replicas_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.NotEnoughReplicasException.

Prefer this to matching Error::NotEnoughReplicas: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_not_enough_replicas_after_append_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.NotEnoughReplicasAfterAppendException.

Prefer this to matching Error::NotEnoughReplicasAfterAppend: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_not_leader_or_follower_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.NotLeaderOrFollowerException.

Prefer this to matching Error::NotLeaderOrFollower: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_offset_metadata_too_large_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.OffsetMetadataTooLarge.

Prefer this to matching Error::OffsetMetadataTooLarge: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_offset_moved_to_tiered_storage_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.OffsetMovedToTieredStorageException.

Prefer this to matching Error::OffsetMovedToTieredStorage: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_offset_not_available_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.OffsetNotAvailableException.

Prefer this to matching Error::OffsetNotAvailable: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_offset_out_of_range_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.OffsetOutOfRangeException.

Prefer this to matching Error::OffsetOutOfRange: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_operation_not_attempted_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.OperationNotAttemptedException.

Prefer this to matching Error::OperationNotAttempted: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_policy_violation_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.PolicyViolationException.

Prefer this to matching Error::PolicyViolation: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_position_out_of_range_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.PositionOutOfRangeException.

Prefer this to matching Error::PositionOutOfRange: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_preferred_leader_not_available_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.PreferredLeaderNotAvailableException.

Prefer this to matching Error::PreferredLeaderNotAvailable: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_principal_deserialization_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.PrincipalDeserializationException.

Prefer this to matching Error::PrincipalDeserialization: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_producer_fenced_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.ProducerFencedException.

Prefer this to matching Error::ProducerFenced: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_quota_violation_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.metrics.QuotaViolationException.

Prefer this to matching Error::QuotaViolation: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_reassignment_in_progress_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.ReassignmentInProgressException.

Prefer this to matching Error::ReassignmentInProgress: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_rebalance_in_progress_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.RebalanceInProgressException.

Prefer this to matching Error::RebalanceInProgress: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_rebootstrap_required_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.RebootstrapRequiredException.

Prefer this to matching Error::RebootstrapRequired: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_record_batch_too_large_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.RecordBatchTooLargeException.

Prefer this to matching Error::RecordBatchTooLarge: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_record_deserialization_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.RecordDeserializationException.

Prefer this to matching Error::RecordDeserialization: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_record_too_large_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.RecordTooLargeException.

Prefer this to matching Error::RecordTooLarge: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_invalid_receive_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.network.InvalidReceiveException.

Prefer this to matching Error::InvalidReceive: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_config_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.config.ConfigException.

Prefer this to matching Error::Config: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_consumer_retriable_commit_failed_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.clients.consumer.RetriableCommitFailedException.

Prefer this to matching Error::ConsumerRetriableCommitFailed: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_consumer_commit_failed_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.clients.consumer.CommitFailedException.

Prefer this to matching Error::ConsumerCommitFailed: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_consumer_no_offset_for_partition_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.clients.consumer.NoOffsetForPartitionException.

Prefer this to matching Error::ConsumerNoOffsetForPartition: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_consumer_log_truncation_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.clients.consumer.LogTruncationException.

Prefer this to matching Error::ConsumerLogTruncation: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_replica_not_available_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.ReplicaNotAvailableException.

Prefer this to matching Error::ReplicaNotAvailable: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_resource_not_found_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.ResourceNotFoundException.

Prefer this to matching Error::ResourceNotFound: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_sasl_authentication_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.SaslAuthenticationException.

Prefer this to matching Error::SaslAuthentication: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_schema_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.protocol.types.SchemaException.

Prefer this to matching Error::Schema: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_security_disabled_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.SecurityDisabledException.

Prefer this to matching Error::SecurityDisabled: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_share_session_limit_reached_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.ShareSessionLimitReachedException.

Prefer this to matching Error::ShareSessionLimitReached: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_share_session_not_found_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.ShareSessionNotFoundException.

Prefer this to matching Error::ShareSessionNotFound: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_snapshot_not_found_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.SnapshotNotFoundException.

Prefer this to matching Error::SnapshotNotFound: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_ssl_authentication_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.SslAuthenticationException.

Prefer this to matching Error::SslAuthentication: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_stale_broker_epoch_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.StaleBrokerEpochException.

Prefer this to matching Error::StaleBrokerEpoch: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_stale_member_epoch_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.StaleMemberEpochException.

Prefer this to matching Error::StaleMemberEpoch: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_streams_invalid_topology_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.StreamsInvalidTopologyException.

Prefer this to matching Error::StreamsInvalidTopology: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_streams_invalid_topology_epoch_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.StreamsInvalidTopologyEpochException.

Prefer this to matching Error::StreamsInvalidTopologyEpoch: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_streams_topology_description_update_failed_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.StreamsTopologyDescriptionUpdateFailedException.

Prefer this to matching Error::StreamsTopologyDescriptionUpdateFailed: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_streams_topology_fenced_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.StreamsTopologyFencedException.

Prefer this to matching Error::StreamsTopologyFenced: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_telemetry_too_large_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.TelemetryTooLargeException.

Prefer this to matching Error::TelemetryTooLarge: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_throttling_quota_exceeded_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.ThrottlingQuotaExceededException.

Prefer this to matching Error::ThrottlingQuotaExceeded: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_topic_authorization_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.TopicAuthorizationException.

Prefer this to matching Error::TopicAuthorization: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_topic_deletion_disabled_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.TopicDeletionDisabledException.

Prefer this to matching Error::TopicDeletionDisabled: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_topic_exists_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.TopicExistsException.

Prefer this to matching Error::TopicExists: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_transaction_abortable_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.TransactionAbortableException.

Prefer this to matching Error::TransactionAbortable: a variant match misses the subclasses a later Java release may add.

Java tests this class in two ways: by code (error == Errors.TRANSACTION_ABORTABLE, four sites in TransactionManager) and by class (error.exception() instanceof TransactionAbortableException, in TransactionManager). This predicate is the class test.

Source

pub fn is_transaction_aborted_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.TransactionAbortedException.

Prefer this to matching Error::TransactionAborted: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_transaction_coordinator_fenced_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.TransactionCoordinatorFencedException.

Prefer this to matching Error::TransactionCoordinatorFenced: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_transactional_id_authorization_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.TransactionalIdAuthorizationException.

Prefer this to matching Error::TransactionalIdAuthorization: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_transactional_id_not_found_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.TransactionalIdNotFoundException.

Prefer this to matching Error::TransactionalIdNotFound: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_unacceptable_credential_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.UnacceptableCredentialException.

Prefer this to matching Error::UnacceptableCredential: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_unknown_controller_id_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.UnknownControllerIdException.

Prefer this to matching Error::UnknownControllerId: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_unknown_leader_epoch_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.UnknownLeaderEpochException.

Prefer this to matching Error::UnknownLeaderEpoch: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_unknown_member_id_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.UnknownMemberIdException.

Prefer this to matching Error::UnknownMemberId: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_unknown_producer_id_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.UnknownProducerIdException.

Prefer this to matching Error::UnknownProducerId: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_unknown_server_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.UnknownServerException.

Prefer this to matching Error::UnknownServer: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_unknown_subscription_id_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.UnknownSubscriptionIdException.

Prefer this to matching Error::UnknownSubscriptionId: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_unknown_topic_id_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.UnknownTopicIdException.

Prefer this to matching Error::UnknownTopicId: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_unknown_topic_or_partition_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.UnknownTopicOrPartitionException.

Prefer this to matching Error::UnknownTopicOrPartition: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_unreleased_instance_id_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.UnreleasedInstanceIdException.

Prefer this to matching Error::UnreleasedInstanceId: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_unstable_offset_commit_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.UnstableOffsetCommitException.

Prefer this to matching Error::UnstableOffsetCommit: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_unsupported_assignor_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.UnsupportedAssignorException.

Prefer this to matching Error::UnsupportedAssignor: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_unsupported_by_authentication_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.UnsupportedByAuthenticationException.

Prefer this to matching Error::UnsupportedByAuthentication: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_unsupported_compression_type_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.UnsupportedCompressionTypeException.

Prefer this to matching Error::UnsupportedCompressionType: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_unsupported_endpoint_type_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.UnsupportedEndpointTypeException.

Prefer this to matching Error::UnsupportedEndpointType: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_unsupported_for_message_format_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.UnsupportedForMessageFormatException.

Prefer this to matching Error::UnsupportedForMessageFormat: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_unsupported_sasl_mechanism_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.UnsupportedSaslMechanismException.

Prefer this to matching Error::UnsupportedSaslMechanism: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_unsupported_version_error(&self) -> bool

Returns whether this error’s Java class extends UnsupportedVersionException.

Exactly the UnsupportedVersion variant (Errors::UnsupportedVersion). Java’s subclasses — UnsupportedProtocolFieldException (Kafka 4.4, KAFKA-18157) and the NoBatchedFindCoordinatorsException / NoBatchedOffsetFetchRequestException nested in FindCoordinatorRequest / OffsetFetchRequest — are none of them public, so they are carried inside that variant rather than as variants of their own; this predicate therefore answers true for them too, as Java’s instanceof UnsupportedVersionException does.

Nested inside is_invalid_configuration_error, because UnsupportedVersionException extends InvalidConfigurationException. The set is pinned in both directions over every code by errors.rs’s test_hierarchy_predicates_match_java.

Prefer this to matching Error::UnsupportedVersion: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_voter_not_found_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.VoterNotFoundException.

Prefer this to matching Error::VoterNotFound: a variant match misses the subclasses a later Java release may add.

Source

pub fn is_wakeup_error(&self) -> bool

Returns whether this error’s Java class is, or extends, org.apache.kafka.common.errors.WakeupException.

Prefer this to matching Error::Wakeup: a variant match misses the subclasses a later Java release may add.

Trait Implementations§

Source§

impl Clone for Error

Source§

fn clone(&self) -> Error

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Error

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Display for Error
where WakeupError: Display, KafkaError: MatchDisplay<WakeupError>, LocalIllegalArgumentError: MatchDisplay<WakeupError>, LocalIllegalStateError: MatchDisplay<WakeupError>, LocalConcurrentModificationError: MatchDisplay<WakeupError>, LocalTimeoutError: MatchDisplay<WakeupError>, LocalUnsupportedOperationError: MatchDisplay<WakeupError>, LocalCallbackError: MatchDisplay<WakeupError>, ApiError: MatchDisplay<WakeupError>, AuthenticationError: MatchDisplay<WakeupError>, AuthorizationError: MatchDisplay<WakeupError>, AuthorizerNotReadyError: MatchDisplay<WakeupError>, BootstrapResolutionError: MatchDisplay<WakeupError>, BrokerIdNotRegisteredError: MatchDisplay<WakeupError>, BrokerNotAvailableError: MatchDisplay<WakeupError>, ProducerBufferExhaustedError: MatchDisplay<WakeupError>, ClusterAuthorizationError: MatchDisplay<WakeupError>, ConcurrentTransactionsError: MatchDisplay<WakeupError>, ControllerIdNotRegisteredError: MatchDisplay<WakeupError>, ControllerMovedError: MatchDisplay<WakeupError>, CoordinatorLoadInProgressError: MatchDisplay<WakeupError>, CoordinatorNotAvailableError: MatchDisplay<WakeupError>, CorrelationIdMismatchError: MatchDisplay<WakeupError>, CorruptRecordError: MatchDisplay<WakeupError>, DelegationTokenAuthorizationError: MatchDisplay<WakeupError>, DelegationTokenDisabledError: MatchDisplay<WakeupError>, DelegationTokenExpiredError: MatchDisplay<WakeupError>, DelegationTokenNotFoundError: MatchDisplay<WakeupError>, DelegationTokenOwnerMismatchError: MatchDisplay<WakeupError>, DisconnectError: MatchDisplay<WakeupError>, DuplicateBrokerRegistrationError: MatchDisplay<WakeupError>, DuplicateResourceError: MatchDisplay<WakeupError>, DuplicateSequenceError: MatchDisplay<WakeupError>, DuplicateVoterError: MatchDisplay<WakeupError>, ElectionNotNeededError: MatchDisplay<WakeupError>, EligibleLeadersNotAvailableError: MatchDisplay<WakeupError>, FeatureUpdateFailedError: MatchDisplay<WakeupError>, FencedInstanceIdError: MatchDisplay<WakeupError>, FencedLeaderEpochError: MatchDisplay<WakeupError>, FencedMemberEpochError: MatchDisplay<WakeupError>, FencedStateEpochError: MatchDisplay<WakeupError>, FetchSessionIdNotFoundError: MatchDisplay<WakeupError>, FetchSessionTopicIdError: MatchDisplay<WakeupError>, GroupAuthorizationError: MatchDisplay<WakeupError>, GroupDeletionFailedError: MatchDisplay<WakeupError>, GroupIdNotFoundError: MatchDisplay<WakeupError>, GroupMaxSizeReachedError: MatchDisplay<WakeupError>, GroupNotEmptyError: MatchDisplay<WakeupError>, GroupSubscribedToTopicError: MatchDisplay<WakeupError>, IllegalGenerationError: MatchDisplay<WakeupError>, IllegalSaslStateError: MatchDisplay<WakeupError>, InconsistentClusterIdError: MatchDisplay<WakeupError>, InconsistentGroupProtocolError: MatchDisplay<WakeupError>, InconsistentTopicIdError: MatchDisplay<WakeupError>, InconsistentVoterSetError: MatchDisplay<WakeupError>, IneligibleReplicaError: MatchDisplay<WakeupError>, InterruptError: MatchDisplay<WakeupError>, InvalidCommitOffsetSizeError: MatchDisplay<WakeupError>, InvalidConfigurationError: MatchDisplay<WakeupError>, InvalidFetchSessionEpochError: MatchDisplay<WakeupError>, InvalidFetchSizeError: MatchDisplay<WakeupError>, InvalidGroupIdError: MatchDisplay<WakeupError>, InvalidOffsetError: MatchDisplay<WakeupError>, InvalidPartitionsError: MatchDisplay<WakeupError>, InvalidPidMappingError: MatchDisplay<WakeupError>, InvalidPrincipalTypeError: MatchDisplay<WakeupError>, InvalidProducerEpochError: MatchDisplay<WakeupError>, InvalidRecordError: MatchDisplay<WakeupError>, InvalidRecordStateError: MatchDisplay<WakeupError>, InvalidRegistrationError: MatchDisplay<WakeupError>, InvalidRegularExpression: MatchDisplay<WakeupError>, InvalidReplicaAssignmentError: MatchDisplay<WakeupError>, InvalidReplicationFactorError: MatchDisplay<WakeupError>, InvalidRequestError: MatchDisplay<WakeupError>, InvalidRequiredAcksError: MatchDisplay<WakeupError>, InvalidSessionTimeoutError: MatchDisplay<WakeupError>, InvalidShareSessionEpochError: MatchDisplay<WakeupError>, InvalidTimestampError: MatchDisplay<WakeupError>, InvalidTopicError: MatchDisplay<WakeupError>, InvalidTxnStateError: MatchDisplay<WakeupError>, InvalidTxnTimeoutError: MatchDisplay<WakeupError>, InvalidUpdateVersionError: MatchDisplay<WakeupError>, InvalidVoterKeyError: MatchDisplay<WakeupError>, KafkaStorageError: MatchDisplay<WakeupError>, LeaderNotAvailableError: MatchDisplay<WakeupError>, ListenerNotFoundError: MatchDisplay<WakeupError>, LogDirNotFoundError: MatchDisplay<WakeupError>, MemberIdRequiredError: MatchDisplay<WakeupError>, MismatchedEndpointTypeError: MatchDisplay<WakeupError>, NetworkError: MatchDisplay<WakeupError>, NewLeaderElectedError: MatchDisplay<WakeupError>, NoReassignmentInProgressError: MatchDisplay<WakeupError>, NotControllerError: MatchDisplay<WakeupError>, NotCoordinatorError: MatchDisplay<WakeupError>, NotEnoughReplicasError: MatchDisplay<WakeupError>, NotEnoughReplicasAfterAppendError: MatchDisplay<WakeupError>, NotLeaderOrFollowerError: MatchDisplay<WakeupError>, OffsetMetadataTooLarge: MatchDisplay<WakeupError>, OffsetMovedToTieredStorageError: MatchDisplay<WakeupError>, OffsetNotAvailableError: MatchDisplay<WakeupError>, OffsetOutOfRangeError: MatchDisplay<WakeupError>, OperationNotAttemptedError: MatchDisplay<WakeupError>, OutOfOrderSequenceError: MatchDisplay<WakeupError>, PolicyViolationError: MatchDisplay<WakeupError>, PositionOutOfRangeError: MatchDisplay<WakeupError>, PreferredLeaderNotAvailableError: MatchDisplay<WakeupError>, PrincipalDeserializationError: MatchDisplay<WakeupError>, ProducerFencedError: MatchDisplay<WakeupError>, Box<QuotaViolationError>: MatchDisplay<WakeupError>, ReassignmentInProgressError: MatchDisplay<WakeupError>, RebalanceInProgressError: MatchDisplay<WakeupError>, RebootstrapRequiredError: MatchDisplay<WakeupError>, RecordBatchTooLargeError: MatchDisplay<WakeupError>, Box<RecordDeserializationError>: MatchDisplay<WakeupError>, RecordTooLargeError: MatchDisplay<WakeupError>, InvalidReceiveError: MatchDisplay<WakeupError>, ConfigError: MatchDisplay<WakeupError>, ConsumerRetriableCommitFailedError: MatchDisplay<WakeupError>, ConsumerCommitFailedError: MatchDisplay<WakeupError>, ConsumerNoOffsetForPartitionError: MatchDisplay<WakeupError>, ConsumerOffsetOutOfRangeError: MatchDisplay<WakeupError>, Box<ConsumerLogTruncationError>: MatchDisplay<WakeupError>, ReplicaNotAvailableError: MatchDisplay<WakeupError>, ResourceNotFoundError: MatchDisplay<WakeupError>, SaslAuthenticationError: MatchDisplay<WakeupError>, SchemaError: MatchDisplay<WakeupError>, SecurityDisabledError: MatchDisplay<WakeupError>, SerializationError: MatchDisplay<WakeupError>, ShareSessionLimitReachedError: MatchDisplay<WakeupError>, ShareSessionNotFoundError: MatchDisplay<WakeupError>, SnapshotNotFoundError: MatchDisplay<WakeupError>, SslAuthenticationError: MatchDisplay<WakeupError>, StaleBrokerEpochError: MatchDisplay<WakeupError>, StaleMemberEpochError: MatchDisplay<WakeupError>, StreamsInvalidTopologyError: MatchDisplay<WakeupError>, StreamsInvalidTopologyEpochError: MatchDisplay<WakeupError>, StreamsTopologyDescriptionUpdateFailedError: MatchDisplay<WakeupError>, StreamsTopologyFencedError: MatchDisplay<WakeupError>, TelemetryTooLargeError: MatchDisplay<WakeupError>, ThrottlingQuotaExceededError: MatchDisplay<WakeupError>, TimeoutError: MatchDisplay<WakeupError>, TopicAuthorizationError: MatchDisplay<WakeupError>, TopicDeletionDisabledError: MatchDisplay<WakeupError>, TopicExistsError: MatchDisplay<WakeupError>, TransactionAbortableError: MatchDisplay<WakeupError>, TransactionAbortedError: MatchDisplay<WakeupError>, TransactionCoordinatorFencedError: MatchDisplay<WakeupError>, TransactionalIdAuthorizationError: MatchDisplay<WakeupError>, TransactionalIdNotFoundError: MatchDisplay<WakeupError>, UnacceptableCredentialError: MatchDisplay<WakeupError>, UnknownControllerIdError: MatchDisplay<WakeupError>, UnknownLeaderEpochError: MatchDisplay<WakeupError>, UnknownMemberIdError: MatchDisplay<WakeupError>, UnknownProducerIdError: MatchDisplay<WakeupError>, UnknownServerError: MatchDisplay<WakeupError>, UnknownSubscriptionIdError: MatchDisplay<WakeupError>, UnknownTopicIdError: MatchDisplay<WakeupError>, UnknownTopicOrPartitionError: MatchDisplay<WakeupError>, UnreleasedInstanceIdError: MatchDisplay<WakeupError>, UnstableOffsetCommitError: MatchDisplay<WakeupError>, UnsupportedAssignorError: MatchDisplay<WakeupError>, UnsupportedByAuthenticationError: MatchDisplay<WakeupError>, UnsupportedCompressionTypeError: MatchDisplay<WakeupError>, UnsupportedEndpointTypeError: MatchDisplay<WakeupError>, UnsupportedForMessageFormatError: MatchDisplay<WakeupError>, UnsupportedSaslMechanismError: MatchDisplay<WakeupError>, UnsupportedVersionError: MatchDisplay<WakeupError>, VoterNotFoundError: MatchDisplay<WakeupError>,

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
Source§

impl Error for Error

Source§

fn source(&self) -> Option<&(dyn Error + 'static)>

Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§

fn description(&self) -> &str

👎Deprecated since 1.42.0: use the Display impl or to_string()
1.0.0 · Source§

fn cause(&self) -> Option<&dyn Error>

👎Deprecated since 1.33.0: replaced by Error::source, which can support downcasting
Source§

fn provide<'a>(&'a self, request: &mut Request<'a>)

🔬This is a nightly-only experimental API. (error_generic_member_access)
Provides type-based access to context intended for error reports. Read more

Auto Trait Implementations§

§

impl Freeze for Error

§

impl RefUnwindSafe for Error

§

impl Send for Error

§

impl Sync for Error

§

impl Unpin for Error

§

impl UnsafeUnpin for Error

§

impl UnwindSafe for Error

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

§

fn vzip(self) -> V