jmxtool

package
v1.5.0 Latest Latest
Warning

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

Go to latest
Published: Mar 3, 2022 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func JSONToKVMap added in v1.2.0

func JSONToKVMap(jsonStr string) (map[string]string, error)

JSONToKVMap converts JSON string to key value pairs

Types

type APIErr

type APIErr struct {
	Code    int    `yaml:"code"`
	Message string `yaml:"message"`
}

APIErr is the error struct for API

type AgentClient

type AgentClient struct {
	URL        string
	HTTPClient *http.Client
}

AgentClient stores the information of agent client

func NewAgentClient

func NewAgentClient(host, port string) *AgentClient

NewAgentClient creates the agent client

func (*AgentClient) UpdateGlobalTransmission added in v1.4.1

func (agent *AgentClient) UpdateGlobalTransmission(transmission *spec.GlobalTransmission) error

UpdateGlobalTransmission updates GlobalTransmission.

func (*AgentClient) UpdateService

func (agent *AgentClient) UpdateService(newService *spec.Service, version int64) error

UpdateService updates service.

type AgentInterface

type AgentInterface interface {
	UpdateService(newService *spec.Service, version int64) error
	UpdateGlobalTransmission(transmission *spec.GlobalTransmission) error
}

AgentInterface is the interface operate the agent client

Jump to

Keyboard shortcuts

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