Documentation
¶
Index ¶
- type Node
- func (n *Node) CreateGRPCServer(grpcServerAddress string)
- func (fn *Node) FindAll(ctx context.Context, query *pb.Query) (*pb.FindValueResponse, error)
- func (n *Node) FindNode(ctx context.Context, target *pb.Target) (*pb.KBucket, error)
- func (fn *Node) FindValue(ctx context.Context, target *pb.Target) (*pb.FindValueResponse, error)
- func (fn *Node) GetAll(entity string, criteria string, maxResults int32) ([][]byte, error)
- func (fn *Node) GetValue(entity string, key string) ([]byte, error)
- func (fn *Node) LookUp(target []byte) ([]basic.NodeInfo, error)
- func (n *Node) Ping(ctx context.Context, sender *pb.NodeInfo) (*pb.NodeInfo, error)
- func (n *Node) PrintRoutingTable()
- func (fn *Node) Republish()
- func (n *Node) Store(ctx context.Context, data *pb.StoreData) (*pb.Response, error)
- func (fn *Node) StoreValue(entity string, key string, data *[]byte) (*[]byte, error)
- type NodeClient
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Node ¶
type Node struct { pb.UnimplementedNodeServer // contains filtered or unexported fields }
func NewNode ¶
func NewNode(nodeIP string, nodePort, bootstrapPort int, infra infrastructure.IInfrastructure, isBootstrapNode bool) *Node
func (*Node) CreateGRPCServer ¶
Create gRPC Server
func (*Node) PrintRoutingTable ¶
func (n *Node) PrintRoutingTable()
type NodeClient ¶
type NodeClient struct { pb.NodeClient IP string Port int }
func NewNodeClient ¶
func NewNodeClient(ip string, port int) (*NodeClient, error)
Click to show internal directories.
Click to hide internal directories.