grpcapi

package
v0.0.0-...-6988bd6 Latest Latest
Warning

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

Go to latest
Published: Feb 21, 2023 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateServer

func CreateServer(logger logging.Logger, repo repository.OrderRepoWith2PC) (*grpc.Server, error)

func ServeWithTrace

func ServeWithTrace(ctx context.Context, server *grpc.Server, appConfig *config.API) error

Types

type OrderService

type OrderService struct {
	pb.OrdersManagerServiceServer
	Repo repository.OrderRepoWith2PC
}

func (*OrderService) GetOrder

func (s *OrderService) GetOrder(ctx context.Context, request *pb.GetOrderRequest) (*pb.OrderResponse, error)

func (*OrderService) InsertOrder

func (s *OrderService) InsertOrder(ctx context.Context, order *pb.Order) (*pb.OrderTnxResponse, error)

type TnxConfirmingService

type TnxConfirmingService struct {
	pb.TnxConfirmingServiceServer
	Repo repository.OrderRepoWith2PC
}

func (*TnxConfirmingService) SendConfirmation

func (s *TnxConfirmingService) SendConfirmation(ctx context.Context,
	confirmation *pb.Confirmation,
) (*pb.ConfirmationResponse, error)

Jump to

Keyboard shortcuts

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