Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Descriptor ¶
type Descriptor struct {
// contains filtered or unexported fields
}
Descriptor loads descriptor from a service/project
func NewDescriptor ¶
func NewDescriptor() *Descriptor
func (*Descriptor) GetAllMessages ¶
func (s *Descriptor) GetAllMessages() []string
GetAllMessages returns all available messages
func (*Descriptor) GetAllMethods ¶
func (s *Descriptor) GetAllMethods() []string
GetAllMethods returns all available methods
func (*Descriptor) GetMessage ¶
func (s *Descriptor) GetMessage(ctx context.Context, name string) (*desc.MessageDescriptor, error)
GetMessage gets message descriptor
func (*Descriptor) GetMethod ¶
func (s *Descriptor) GetMethod(ctx context.Context, methodPath string) (*desc.MethodDescriptor, error)
GetMethod gets method descriptor methodPath: full path of method, format must be /<service-name>/<method-name> for example: /offers.v1.OfferService/ValidateOffer
type HealthService ¶
type HealthService struct{}
HealthService defines health check service
func (*HealthService) Check ¶
func (s *HealthService) Check(_ context.Context, req *health.HealthCheckRequest) (*health.HealthCheckResponse, error)
Check checks server status
func (*HealthService) Watch ¶
func (s *HealthService) Watch(_ *health.HealthCheckRequest, server health.Health_WatchServer) error
Watch performs a streaming health-check
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server serves grpc incoming requests
func NewServer ¶
func NewServer(stubStore rio.StubStore, fileStorage fs.FileStorage, descriptor *ServiceDescriptor) *Server
type ServiceDescriptor ¶
type ServiceDescriptor struct {
// contains filtered or unexported fields
}
ServiceDescriptor manages descriptor for all services/projects Each grpc service has a different proto definitions and dependencies These proto files must be compressed into a zip file and uploaded to server
func NewServiceDescriptor ¶
func NewServiceDescriptor(fileStorage fs.FileStorage) *ServiceDescriptor
func (*ServiceDescriptor) ClearCache ¶
func (p *ServiceDescriptor) ClearCache(ctx context.Context) error
ClearCache clear cached files
func (*ServiceDescriptor) GetDescriptor ¶
func (p *ServiceDescriptor) GetDescriptor(ctx context.Context, protoFileID string) (*Descriptor, error)
GetDescriptor loads service descriptors from a file storage