Documentation ¶
Index ¶
Constants ¶
View Source
const ( ResponseStatusNoErr = 0x0000 ResponseStatusKeyNotFound = 0x0001 ResponseStatusKeyExists = 0x0002 ResponseStatusValueTooLarge = 0x0003 ResponseStatusInvalidArg = 0x0004 ResponseStatusItemNotStored = 0x0005 ResponseStatusNonNumeric = 0x0006 ResponseStatusUnknownCmd = 0x0081 ResponseStatusOutOfMem = 0x0082 ResponseStatusNotSupported = 0x0083 ResponseStatusInternalErr = 0x0084 ResponseStatusBusy = 0x0085 ResponseStatusTemporary = 0x0086 )
all memcache response status
Variables ¶
View Source
var ( // ERROR means the client sent a nonexistent command name. ErrError = errs.New("ERROR") // CLIENT_ERROR // means some sort of client error in the input line, i.e. the input // doesn't conform to the protocol in some way. <error> is a // human-readable error string. ErrBadRequest = errs.New("CLIENT_ERROR bad request") ErrBadLength = errs.New("CLIENT_ERROR length is not a valid integer") // SERVER_ERROR // means some sort of server error prevents the server from carrying // out the command. <error> is a human-readable error string. In cases // of severe server errors, which make it impossible to continue // serving the client (this shouldn't normally happen), the server will // close the connection after sending the error line. This is the only // case in which the server closes a connection to a client. ErrClosed = errs.New("SERVER_ERROR connection closed") ErrPingerPong = errs.New("SERVER_ERROR Pinger pong unexpected") ErrAssertReq = errs.New("SERVER_ERROR assert request not ok") ErrBadResponse = errs.New("SERVER_ERROR bad response") )
errors
Functions ¶
Types ¶
type MCRequest ¶
type MCRequest struct {
// contains filtered or unexported fields
}
MCRequest is the mc client Msg type and data.
type RequestType ¶
type RequestType byte
RequestType is the protocol-agnostic identifier for the command
const ( RequestTypeGet RequestType = 0x00 RequestTypeSet RequestType = 0x01 RequestTypeAdd RequestType = 0x02 RequestTypeReplace RequestType = 0x03 RequestTypeDelete RequestType = 0x04 RequestTypeIncr RequestType = 0x05 RequestTypeDecr RequestType = 0x06 RequestTypeGetQ RequestType = 0x09 RequestTypeNoop RequestType = 0x0a RequestTypeGetK RequestType = 0x0c RequestTypeGetKQ RequestType = 0x0d RequestTypeAppend RequestType = 0x0e RequestTypePrepend RequestType = 0x0f // RequestTypeSetQ = 0x11 // RequestTypeAddQ = 0x12 // RequestTypeReplaceQ = 0x13 // RequestTypeIncrQ = 0x15 // RequestTypeDecrQ = 0x16 // RequestTypeAppendQ = 0x19 // RequestTypePrependQ = 0x1a RequestTypeTouch RequestType = 0x1c RequestTypeGat RequestType = 0x1d // RequestTypeGatQ = 0x1e RequestTypeUnknown RequestType = 0xff )
all memcache request type
type ResponseStatus ¶ added in v1.3.2
type ResponseStatus byte
ResponseStatus is the protocol-agnostic identifier for the response status
Click to show internal directories.
Click to hide internal directories.