Files
PandaX/pkg/transport/transport.go
2022-08-03 16:00:32 +08:00

20 lines
248 B
Go

package transport
import (
"context"
)
type Type string
const (
TypeHTTP Type = "HTTP"
TypeGRPC Type = "GRPC"
)
// Server is transport server.
type Server interface {
Type() Type
Start(context.Context) error
Stop(context.Context) error
}