Package org.apache.pulsar.client.api
Class PulsarClientException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.io.IOException
-
- org.apache.pulsar.client.api.PulsarClientException
-
- All Implemented Interfaces:
java.io.Serializable
- Direct Known Subclasses:
PulsarClientException.AlreadyClosedException,PulsarClientException.AuthenticationException,PulsarClientException.AuthorizationException,PulsarClientException.BrokerMetadataException,PulsarClientException.BrokerPersistenceException,PulsarClientException.ChecksumException,PulsarClientException.ConnectException,PulsarClientException.ConsumerAssignException,PulsarClientException.ConsumerBusyException,PulsarClientException.CryptoException,PulsarClientException.GettingAuthenticationDataException,PulsarClientException.IncompatibleSchemaException,PulsarClientException.InvalidConfigurationException,PulsarClientException.InvalidMessageException,PulsarClientException.InvalidServiceURL,PulsarClientException.InvalidTopicNameException,PulsarClientException.LookupException,PulsarClientException.MemoryBufferIsFullError,PulsarClientException.MessageAcknowledgeException,PulsarClientException.NotAllowedException,PulsarClientException.NotConnectedException,PulsarClientException.NotFoundException,PulsarClientException.NotSupportedException,PulsarClientException.ProducerBlockedQuotaExceededError,PulsarClientException.ProducerBlockedQuotaExceededException,PulsarClientException.ProducerBusyException,PulsarClientException.ProducerFencedException,PulsarClientException.ProducerQueueIsFullError,PulsarClientException.TimeoutException,PulsarClientException.TopicDoesNotExistException,PulsarClientException.TopicTerminatedException,PulsarClientException.TransactionConflictException,PulsarClientException.UnsupportedAuthenticationException
@Public @Stable public class PulsarClientException extends java.io.IOException
Base type of exception thrown by Pulsar client.- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classPulsarClientException.AlreadyClosedExceptionAlready closed exception thrown by Pulsar client.static classPulsarClientException.AuthenticationExceptionAuthentication exception thrown by Pulsar client.static classPulsarClientException.AuthorizationExceptionAuthorization exception thrown by Pulsar client.static classPulsarClientException.BrokerMetadataExceptionBroker metadata exception thrown by Pulsar client.static classPulsarClientException.BrokerPersistenceExceptionBroker persistence exception thrown by Pulsar client.static classPulsarClientException.ChecksumExceptionChecksum exception thrown by Pulsar client.static classPulsarClientException.ConnectExceptionConnect exception thrown by Pulsar client.static classPulsarClientException.ConsumerAssignExceptionConsumer assign exception thrown by Pulsar client.static classPulsarClientException.ConsumerBusyExceptionConsumer busy exception thrown by Pulsar client.static classPulsarClientException.CryptoExceptionCrypto exception thrown by Pulsar client.static classPulsarClientException.GettingAuthenticationDataExceptionGetting authentication data exception thrown by Pulsar client.static classPulsarClientException.IncompatibleSchemaExceptionIncompatible schema exception thrown by Pulsar client.static classPulsarClientException.InvalidConfigurationExceptionInvalid Configuration exception thrown by Pulsar client.static classPulsarClientException.InvalidMessageExceptionInvalid message exception thrown by Pulsar client.static classPulsarClientException.InvalidServiceURLInvalid Service URL exception thrown by Pulsar client.static classPulsarClientException.InvalidTopicNameExceptionInvalid topic name exception thrown by Pulsar client.static classPulsarClientException.LookupExceptionLookup exception thrown by Pulsar client.static classPulsarClientException.MemoryBufferIsFullErrorMemory buffer full error thrown by Pulsar client.static classPulsarClientException.MessageAcknowledgeExceptionConsumer assign exception thrown by Pulsar client.static classPulsarClientException.NotAllowedExceptionNot allowed exception thrown by Pulsar client.static classPulsarClientException.NotConnectedExceptionNot connected exception thrown by Pulsar client.static classPulsarClientException.NotFoundExceptionNot Found exception thrown by Pulsar client.static classPulsarClientException.NotSupportedExceptionNot supported exception thrown by Pulsar client.static classPulsarClientException.ProducerBlockedQuotaExceededErrorProducer blocked quota exceeded error thrown by Pulsar client.static classPulsarClientException.ProducerBlockedQuotaExceededExceptionProducer blocked quota exceeded exception thrown by Pulsar client.static classPulsarClientException.ProducerBusyExceptionProducer busy exception thrown by Pulsar client.static classPulsarClientException.ProducerFencedExceptionProducer fenced exception thrown by Pulsar client.static classPulsarClientException.ProducerQueueIsFullErrorFull producer queue error thrown by Pulsar client.static classPulsarClientException.TimeoutExceptionTimeout exception thrown by Pulsar client.static classPulsarClientException.TooManyRequestsExceptionToo many requests exception thrown by Pulsar client.static classPulsarClientException.TopicDoesNotExistExceptionTopic does not exist and cannot be created.static classPulsarClientException.TopicTerminatedExceptionTopic terminated exception thrown by Pulsar client.static classPulsarClientException.TransactionConflictExceptionConsumer assign exception thrown by Pulsar client.static classPulsarClientException.UnsupportedAuthenticationExceptionUnsupported authentication exception thrown by Pulsar client.
-
Constructor Summary
Constructors Constructor Description PulsarClientException(java.lang.String msg)Constructs anPulsarClientExceptionwith the specified detail message.PulsarClientException(java.lang.String msg, long sequenceId)Constructs anPulsarClientExceptionwith the specified detail message.PulsarClientException(java.lang.String msg, java.lang.Throwable t)Constructs anPulsarClientExceptionwith the specified cause.PulsarClientException(java.lang.Throwable t)Constructs anPulsarClientExceptionwith the specified cause.PulsarClientException(java.lang.Throwable t, long sequenceId)Constructs anPulsarClientExceptionwith the specified cause.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.Collection<java.lang.Throwable>getPreviousExceptions()Get the collection of previous exceptions which have caused retries for this operation.static java.util.Collection<java.lang.Throwable>getPreviousExceptions(java.lang.Throwable t)longgetSequenceId()static booleanisRetriableError(java.lang.Throwable t)static voidsetPreviousExceptions(java.lang.Throwable t, java.util.Collection<java.lang.Throwable> previous)voidsetPreviousExceptions(java.util.Collection<java.lang.Throwable> previous)Add a list of previous exception which occurred for the same operation and have been retried.voidsetSequenceId(long sequenceId)java.lang.StringtoString()static PulsarClientExceptionunwrap(java.lang.Throwable t)static java.lang.Throwablewrap(java.lang.Throwable t, java.lang.String msg)
-
-
-
Constructor Detail
-
PulsarClientException
public PulsarClientException(java.lang.String msg)
Constructs anPulsarClientExceptionwith the specified detail message.- Parameters:
msg- The detail message (which is saved for later retrieval by theThrowable.getMessage()method)
-
PulsarClientException
public PulsarClientException(java.lang.String msg, long sequenceId)Constructs anPulsarClientExceptionwith the specified detail message.- Parameters:
msg- The detail message (which is saved for later retrieval by theThrowable.getMessage()method)sequenceId- The sequenceId of the message
-
PulsarClientException
public PulsarClientException(java.lang.Throwable t)
Constructs anPulsarClientExceptionwith the specified cause.- Parameters:
t- The cause (which is saved for later retrieval by theThrowable.getCause()method). (A null value is permitted, and indicates that the cause is nonexistent or unknown.)
-
PulsarClientException
public PulsarClientException(java.lang.String msg, java.lang.Throwable t)Constructs anPulsarClientExceptionwith the specified cause.- Parameters:
msg- The detail message (which is saved for later retrieval by theThrowable.getMessage()method)t- The cause (which is saved for later retrieval by theThrowable.getCause()method). (A null value is permitted, and indicates that the cause is nonexistent or unknown.)
-
PulsarClientException
public PulsarClientException(java.lang.Throwable t, long sequenceId)Constructs anPulsarClientExceptionwith the specified cause.- Parameters:
t- The cause (which is saved for later retrieval by theThrowable.getCause()method). (A null value is permitted, and indicates that the cause is nonexistent or unknown.)sequenceId- The sequenceId of the message
-
-
Method Detail
-
setPreviousExceptions
public void setPreviousExceptions(java.util.Collection<java.lang.Throwable> previous)
Add a list of previous exception which occurred for the same operation and have been retried.- Parameters:
previous- A collection of throwables that triggered retries
-
getPreviousExceptions
public java.util.Collection<java.lang.Throwable> getPreviousExceptions()
Get the collection of previous exceptions which have caused retries for this operation.- Returns:
- a collection of exception, ordered as they occurred
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Throwable
-
wrap
public static java.lang.Throwable wrap(java.lang.Throwable t, java.lang.String msg)
-
unwrap
public static PulsarClientException unwrap(java.lang.Throwable t)
-
getPreviousExceptions
public static java.util.Collection<java.lang.Throwable> getPreviousExceptions(java.lang.Throwable t)
-
setPreviousExceptions
public static void setPreviousExceptions(java.lang.Throwable t, java.util.Collection<java.lang.Throwable> previous)
-
getSequenceId
public long getSequenceId()
-
setSequenceId
public void setSequenceId(long sequenceId)
-
isRetriableError
public static boolean isRetriableError(java.lang.Throwable t)
-
-