grpc

package
v4.0.0-rc4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 15, 2022 License: AGPL-3.0 Imports: 26 Imported by: 0

Documentation

Overview

Package grpc provides a GRPC service for aggregating all indexes from all datasources

Index

Constants

This section is empty.

Variables

View Source
var (
	UnitTests = false
)

Functions

This section is empty.

Types

type DataSource

type DataSource struct {
	Name string
	// contains filtered or unexported fields
}

func NewDataSource

func NewDataSource(name string, reader tree.NodeProviderClient, writer tree.NodeReceiverClient) DataSource

type EventSubscriber

type EventSubscriber struct {
	TreeServer *TreeServer
	// contains filtered or unexported fields
}

func NewEventSubscriber

func NewEventSubscriber(t *TreeServer) (*EventSubscriber, error)

func (*EventSubscriber) Handle

Handle incoming INDEX events and resend them as TREE events. Events that carry an XPydioMoveUuid metadata are enqueued in a cache to re-create CREATE+DELETE pairs across datasources.

type StreamConverter

type StreamConverter struct {
	// contains filtered or unexported fields
}

StreamConverter wraps a Searcher_SearchStream into a NodesProvider_ListNodesStream

func (*StreamConverter) Context

func (sc *StreamConverter) Context() context.Context

func (*StreamConverter) RecvMsg

func (sc *StreamConverter) RecvMsg(i interface{}) error

func (*StreamConverter) Send

func (sc *StreamConverter) Send(response *tree.ListNodesResponse) error

func (*StreamConverter) SendHeader

func (sc *StreamConverter) SendHeader(md metadata.MD) error

func (*StreamConverter) SendMsg

func (sc *StreamConverter) SendMsg(i interface{}) error

func (*StreamConverter) SetHeader

func (sc *StreamConverter) SetHeader(md metadata.MD) error

func (*StreamConverter) SetTrailer

func (sc *StreamConverter) SetTrailer(md metadata.MD)

type TreeServer

func (*TreeServer) CreateNode

CreateNode implementation for the TreeServer

func (*TreeServer) DeleteNode

DeleteNode implementation for the TreeServer

func (*TreeServer) ListNodes

func (*TreeServer) ListNodesWithLimit

func (s *TreeServer) ListNodesWithLimit(ctx context.Context, metaStreamer meta.Loader, req *tree.ListNodesRequest, resp tree.NodeProvider_ListNodesServer, cursorIndex *int64, numberSent *int64) error

ListNodesWithLimit implementation for the TreeServer

func (*TreeServer) Name

func (s *TreeServer) Name() string

func (*TreeServer) PublishChange

func (s *TreeServer) PublishChange(change *tree.NodeChangeEvent)

func (*TreeServer) ReadNode

ReadNode implementation for the TreeServer

func (*TreeServer) ReadNodeStream

func (s *TreeServer) ReadNodeStream(streamer tree.NodeProviderStreamer_ReadNodeStreamServer) error

ReadNodeStream Implement stream for readNode method

func (*TreeServer) Search

func (s *TreeServer) Search(request *tree.SearchRequest, stream tree.Searcher_SearchServer) error

Search implements the SearchServer handler method. It will transform a tree.SearchRequest into an underlying ListNode query

func (*TreeServer) StreamChanges

func (*TreeServer) UpdateNode

UpdateNode implementation for the TreeServer

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL