ErrorCode

com.bilalfazlani.zioMaelstrom.ErrorCode
See theErrorCode companion trait
object ErrorCode

Attributes

Companion
trait
Graph
Supertypes
trait Sum
trait Mirror
class Object
trait Matchable
class Any
Self type
ErrorCode.type

Members list

Type members

Classlikes

object Abort extends ErrorCode

Indicates that some kind of general, definite error occurred. Use this as a catch-all for errors you can't otherwise categorize, when you specifically know that the requested operation has not taken place. For instance, you might encounter an indefinite failure during the prepare phase of a transaction: since you haven't started the commit process yet, the transaction can't have taken place. It's therefore safe to return a definite abort to the client.

Indicates that some kind of general, definite error occurred. Use this as a catch-all for errors you can't otherwise categorize, when you specifically know that the requested operation has not taken place. For instance, you might encounter an indefinite failure during the prepare phase of a transaction: since you haven't started the commit process yet, the transaction can't have taken place. It's therefore safe to return a definite abort to the client.

Attributes

Supertypes
trait ErrorCode
class Object
trait Matchable
class Any
Self type
Abort.type
object Crash extends ErrorCode

Indicates that some kind of general, indefinite error occurred. Use this as a catch-all for errors you can't otherwise categorize, or as a starting point for your error handler: it's safe to return internal-error for every problem by default, then add special cases for more specific errors later.

Indicates that some kind of general, indefinite error occurred. Use this as a catch-all for errors you can't otherwise categorize, or as a starting point for your error handler: it's safe to return internal-error for every problem by default, then add special cases for more specific errors later.

Attributes

Supertypes
trait ErrorCode
class Object
trait Matchable
class Any
Self type
Crash.type
case class Custom(code: Int) extends ErrorCode

Custom error code

Custom error code

Value parameters

code

the error code

Attributes

Supertypes
trait Serializable
trait Product
trait Equals
trait ErrorCode
class Object
trait Matchable
class Any
Show all
object KeyAlreadyExists extends ErrorCode

The client requested the creation of a key which already exists, and the server will not overwrite it.

The client requested the creation of a key which already exists, and the server will not overwrite it.

Attributes

Supertypes
trait ErrorCode
class Object
trait Matchable
class Any
Self type
object KeyDoesNotExist extends ErrorCode

The client requested an operation on a key which does not exist (assuming the operation should not automatically create missing keys).

The client requested an operation on a key which does not exist (assuming the operation should not automatically create missing keys).

Attributes

Supertypes
trait ErrorCode
class Object
trait Matchable
class Any
Self type
object MalformedRequest extends ErrorCode

The client's request did not conform to the server's expectations, and could not possibly have been processed.

The client's request did not conform to the server's expectations, and could not possibly have been processed.

Attributes

Supertypes
trait ErrorCode
class Object
trait Matchable
class Any
Self type
object NodeNotFound extends ErrorCode

Thrown when a client sends an RPC request to a node which does not exist.

Thrown when a client sends an RPC request to a node which does not exist.

Attributes

Supertypes
trait ErrorCode
class Object
trait Matchable
class Any
Self type
object NotSupported extends ErrorCode

Use this error to indicate that a requested operation is not supported by the current implementation. Helpful for stubbing out APIs during development.

Use this error to indicate that a requested operation is not supported by the current implementation. Helpful for stubbing out APIs during development.

Attributes

Supertypes
trait ErrorCode
class Object
trait Matchable
class Any
Self type
object PreconditionFailed extends ErrorCode

The requested operation expected some conditions to hold, and those conditions were not met. For instance, a compare-and-set operation might assert that the value of a key is currently 5; if the value is 3, the server would return precondition-failed.

The requested operation expected some conditions to hold, and those conditions were not met. For instance, a compare-and-set operation might assert that the value of a key is currently 5; if the value is 3, the server would return precondition-failed.

Attributes

Supertypes
trait ErrorCode
class Object
trait Matchable
class Any
Self type

Indicates that the operation definitely cannot be performed at this time--perhaps because the server is in a read-only state, has not yet been initialized, believes its peers to be down, and so on. Do not use this error for indeterminate cases, when the operation may actually have taken place.

Indicates that the operation definitely cannot be performed at this time--perhaps because the server is in a read-only state, has not yet been initialized, believes its peers to be down, and so on. Do not use this error for indeterminate cases, when the operation may actually have taken place.

Attributes

Supertypes
trait ErrorCode
class Object
trait Matchable
class Any
Self type
object Timeout extends ErrorCode

Indicates that the requested operation could not be completed within a timeout.

Indicates that the requested operation could not be completed within a timeout.

Attributes

Supertypes
trait ErrorCode
class Object
trait Matchable
class Any
Self type
Timeout.type
object TxnConflict extends ErrorCode

The requested transaction has been aborted because of a conflict with another transaction. Servers need not return this error on every conflict: they may choose to retry automatically instead.

The requested transaction has been aborted because of a conflict with another transaction. Servers need not return this error on every conflict: they may choose to retry automatically instead.

Attributes

Supertypes
trait ErrorCode
class Object
trait Matchable
class Any
Self type

Inherited types

type MirroredElemLabels <: Tuple

The names of the product elements

The names of the product elements

Attributes

Inherited from:
Mirror
type MirroredLabel <: String

The name of the type

The name of the type

Attributes

Inherited from:
Mirror

Givens

Givens