Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func List ¶
func List(client *gophercloud.ServiceClient, lbID uint64, opts ListOptsBuilder) pagination.Pager
Types ¶
type CreateOpts ¶
type CreateOpts struct { // The address of the node Address string `json:"address"` // The port for the node Port int32 `json:"port"` // Indicates if the node is ENABLED, DISABLED, or DRAINING Condition string `json:"condition"` // Indicates the weight for the node Weight uint `json:"weight,omitempty"` // Node type Type string `json:"type,omitempty"` }
CreateOpts contain the values necessary to create a node
type CreateResult ¶
type CreateResult struct {
gophercloud.Result
}
CreateResult is the result of a Create operation
func Create ¶
func Create(client *gophercloud.ServiceClient, lbID uint64, opts []CreateOpts) (r CreateResult)
Create creates a requested node
func (CreateResult) Extract ¶
func (r CreateResult) Extract() (*Node, error)
Extract interprets a CreateResult as a Node.
type DeleteResult ¶
type DeleteResult struct {
gophercloud.ErrResult
}
method to determine if the call succeeded or failed.
func Delete ¶
func Delete(client *gophercloud.ServiceClient, lbID uint64, id uint64) (r DeleteResult)
Delete deletes the specified node ID.
type GetResult ¶
type GetResult struct {
gophercloud.Result
}
GetResult is the response from a Get operation. Call its Extract method to interpret it as a Node.
func Get ¶
func Get(client *gophercloud.ServiceClient, lbID uint64, id uint64) (r GetResult)
Get returns data about a specific node by its ID.
type ListOpts ¶
type ListOpts struct { // Status of the LoadBalancer Status string `q:"status"` // Address of a node attached to the LoadBalancer Node string `q:"nodeaddress"` // Name of the LoadBalancer Name string `q:"name"` }
ListOpts contain options filtering LoadBalancers returned from a call to List.
func (ListOpts) ToLoadBalancerListQuery ¶
ToLoadBalancerListQuery formats a ListOpts into a query string.
type ListOptsBuilder ¶
ListOptsBuilder allows extensions to add additional parameters to the List request.
type Node ¶
type Node struct { // ID is the unique ID of a node ID uint64 `json:"id"` // The address of the node Address string `json:"address"` // The port for the node Port int32 `json:"port"` // Indicates if the node is ENABLED, DISABLED or DRAINING Condition string `json:"condition"` // The status of the node Status string `json:"status"` // Indicates the weight for the node Weight uint `json:"weight"` // Node typeof virtualIps for a load balancer Type string `json:"type"` }
Node represents a node behind a load balancer returned by the Cloud Load Balancer API.
func ExtractNodes ¶
func ExtractNodes(r pagination.Page) ([]Node, error)
ExtractNodes converts a page of List results into a slice of usable Node structs.
type NodePage ¶
type NodePage struct {
pagination.LinkedPageBase
}
NodePage contains a single page of all Nodes return from a List operation. Use ExtractNodes to convert it into a slice of usable structs.
func (NodePage) NextPageURL ¶
NextPageURL uses the response's embedded link reference to navigate to the next page of results.