grpc

package
v0.23.3-dev.0 Latest Latest
Warning

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

Go to latest
Published: May 20, 2024 License: AGPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func HandleStartFailure

func HandleStartFailure(err error) error

HandleStartFailure is used to handle errors when starting both Steampipe plugins an dthe plugin manage (which is itself a GRPC plugin)

When starting a GRPC plugin, a specific handshake sequence is expected on stdout. (This is automatically written in the case of a successfulty startup) If the handshae is missing (because the startup failed or anything else was written to stdout) we get the error "Unrecognized remote plugin message"

If the plugin startup fails with an error panic, it constructs a message string starting with the prefix "Plugin startup failed: " , detailing the error.

This function checks whether the error returned from startup is "Unrecognized remote plugin message", and if so, it looks for ""Plugin startup failed: " in the plugin message and if found, extracts the underlying error message. This is returnerd as an error

Types

This section is empty.

Directories

Path Synopsis
Package shared contains shared data between the host and plugins.
Package shared contains shared data between the host and plugins.

Jump to

Keyboard shortcuts

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