grpcserver

package
v0.3.3 Latest Latest
Warning

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

Go to latest
Published: Sep 3, 2024 License: Apache-2.0 Imports: 8 Imported by: 1

Documentation

Overview

Package grpcserver services gRPC requests.

Index

Constants

View Source
const ComponentID = 6464

Identfier of the package found messages having the format "senzing-6464xxxx".

Variables

This section is empty.

Functions

This section is empty.

Types

type GrpcServer

type GrpcServer interface {
	GracefulStop(ctx context.Context) error
	Serve(ctx context.Context) error
}

type SimpleGrpcServer added in v0.3.2

type SimpleGrpcServer struct {
	Port          int
	ServerOptions []grpc.ServerOption
	Subject       subject.Subject
	observerpb.UnimplementedObserverServer
	// contains filtered or unexported fields
}

SimpleGrpcServer is the default implementation of the GrpcServer interface.

func (*SimpleGrpcServer) GracefulStop added in v0.3.2

func (grpcServer *SimpleGrpcServer) GracefulStop(ctx context.Context) error

The Serve method starts the gRPC server.

Input

  • ctx: A context to control lifecycle.

func (*SimpleGrpcServer) Serve added in v0.3.2

func (grpcServer *SimpleGrpcServer) Serve(ctx context.Context) error

The Serve method starts the gRPC server.

Input

  • ctx: A context to control lifecycle.

func (*SimpleGrpcServer) UpdateObserver added in v0.3.2

The UpdateObserver method is a gRPC protocol method which receives a message from a remote observer and repeats it to local observers.

Input

  • ctx: A context to control lifecycle.
  • request: Includes the message to send to Observers.

Output

  • Empty response
  • Error

Jump to

Keyboard shortcuts

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