Documentation ¶
Index ¶
- func CleanupStandaloneAddressFile(info ServerSettings) error
- func CleanupStandalonePIDFile(info ServerSettings) error
- func CreateStandaloneAddressFile(address, dir string) error
- func CreateStandalonePIDFile(pid int, dir string) error
- func FindAndKillCurrentPlugin(dir string)
- func RunDummyPluginLocator(address string)
- type ClientSettings
- type ServerSettings
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CleanupStandaloneAddressFile ¶ added in v0.156.0
func CleanupStandaloneAddressFile(info ServerSettings) error
CleanupStandaloneAddressFile attempts to delete standalone.txt from the specified folder. If the file does not exist, the function returns nil.
func CleanupStandalonePIDFile ¶ added in v0.156.0
func CleanupStandalonePIDFile(info ServerSettings) error
CleanupStandalonePIDFile attempts to delete pid.txt from the specified folder. If the file does not exist, the function returns nil.
func CreateStandaloneAddressFile ¶ added in v0.156.0
CreateStandaloneAddressFile creates the standalone.txt file containing the address of the GRPC server
func CreateStandalonePIDFile ¶ added in v0.156.0
CreateStandalonePIDFile creates the pid.txt file containing the PID of the GRPC server process
func FindAndKillCurrentPlugin ¶ added in v0.156.0
func FindAndKillCurrentPlugin(dir string)
FindAndKillCurrentPlugin kills the currently registered plugin, causing Grafana to restart it and connect to our new host.
func RunDummyPluginLocator ¶
func RunDummyPluginLocator(address string)
RunDummyPluginLocator runs the standalone server locator that Grafana uses to connect to the standalone GRPC server.
Types ¶
type ClientSettings ¶ added in v0.165.0
func ClientModeEnabled ¶ added in v0.165.0
func ClientModeEnabled(pluginID string) (ClientSettings, bool)
ClientModeEnabled returns standalone server connection settings if a standalone server is running and can be reached.
type ServerSettings ¶ added in v0.165.0
func NewServerSettings ¶ added in v0.165.0
func NewServerSettings(address, dir string) ServerSettings
func ServerModeEnabled ¶ added in v0.165.0
func ServerModeEnabled(pluginID string) (ServerSettings, bool)
ServerModeEnabled returns true if the plugin should run in standalone server mode.