Documentation
¶
Index ¶
- Constants
- Variables
- type GRPCClient
- type GRPCPlugin
- type GRPCServer
- func (g *GRPCServer) Init(_ context.Context, config *plugininterface.Config) (*plugininterface.InitResponse, error)
- func (g *GRPCServer) Name(_ context.Context, _ *plugininterface.Empty) (*plugininterface.NameResponse, error)
- func (g *GRPCServer) ParseOutput(_ context.Context, _ *plugininterface.Empty) (*plugininterface.ParseOutputResponse, error)
- func (g *GRPCServer) Run(_ context.Context, _ *plugininterface.Empty) (*plugininterface.RunResponse, error)
- func (g *GRPCServer) Version(_ context.Context, _ *plugininterface.Empty) (*plugininterface.VersionResponse, error)
- type IPlugin
Constants ¶
View Source
const (
ApplicationResponseSuccess string = "no_error"
)
Variables ¶
View Source
var Handshake = plugin.HandshakeConfig{
ProtocolVersion: 1,
MagicCookieKey: "BASIC_PLUGIN",
MagicCookieValue: "hello",
}
Handshake is a common handshake that is shared by plugin and host.
View Source
var PluginMap = map[string]plugin.Plugin{ "plugin_grpc": &GRPCPlugin{}, }
PluginMap is the map of plugins we can dispense.
Functions ¶
This section is empty.
Types ¶
type GRPCClient ¶ added in v1.0.5
type GRPCClient struct {
// contains filtered or unexported fields
}
func (*GRPCClient) Name ¶ added in v1.0.5
func (g *GRPCClient) Name() (string, error)
func (*GRPCClient) ParseOutput ¶ added in v1.0.5
func (g *GRPCClient) ParseOutput() (string, error)
func (*GRPCClient) Run ¶ added in v1.0.5
func (g *GRPCClient) Run() error
func (*GRPCClient) Version ¶ added in v1.0.5
func (g *GRPCClient) Version() (string, error)
type GRPCPlugin ¶ added in v1.0.5
type GRPCPlugin struct {
// GRPCPlugin must still implement the Plugin interface
plugin.Plugin
// Concrete implementation, written in Go. This is only used for plugins
// that are written in Go.
Impl IPlugin
}
func (*GRPCPlugin) GRPCClient ¶ added in v1.0.5
func (p *GRPCPlugin) GRPCClient(ctx context.Context, broker *plugin.GRPCBroker, c *grpc.ClientConn) (interface{}, error)
func (*GRPCPlugin) GRPCServer ¶ added in v1.0.5
func (p *GRPCPlugin) GRPCServer(broker *plugin.GRPCBroker, s *grpc.Server) error
type GRPCServer ¶ added in v1.0.5
type GRPCServer struct {
plugininterface.UnimplementedHypothesisServer
Impl IPlugin
// contains filtered or unexported fields
}
func (*GRPCServer) Init ¶ added in v1.0.5
func (g *GRPCServer) Init(_ context.Context, config *plugininterface.Config) (*plugininterface.InitResponse, error)
func (*GRPCServer) Name ¶ added in v1.0.5
func (g *GRPCServer) Name(_ context.Context, _ *plugininterface.Empty) (*plugininterface.NameResponse, error)
func (*GRPCServer) ParseOutput ¶ added in v1.0.5
func (g *GRPCServer) ParseOutput(_ context.Context, _ *plugininterface.Empty) (*plugininterface.ParseOutputResponse, error)
func (*GRPCServer) Run ¶ added in v1.0.5
func (g *GRPCServer) Run(_ context.Context, _ *plugininterface.Empty) (*plugininterface.RunResponse, error)
func (*GRPCServer) Version ¶ added in v1.0.5
func (g *GRPCServer) Version(_ context.Context, _ *plugininterface.Empty) (*plugininterface.VersionResponse, error)
Click to show internal directories.
Click to hide internal directories.