Documentation
¶
Index ¶
- Constants
- type Client
- type RegisterBody
- type RegisterDefault
- type RegisterDefaultBody
- type RegisterOK
- type RegisterOKBody
- type RegisterOKBodyContainerNode
- type RegisterOKBodyGenericNode
- type RegisterOKBodyPMMAgent
- type RegisterParams
- func (o *RegisterParams) SetBody(body RegisterBody)
- func (o *RegisterParams) SetContext(ctx context.Context)
- func (o *RegisterParams) SetHTTPClient(client *http.Client)
- func (o *RegisterParams) SetTimeout(timeout time.Duration)
- func (o *RegisterParams) WithBody(body RegisterBody) *RegisterParams
- func (o *RegisterParams) WithContext(ctx context.Context) *RegisterParams
- func (o *RegisterParams) WithHTTPClient(client *http.Client) *RegisterParams
- func (o *RegisterParams) WithTimeout(timeout time.Duration) *RegisterParams
- func (o *RegisterParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
- type RegisterReader
Constants ¶
const ( // RegisterBodyNodeTypeNODETYPEINVALID captures enum value "NODE_TYPE_INVALID" RegisterBodyNodeTypeNODETYPEINVALID string = "NODE_TYPE_INVALID" // RegisterBodyNodeTypeGENERICNODE captures enum value "GENERIC_NODE" RegisterBodyNodeTypeGENERICNODE string = "GENERIC_NODE" // RegisterBodyNodeTypeCONTAINERNODE captures enum value "CONTAINER_NODE" RegisterBodyNodeTypeCONTAINERNODE string = "CONTAINER_NODE" // RegisterBodyNodeTypeREMOTENODE captures enum value "REMOTE_NODE" RegisterBodyNodeTypeREMOTENODE string = "REMOTE_NODE" // RegisterBodyNodeTypeREMOTEAMAZONRDSNODE captures enum value "REMOTE_AMAZON_RDS_NODE" RegisterBodyNodeTypeREMOTEAMAZONRDSNODE string = "REMOTE_AMAZON_RDS_NODE" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client for node API
func New ¶
func New(transport runtime.ClientTransport, formats strfmt.Registry) *Client
New creates a new node API client.
func (*Client) Register ¶
func (a *Client) Register(params *RegisterParams) (*RegisterOK, error)
Register registers registers a new node and pmm agent
func (*Client) SetTransport ¶
func (a *Client) SetTransport(transport runtime.ClientTransport)
SetTransport changes the transport on the client
type RegisterBody ¶
type RegisterBody struct {
// Address FIXME https://jira.percona.com/browse/PMM-3786
Address string `json:"address,omitempty"`
// Node availability zone.
Az string `json:"az,omitempty"`
// Container identifier. If specified, must be a unique Docker container identifier.
ContainerID string `json:"container_id,omitempty"`
// Container name.
ContainerName string `json:"container_name,omitempty"`
// Custom user-assigned labels.
CustomLabels map[string]string `json:"custom_labels,omitempty"`
// Linux distribution name and version.
Distro string `json:"distro,omitempty"`
// Linux machine-id.
// Must be unique across all Generic Nodes if specified.
MachineID string `json:"machine_id,omitempty"`
// Node model.
NodeModel string `json:"node_model,omitempty"`
// Unique across all Nodes user-defined name. Can't be changed.
NodeName string `json:"node_name,omitempty"`
// NodeType describes supported Node types.
// Enum: [NODE_TYPE_INVALID GENERIC_NODE CONTAINER_NODE REMOTE_NODE REMOTE_AMAZON_RDS_NODE]
NodeType *string `json:"node_type,omitempty"`
// Node region.
Region string `json:"region,omitempty"`
// If true, and Node with that name already exist, it will be removed with all dependent Services and Agents.
Reregister bool `json:"reregister,omitempty"`
}
RegisterBody register body swagger:model RegisterBody
func (*RegisterBody) MarshalBinary ¶
func (o *RegisterBody) MarshalBinary() ([]byte, error)
MarshalBinary interface implementation
func (*RegisterBody) UnmarshalBinary ¶
func (o *RegisterBody) UnmarshalBinary(b []byte) error
UnmarshalBinary interface implementation
type RegisterDefault ¶
type RegisterDefault struct {
Payload *RegisterDefaultBody
// contains filtered or unexported fields
}
RegisterDefault handles this case with default header values.
An error response.
func NewRegisterDefault ¶
func NewRegisterDefault(code int) *RegisterDefault
NewRegisterDefault creates a RegisterDefault with default headers values
func (*RegisterDefault) Code ¶
func (o *RegisterDefault) Code() int
Code gets the status code for the register default response
func (*RegisterDefault) Error ¶
func (o *RegisterDefault) Error() string
func (*RegisterDefault) GetPayload ¶
func (o *RegisterDefault) GetPayload() *RegisterDefaultBody
type RegisterDefaultBody ¶
type RegisterDefaultBody struct {
// code
Code int32 `json:"code,omitempty"`
// error
Error string `json:"error,omitempty"`
// message
Message string `json:"message,omitempty"`
}
RegisterDefaultBody ErrorResponse is a message returned on HTTP error. swagger:model RegisterDefaultBody
func (*RegisterDefaultBody) MarshalBinary ¶
func (o *RegisterDefaultBody) MarshalBinary() ([]byte, error)
MarshalBinary interface implementation
func (*RegisterDefaultBody) UnmarshalBinary ¶
func (o *RegisterDefaultBody) UnmarshalBinary(b []byte) error
UnmarshalBinary interface implementation
type RegisterOK ¶
type RegisterOK struct {
Payload *RegisterOKBody
}
RegisterOK handles this case with default header values.
A successful response.
func NewRegisterOK ¶
func NewRegisterOK() *RegisterOK
NewRegisterOK creates a RegisterOK with default headers values
func (*RegisterOK) Error ¶
func (o *RegisterOK) Error() string
func (*RegisterOK) GetPayload ¶
func (o *RegisterOK) GetPayload() *RegisterOKBody
type RegisterOKBody ¶
type RegisterOKBody struct {
// container node
ContainerNode *RegisterOKBodyContainerNode `json:"container_node,omitempty"`
// generic node
GenericNode *RegisterOKBodyGenericNode `json:"generic_node,omitempty"`
// pmm agent
PMMAgent *RegisterOKBodyPMMAgent `json:"pmm_agent,omitempty"`
}
RegisterOKBody register OK body swagger:model RegisterOKBody
func (*RegisterOKBody) MarshalBinary ¶
func (o *RegisterOKBody) MarshalBinary() ([]byte, error)
MarshalBinary interface implementation
func (*RegisterOKBody) UnmarshalBinary ¶
func (o *RegisterOKBody) UnmarshalBinary(b []byte) error
UnmarshalBinary interface implementation
type RegisterOKBodyContainerNode ¶
type RegisterOKBodyContainerNode struct {
// Address FIXME https://jira.percona.com/browse/PMM-3786
Address string `json:"address,omitempty"`
// Node availability zone. Auto-detected and auto-updated.
Az string `json:"az,omitempty"`
// Container identifier. If specified, must be a unique Docker container identifier.
// Auto-detected and auto-updated.
ContainerID string `json:"container_id,omitempty"`
// Container name. Auto-detected and auto-updated.
ContainerName string `json:"container_name,omitempty"`
// Custom user-assigned labels.
CustomLabels map[string]string `json:"custom_labels,omitempty"`
// Linux machine-id of the Generic Node where this Container Node runs. Auto-detected and auto-updated.
// If defined, Generic Node with that machine_id must exist.
MachineID string `json:"machine_id,omitempty"`
// Unique randomly generated instance identifier. Can't be changed.
NodeID string `json:"node_id,omitempty"`
// Node model. Auto-detected and auto-updated.
NodeModel string `json:"node_model,omitempty"`
// Unique across all Nodes user-defined name. Can't be changed.
NodeName string `json:"node_name,omitempty"`
// Node region. Auto-detected and auto-updated.
Region string `json:"region,omitempty"`
}
RegisterOKBodyContainerNode ContainerNode represents a Docker container. swagger:model RegisterOKBodyContainerNode
func (*RegisterOKBodyContainerNode) MarshalBinary ¶
func (o *RegisterOKBodyContainerNode) MarshalBinary() ([]byte, error)
MarshalBinary interface implementation
func (*RegisterOKBodyContainerNode) UnmarshalBinary ¶
func (o *RegisterOKBodyContainerNode) UnmarshalBinary(b []byte) error
UnmarshalBinary interface implementation
type RegisterOKBodyGenericNode ¶
type RegisterOKBodyGenericNode struct {
// Address FIXME https://jira.percona.com/browse/PMM-3786
Address string `json:"address,omitempty"`
// Node availability zone. Auto-detected and auto-updated.
Az string `json:"az,omitempty"`
// Custom user-assigned labels. Can be changed.
CustomLabels map[string]string `json:"custom_labels,omitempty"`
// Linux distribution name and version. Auto-detected and auto-updated.
Distro string `json:"distro,omitempty"`
// Linux machine-id. Auto-detected and auto-updated.
// Must be unique across all Generic Nodes if specified.
MachineID string `json:"machine_id,omitempty"`
// Unique randomly generated instance identifier. Can't be changed.
NodeID string `json:"node_id,omitempty"`
// Node model. Auto-detected and auto-updated.
NodeModel string `json:"node_model,omitempty"`
// Unique across all Nodes user-defined name. Can't be changed.
NodeName string `json:"node_name,omitempty"`
// Node region. Auto-detected and auto-updated.
Region string `json:"region,omitempty"`
}
RegisterOKBodyGenericNode GenericNode represents a bare metal server or virtual machine. swagger:model RegisterOKBodyGenericNode
func (*RegisterOKBodyGenericNode) MarshalBinary ¶
func (o *RegisterOKBodyGenericNode) MarshalBinary() ([]byte, error)
MarshalBinary interface implementation
func (*RegisterOKBodyGenericNode) UnmarshalBinary ¶
func (o *RegisterOKBodyGenericNode) UnmarshalBinary(b []byte) error
UnmarshalBinary interface implementation
type RegisterOKBodyPMMAgent ¶
type RegisterOKBodyPMMAgent struct {
// Unique randomly generated instance identifier.
AgentID string `json:"agent_id,omitempty"`
// True if Agent is running and connected to pmm-managed.
Connected bool `json:"connected,omitempty"`
// Custom user-assigned labels.
CustomLabels map[string]string `json:"custom_labels,omitempty"`
// Node identifier where this instance runs.
RunsOnNodeID string `json:"runs_on_node_id,omitempty"`
}
RegisterOKBodyPMMAgent PMMAgent runs on Generic on Container Node. swagger:model RegisterOKBodyPMMAgent
func (*RegisterOKBodyPMMAgent) MarshalBinary ¶
func (o *RegisterOKBodyPMMAgent) MarshalBinary() ([]byte, error)
MarshalBinary interface implementation
func (*RegisterOKBodyPMMAgent) UnmarshalBinary ¶
func (o *RegisterOKBodyPMMAgent) UnmarshalBinary(b []byte) error
UnmarshalBinary interface implementation
type RegisterParams ¶
type RegisterParams struct {
/*Body*/
Body RegisterBody
Context context.Context
HTTPClient *http.Client
// contains filtered or unexported fields
}
RegisterParams contains all the parameters to send to the API endpoint for the register operation typically these are written to a http.Request
func NewRegisterParams ¶
func NewRegisterParams() *RegisterParams
NewRegisterParams creates a new RegisterParams object with the default values initialized.
func NewRegisterParamsWithContext ¶
func NewRegisterParamsWithContext(ctx context.Context) *RegisterParams
NewRegisterParamsWithContext creates a new RegisterParams object with the default values initialized, and the ability to set a context for a request
func NewRegisterParamsWithHTTPClient ¶
func NewRegisterParamsWithHTTPClient(client *http.Client) *RegisterParams
NewRegisterParamsWithHTTPClient creates a new RegisterParams object with the default values initialized, and the ability to set a custom HTTPClient for a request
func NewRegisterParamsWithTimeout ¶
func NewRegisterParamsWithTimeout(timeout time.Duration) *RegisterParams
NewRegisterParamsWithTimeout creates a new RegisterParams object with the default values initialized, and the ability to set a timeout on a request
func (*RegisterParams) SetBody ¶
func (o *RegisterParams) SetBody(body RegisterBody)
SetBody adds the body to the register params
func (*RegisterParams) SetContext ¶
func (o *RegisterParams) SetContext(ctx context.Context)
SetContext adds the context to the register params
func (*RegisterParams) SetHTTPClient ¶
func (o *RegisterParams) SetHTTPClient(client *http.Client)
SetHTTPClient adds the HTTPClient to the register params
func (*RegisterParams) SetTimeout ¶
func (o *RegisterParams) SetTimeout(timeout time.Duration)
SetTimeout adds the timeout to the register params
func (*RegisterParams) WithBody ¶
func (o *RegisterParams) WithBody(body RegisterBody) *RegisterParams
WithBody adds the body to the register params
func (*RegisterParams) WithContext ¶
func (o *RegisterParams) WithContext(ctx context.Context) *RegisterParams
WithContext adds the context to the register params
func (*RegisterParams) WithHTTPClient ¶
func (o *RegisterParams) WithHTTPClient(client *http.Client) *RegisterParams
WithHTTPClient adds the HTTPClient to the register params
func (*RegisterParams) WithTimeout ¶
func (o *RegisterParams) WithTimeout(timeout time.Duration) *RegisterParams
WithTimeout adds the timeout to the register params
func (*RegisterParams) WriteToRequest ¶
func (o *RegisterParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
WriteToRequest writes these params to a swagger request
type RegisterReader ¶
type RegisterReader struct {
// contains filtered or unexported fields
}
RegisterReader is a Reader for the Register structure.
func (*RegisterReader) ReadResponse ¶
func (o *RegisterReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)
ReadResponse reads a server response into the received o.