Documentation ¶
Index ¶
- Constants
- func DSQuery(q Query) dsq.Query
- func DefaultUserPrefix(req *Request, reply *ReplyMessage) bool
- func NewStoreClient(ctx context.Context, src host.Host, target peer.AddrInfo, pid protocol.ID, ...) core.RemoteDataNodeClient
- func NewStoreServer(ctx context.Context, h host.Host, pid protocol.ID, ds, fds ds.Datastore, ...) core.DataNodeServer
- func ReadQueryResultEntry(s network.Stream, msg *QueryResultEntry, timeout int) error
- func ReadReplyMsg(s network.Stream, msg *ReplyMessage, timeout int) error
- func ReadRequestMsg(s network.Stream, msg *RequestMessage, timeout int) error
- func WriteQueryResultEntry(s network.Stream, msg *QueryResultEntry, timeout int) error
- func WriteReplyMsg(s network.Stream, msg *ReplyMessage, timeout int) error
- func WriteRequstMsg(s network.Stream, msg *RequestMessage, timeout int) error
- type Act
- type ErrCode
- type Interceptor
- type Query
- type QueryResultEntry
- type ReplyMessage
- type Request
- type RequestMessage
Constants ¶
View Source
const ( PROTOCOL_V1 = "/cluster/remoteds/0.0.1" PREFIX = "remoteds" )
View Source
const AuthFailed = "unauthorized access denied"
View Source
const EOF = "query result finished"
Variables ¶
This section is empty.
Functions ¶
func DefaultUserPrefix ¶ added in v0.0.7
func DefaultUserPrefix(req *Request, reply *ReplyMessage) bool
func NewStoreClient ¶
func NewStoreServer ¶
func ReadQueryResultEntry ¶
func ReadQueryResultEntry(s network.Stream, msg *QueryResultEntry, timeout int) error
func ReadReplyMsg ¶
func ReadReplyMsg(s network.Stream, msg *ReplyMessage, timeout int) error
func ReadRequestMsg ¶
func ReadRequestMsg(s network.Stream, msg *RequestMessage, timeout int) error
func WriteQueryResultEntry ¶
func WriteQueryResultEntry(s network.Stream, msg *QueryResultEntry, timeout int) error
func WriteReplyMsg ¶
func WriteReplyMsg(s network.Stream, msg *ReplyMessage, timeout int) error
func WriteRequstMsg ¶
func WriteRequstMsg(s network.Stream, msg *RequestMessage, timeout int) error
Types ¶
type Interceptor ¶ added in v0.0.7
type Interceptor func(req *Request, reply *ReplyMessage) bool
Interceptor if return true, than send ReplyMessage to sender and skip the next processing
type QueryResultEntry ¶
func (*QueryResultEntry) MarshalCBOR ¶
func (t *QueryResultEntry) MarshalCBOR(w io.Writer) error
func (*QueryResultEntry) UnmarshalCBOR ¶
func (t *QueryResultEntry) UnmarshalCBOR(r io.Reader) error
type ReplyMessage ¶
func (*ReplyMessage) MarshalCBOR ¶
func (t *ReplyMessage) MarshalCBOR(w io.Writer) error
func (*ReplyMessage) UnmarshalCBOR ¶
func (t *ReplyMessage) UnmarshalCBOR(r io.Reader) error
type Request ¶ added in v0.0.7
type Request struct { *RequestMessage InnerFileKey string InnerFilePrefix string }
type RequestMessage ¶
func (*RequestMessage) MarshalCBOR ¶
func (t *RequestMessage) MarshalCBOR(w io.Writer) error
func (*RequestMessage) UnmarshalCBOR ¶
func (t *RequestMessage) UnmarshalCBOR(r io.Reader) error
Click to show internal directories.
Click to hide internal directories.