Package com.github.ambry.router
Enum RouterErrorCode
- java.lang.Object
-
- java.lang.Enum<RouterErrorCode>
-
- com.github.ambry.router.RouterErrorCode
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<RouterErrorCode>
public enum RouterErrorCode extends java.lang.Enum<RouterErrorCode>
All the error codes that accompany aRouterException
.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description AmbryUnavailable
Insufficient Ambry DataNodes could be contacted to successfully complete an operation.BadInputChannel
Unexpected error reading from the input channel for puts.BlobAuthorizationFailure
ContainerId or AccountId from blobId doesn't match these in store server.BlobDeleted
Blob has been deleted and so cannot be retrieved.BlobDoesNotExist
No Blob could be found for specified blob id.BlobExpired
TTL of Blob has expired and so Blob cannot be retrieved.BlobNotDeleted
Blob is not yet deleted.BlobTooLarge
Blob is too large.BlobUndeleted
Blob already undeleted so it can't not be undeleted again.BlobUpdateNotAllowed
The update has been rejectedChannelClosed
The channel returned to the user in a getBlob operation has been closed before operation completion.InsufficientCapacity
Insufficient capacity available in Ambry for object to be stored.InvalidBlobId
Caller passed in an invalid blob id and so operation could not be attempted.InvalidPutArgument
Caller passed in an illegal argument forRouter.putBlob(com.github.ambry.messageformat.BlobProperties, byte[], ReadableStreamChannel, PutBlobOptions)
operation (and its variant).LifeVersionConflict
LifeVersions from two responses are different.OperationTimedOut
Operation did not complete within specified time out.RangeNotSatisfiable
The range offsets provided for a getBlob operation are invalid for the specified blob.RouterClosed
Thrown when an operation is attempted after theRouter
is closed.UnexpectedInternalError
Router experienced an unexpected internal error.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static RouterErrorCode
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static RouterErrorCode[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
AmbryUnavailable
public static final RouterErrorCode AmbryUnavailable
Insufficient Ambry DataNodes could be contacted to successfully complete an operation. The caller should retry the operation. An operation that changes the state of an existing blob (delete) may have partially completed and so may eventually complete in the future.
-
InvalidBlobId
public static final RouterErrorCode InvalidBlobId
Caller passed in an invalid blob id and so operation could not be attempted. May occur forRouter.getBlob(String, GetBlobOptions)
,Router.deleteBlob(String, String)
(and their variants) operations.
-
InvalidPutArgument
public static final RouterErrorCode InvalidPutArgument
Caller passed in an illegal argument forRouter.putBlob(com.github.ambry.messageformat.BlobProperties, byte[], ReadableStreamChannel, PutBlobOptions)
operation (and its variant).
-
OperationTimedOut
public static final RouterErrorCode OperationTimedOut
Operation did not complete within specified time out. The caller should retry the operation. An operation that changes the state of an existing blob (delete) may have partially completed and so may eventually complete in the future.
-
RouterClosed
public static final RouterErrorCode RouterClosed
Thrown when an operation is attempted after theRouter
is closed.
-
UnexpectedInternalError
public static final RouterErrorCode UnexpectedInternalError
Router experienced an unexpected internal error. The caller should retry the operation. An operation that changes the state of an existing blob (delete) may have partially completed and so may eventually complete in the future.
-
BlobTooLarge
public static final RouterErrorCode BlobTooLarge
Blob is too large. Cannot store blob of such size.
-
BadInputChannel
public static final RouterErrorCode BadInputChannel
Unexpected error reading from the input channel for puts.
-
InsufficientCapacity
public static final RouterErrorCode InsufficientCapacity
Insufficient capacity available in Ambry for object to be stored.
-
BlobDeleted
public static final RouterErrorCode BlobDeleted
Blob has been deleted and so cannot be retrieved.
-
BlobDoesNotExist
public static final RouterErrorCode BlobDoesNotExist
No Blob could be found for specified blob id.
-
BlobExpired
public static final RouterErrorCode BlobExpired
TTL of Blob has expired and so Blob cannot be retrieved.
-
RangeNotSatisfiable
public static final RouterErrorCode RangeNotSatisfiable
The range offsets provided for a getBlob operation are invalid for the specified blob.
-
ChannelClosed
public static final RouterErrorCode ChannelClosed
The channel returned to the user in a getBlob operation has been closed before operation completion.
-
BlobUpdateNotAllowed
public static final RouterErrorCode BlobUpdateNotAllowed
The update has been rejected
-
BlobAuthorizationFailure
public static final RouterErrorCode BlobAuthorizationFailure
ContainerId or AccountId from blobId doesn't match these in store server.
-
BlobUndeleted
public static final RouterErrorCode BlobUndeleted
Blob already undeleted so it can't not be undeleted again. Should delete this blob before undelete.
-
LifeVersionConflict
public static final RouterErrorCode LifeVersionConflict
LifeVersions from two responses are different. eg, undelete responses returns two different lifeVersions.
-
BlobNotDeleted
public static final RouterErrorCode BlobNotDeleted
Blob is not yet deleted. For undelete, a blob needs to be deleted first.
-
-
Method Detail
-
values
public static RouterErrorCode[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (RouterErrorCode c : RouterErrorCode.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static RouterErrorCode valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
-