Documentation ¶
Index ¶
- Constants
- Variables
- func BytesToInt(data []byte) (ret int64, err error)
- func CheckFatalError(err error)
- func Int64ToBytes(v int64) ([]byte, error)
- func MustInt64ToBytes(v int64) []byte
- func NodeResolveId(nID string, nMap *map[string]string) (string, error)
- func PreparePayload(src []byte) (prop []byte)
- func ResolveCounterIRI(tCounter *pb.Counter, nMap *map[string]string, p *perms.Count) (iri.BaseCounter, error)
- func ResolveMetaIRI(tMeta *pb.Meta, nMap *map[string]string, p *perms.Meta) (iri.IRI, error)
- type CDSCabinetServer
- func (s *CDSCabinetServer) CounterGet(ctx context.Context, counter *pb.Counter) (*pb.CounterValueResponse, error)
- func (s *CDSCabinetServer) EdgeGet(ctx context.Context, edge *pb.EdgeGetRequest) (*pb.Edge, error)
- func (s *CDSCabinetServer) EdgeList(edgeRq *pb.EdgeListRequest, stream pb.CDSCabinet_EdgeListServer) error
- func (s *CDSCabinetServer) IndexChoices(indexRq *pb.IndexChoiceRequest, stream pb.CDSCabinet_IndexChoicesServer) error
- func (s *CDSCabinetServer) IndexDrop(ctx context.Context, index *pb.IndexDropRequest) (*pb.MutationResponse, error)
- func (s *CDSCabinetServer) IndexGet(ctx context.Context, indexGet *pb.IndexGetRequest) (*pb.Index, error)
- func (s *CDSCabinetServer) IndexList(indexRq *pb.IndexListRequest, stream pb.CDSCabinet_IndexListServer) error
- func (s *CDSCabinetServer) MetaGet(ctx context.Context, meta *pb.Meta) (*pb.MetaGetResponse, error)
- func (s *CDSCabinetServer) MetaList(metaRq *pb.MetaListRequest, stream pb.CDSCabinet_MetaListServer) error
- func (s *CDSCabinetServer) NodeGet(ctx context.Context, nodeRq *pb.NodeGetRequest) (*pb.Node, error)
- func (s *CDSCabinetServer) NodeList(nodeRq *pb.NodeListRequest, stream pb.CDSCabinet_NodeListServer) error
- func (s *CDSCabinetServer) ReadCheck(ctx context.Context, rcRq *pb.ReadCheckRequest) (*pb.ReadCheckResponse, error)
- func (s *CDSCabinetServer) SequentialCreate(ctx context.Context, seq *pb.Sequential) (newSeq *pb.Sequential, err error)
- func (s *CDSCabinetServer) SequentialDelete(ctx context.Context, seq *pb.Sequential) (*pb.MutationResponse, error)
- func (s *CDSCabinetServer) SequentialGet(ctx context.Context, seq *pb.Sequential) (*pb.Sequential, error)
- func (s *CDSCabinetServer) SequentialList(seqRq *pb.SequentialListRequest, stream pb.CDSCabinet_SequentialListServer) error
- func (s *CDSCabinetServer) Transaction(bStream pb.CDSCabinet_TransactionServer) error
- type KeyReport
- type KeyReportClass
- type TransactionOperation
- func (o *TransactionOperation) CounterDelete(counter *pb.Counter) error
- func (o *TransactionOperation) CounterIncrement(counter *pb.Counter) error
- func (o *TransactionOperation) CounterRegister(counter *pb.Counter) error
- func (o *TransactionOperation) EdgeClear(edge *pb.Edge) error
- func (o *TransactionOperation) EdgeDelete(edge *pb.Edge) error
- func (o *TransactionOperation) EdgeUpdate(edge *pb.Edge) error
- func (o *TransactionOperation) IndexCreate(index *pb.Index) error
- func (o *TransactionOperation) IndexDelete(index *pb.Index) error
- func (o *TransactionOperation) MetaClear(meta *pb.Meta) error
- func (o *TransactionOperation) MetaDelete(meta *pb.Meta) error
- func (o *TransactionOperation) MetaUpdate(meta *pb.Meta) error
- func (o *TransactionOperation) NodeCreate(node *pb.Node) error
- func (o *TransactionOperation) NodeDelete(node *pb.Node) error
- func (o *TransactionOperation) NodeUpdate(node *pb.Node) error
- func (o *TransactionOperation) ReadCheck(rc *pb.ReadCheckRequest) error
Constants ¶
View Source
const ( //RPCError RPCErrorInvalidAction = "E(0x001) Unknown TransactionAction" RPCErrorRepeatAction = "E(0x002) Repeat actionId in transaction" RPCErrorArgumentInvalid = "E(0x003) One or more arguments are invalid (generic)" RPCErrorInvalidIRI = "E(0x004) Invalid IRI (generic)" RPCErrorNotFound = "E(0x005) Requested record not found" RPCErrorFieldRequired = "E(0x006) Field %s is required" RPCErrorFieldUnexpected = "E(0x007) Field %s is unexpected" RPCErrorFieldSpecific = "E(0x008) Error %s on %s" RPCErrorDataCorrupted = "E(0x009) Data is corrupted on %s" RPCErrorDuplicateRecord = "E(0x010) Requested record already exists" RPCErrorIRISpecific = "E(0x011) IRI: %s" RPCErrorListIterator = "E(0x012) List iteration failed" RPCErrorReadCheck = "E(0x013) ReadCheck failure in transaction" RPCErrorServer = "E(0x014) Server processing error" )
RPC Errors Returned by gRPC, standardized on E(0xYYY)
View Source
const (
DebugServerRequests = true
)
View Source
const (
KeyReportBelowZero = KeyReportClass(0)
)
Variables ¶
View Source
var CounterKeys = map[int]string{
0: "0",
1: "1",
2: "2",
3: "3",
4: "4",
5: "5",
6: "6",
7: "7",
8: "8",
9: "9",
10: "a",
11: "b",
12: "c",
13: "d",
14: "e",
15: "f",
}
Functions ¶
func BytesToInt ¶
func CheckFatalError ¶
func CheckFatalError(err error)
func Int64ToBytes ¶
func MustInt64ToBytes ¶
func PreparePayload ¶
func ResolveCounterIRI ¶
Types ¶
type CDSCabinetServer ¶
type CDSCabinetServer struct { Version int32 // contains filtered or unexported fields }
func StartServer ¶
func StartServer() *CDSCabinetServer
func (*CDSCabinetServer) CounterGet ¶
func (s *CDSCabinetServer) CounterGet(ctx context.Context, counter *pb.Counter) (*pb.CounterValueResponse, error)
func (*CDSCabinetServer) EdgeGet ¶
func (s *CDSCabinetServer) EdgeGet(ctx context.Context, edge *pb.EdgeGetRequest) (*pb.Edge, error)
func (*CDSCabinetServer) EdgeList ¶
func (s *CDSCabinetServer) EdgeList(edgeRq *pb.EdgeListRequest, stream pb.CDSCabinet_EdgeListServer) error
func (*CDSCabinetServer) IndexChoices ¶
func (s *CDSCabinetServer) IndexChoices(indexRq *pb.IndexChoiceRequest, stream pb.CDSCabinet_IndexChoicesServer) error
func (*CDSCabinetServer) IndexDrop ¶
func (s *CDSCabinetServer) IndexDrop(ctx context.Context, index *pb.IndexDropRequest) (*pb.MutationResponse, error)
func (*CDSCabinetServer) IndexGet ¶
func (s *CDSCabinetServer) IndexGet(ctx context.Context, indexGet *pb.IndexGetRequest) (*pb.Index, error)
func (*CDSCabinetServer) IndexList ¶
func (s *CDSCabinetServer) IndexList(indexRq *pb.IndexListRequest, stream pb.CDSCabinet_IndexListServer) error
func (*CDSCabinetServer) MetaGet ¶
func (s *CDSCabinetServer) MetaGet(ctx context.Context, meta *pb.Meta) (*pb.MetaGetResponse, error)
func (*CDSCabinetServer) MetaList ¶
func (s *CDSCabinetServer) MetaList(metaRq *pb.MetaListRequest, stream pb.CDSCabinet_MetaListServer) error
func (*CDSCabinetServer) NodeGet ¶
func (s *CDSCabinetServer) NodeGet(ctx context.Context, nodeRq *pb.NodeGetRequest) (*pb.Node, error)
func (*CDSCabinetServer) NodeList ¶
func (s *CDSCabinetServer) NodeList(nodeRq *pb.NodeListRequest, stream pb.CDSCabinet_NodeListServer) error
func (*CDSCabinetServer) ReadCheck ¶
func (s *CDSCabinetServer) ReadCheck(ctx context.Context, rcRq *pb.ReadCheckRequest) (*pb.ReadCheckResponse, error)
func (*CDSCabinetServer) SequentialCreate ¶
func (s *CDSCabinetServer) SequentialCreate(ctx context.Context, seq *pb.Sequential) (newSeq *pb.Sequential, err error)
func (*CDSCabinetServer) SequentialDelete ¶
func (s *CDSCabinetServer) SequentialDelete(ctx context.Context, seq *pb.Sequential) (*pb.MutationResponse, error)
func (*CDSCabinetServer) SequentialGet ¶
func (s *CDSCabinetServer) SequentialGet(ctx context.Context, seq *pb.Sequential) (*pb.Sequential, error)
func (*CDSCabinetServer) SequentialList ¶
func (s *CDSCabinetServer) SequentialList(seqRq *pb.SequentialListRequest, stream pb.CDSCabinet_SequentialListServer) error
func (*CDSCabinetServer) Transaction ¶
func (s *CDSCabinetServer) Transaction(bStream pb.CDSCabinet_TransactionServer) error
type KeyReport ¶
type KeyReport struct {
// contains filtered or unexported fields
}
func NewKeyReport ¶
func NewKeyReport(class KeyReportClass, request interface{}, err string, key []byte, value []byte) *KeyReport
type KeyReportClass ¶
type KeyReportClass uint8
type TransactionOperation ¶
type TransactionOperation struct { IdMap map[string]string UsedActions map[uint32]bool // contains filtered or unexported fields }
func (*TransactionOperation) CounterDelete ¶
func (o *TransactionOperation) CounterDelete(counter *pb.Counter) error
func (*TransactionOperation) CounterIncrement ¶
func (o *TransactionOperation) CounterIncrement(counter *pb.Counter) error
func (*TransactionOperation) CounterRegister ¶
func (o *TransactionOperation) CounterRegister(counter *pb.Counter) error
func (*TransactionOperation) EdgeClear ¶
func (o *TransactionOperation) EdgeClear(edge *pb.Edge) error
func (*TransactionOperation) EdgeDelete ¶
func (o *TransactionOperation) EdgeDelete(edge *pb.Edge) error
func (*TransactionOperation) EdgeUpdate ¶
func (o *TransactionOperation) EdgeUpdate(edge *pb.Edge) error
func (*TransactionOperation) IndexCreate ¶
func (o *TransactionOperation) IndexCreate(index *pb.Index) error
func (*TransactionOperation) IndexDelete ¶
func (o *TransactionOperation) IndexDelete(index *pb.Index) error
func (*TransactionOperation) MetaClear ¶
func (o *TransactionOperation) MetaClear(meta *pb.Meta) error
func (*TransactionOperation) MetaDelete ¶
func (o *TransactionOperation) MetaDelete(meta *pb.Meta) error
func (*TransactionOperation) MetaUpdate ¶
func (o *TransactionOperation) MetaUpdate(meta *pb.Meta) error
func (*TransactionOperation) NodeCreate ¶
func (o *TransactionOperation) NodeCreate(node *pb.Node) error
func (*TransactionOperation) NodeDelete ¶
func (o *TransactionOperation) NodeDelete(node *pb.Node) error
func (*TransactionOperation) NodeUpdate ¶
func (o *TransactionOperation) NodeUpdate(node *pb.Node) error
func (*TransactionOperation) ReadCheck ¶
func (o *TransactionOperation) ReadCheck(rc *pb.ReadCheckRequest) error
Source Files ¶
- bytes.go
- counter_delete.go
- counter_get.go
- counter_increment.go
- counter_register.go
- edge_clear.go
- edge_delete.go
- edge_get.go
- edge_list.go
- edge_update.go
- errors.go
- index_choices.go
- index_create.go
- index_delete.go
- index_drop.go
- index_get.go
- index_list.go
- main.go
- meta_clear.go
- meta_delete.go
- meta_get.go
- meta_list.go
- meta_update.go
- node_create.go
- node_delete.go
- node_get.go
- node_list.go
- node_update.go
- read_check.go
- resolvers.go
- sequential_create.go
- sequential_delete.go
- sequential_get.go
- sequential_list.go
- sequential_validator.go
- transaction.go
- transaction_base.go
- transaction_read_check.go
Click to show internal directories.
Click to hide internal directories.