Documentation ¶
Index ¶
- type APIErr
- func NewJSONMsgDefautlDebugs(errs ...error) []*APIErr
- func NewJSONMsgDefautlErrors(errs ...error) []*APIErr
- func NewJSONMsgDefautlFatals(errs ...error) []*APIErr
- func NewJSONMsgDefautlInfos(errs ...error) []*APIErr
- func NewJSONMsgDefautlPanics(errs ...error) []*APIErr
- func NewJSONMsgDefautlWarns(errs ...error) []*APIErr
- type APIErrCode
- type APIErrs
- type APIMsg
- type APIMsgRequest
- type APIMsgResponse
- type Conformance
- type ConformanceClient
- type ConformanceServer
- type ErrSeverity
- type KV
- type KVS
- func (keyValues KVS) Copy() KVS
- func (keyValues KVS) Err() error
- func (keyValues KVS) Error() string
- func (m KVS) Fields() []a5gfields.Field
- func (keyValues KVS) KV() KV
- func (keyValues KVS) Merge(newKeyValues KVS)
- func (keyValues KVS) ResponseMessages() []*APIErr
- func (keyValues KVS) String() string
- type KVSValueBoolean
- type ResponseMessenger
- type SessionShardPayload
- type SessionShardResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APIErr ¶
type APIErr struct { Code uint64 `json:"code"` Err error `json:"message,omitempty"` Public bool `json:"-"` Severity uint64 `json:"-"` }
func NewJSONMsgDefautlDebugs ¶
func NewJSONMsgDefautlErrors ¶
func NewJSONMsgDefautlFatals ¶
func NewJSONMsgDefautlInfos ¶
func NewJSONMsgDefautlPanics ¶
func NewJSONMsgDefautlWarns ¶
func (*APIErr) MarshalJSON ¶
func (*APIErr) UnmarshalJSON ¶
type APIErrCode ¶
type APIErrCode uint64
const ( ErrCodeDefaultDebug APIErrCode = 1100 ErrCodeDefaultInfo ErrCodeDefaultWarn ErrCodeDefaultError APIErrCode = 5100 ErrCodeDefaultFatal ErrCodeDefaultPanic )
type APIMsg ¶
type APIMsg struct { Success bool `json:"success"` Errs []*APIErr `json:"messages,omitempty"` Payload interface{} `json:"payload,omitempty"` Time uint64 `json:"time,omitempty"` }
type APIMsgRequest ¶
type APIMsgRequest struct { Payload interface{} `json:"payload,omitempty"` Time uint64 `json:"time,omitempty"` }
func NewMsgRequest ¶
func NewMsgRequest( responsePayload interface{}) (*APIMsgRequest, error)
type APIMsgResponse ¶
type APIMsgResponse APIMsg
func NewMsgResponse ¶
func NewMsgResponse( debugLevel int, isSuccess bool, responsePayload interface{}, responseMessenger ResponseMessenger, errs ...*APIErr) (*APIMsgResponse, error)
type Conformance ¶
type Conformance struct { Name string `json:"name"` Server *ConformanceServer `json:"server"` API *ConformanceClient `json:"api"` }
type ConformanceClient ¶
type ConformanceClient struct {
Version string `json:"version"`
}
type ConformanceServer ¶
type ConformanceServer struct { Type string `json:"type"` ID uint64 `json:"id"` Version uint64 `json:"version"` ReleaseStage string `json:"releaseStage"` Sharded bool `json:"sharded,omitempty"` ShardsCount uint64 `json:"shardsCount,omitempty"` StartedAt string `json:"startedAt,omitempty"` Architecture string `json:"architecture"` HeartbeatMetricsEnabled bool `json:"heartbeatMetricsEnabled,omitempty"` ClientMetricsEnabled bool `json:"clientMetricsEnabled,omitempty"` }
type ErrSeverity ¶
type ErrSeverity uint64
const ( ErrSeverityUnknown ErrSeverity = iota ErrSeverityDebug ErrSeverityInfo ErrSeverityWarn ErrSeverityError ErrSeverityFatal ErrSeverityPanic )
func (ErrSeverity) ErrorDefaultCode ¶
func (v ErrSeverity) ErrorDefaultCode() uint64
func (ErrSeverity) Uint64 ¶
func (v ErrSeverity) Uint64() uint64
type KVSValueBoolean ¶
type KVSValueBoolean string
const ( KVSValBoolTrue KVSValueBoolean = "true" KVSValBoolFalse KVSValueBoolean = "false" )
func (KVSValueBoolean) String ¶
func (v KVSValueBoolean) String() string
type ResponseMessenger ¶
type ResponseMessenger interface {
ResponseMessages() []*APIErr
}
type SessionShardPayload ¶
type SessionShardPayload struct {
UserDataVersion uint64 `json:"userDataVersion,omitempty"`
}
func (*SessionShardPayload) IsUserDataVersionPresent ¶
func (v *SessionShardPayload) IsUserDataVersionPresent() bool
type SessionShardResponse ¶
type SessionShardResponse struct { APIMsg Payload *SessionShardPayload `json:"payload,omitempty"` }
Click to show internal directories.
Click to hide internal directories.