Documentation ¶
Index ¶
- Variables
- func GenerateCreateInput(cr *v1alpha1.NetworkLoadBalancer, listenerLanID, targetLanID int32, ...) sdkgo.NetworkLoadBalancer
- func GenerateUpdateInput(cr *v1alpha1.NetworkLoadBalancer, listenerLanID, targetLanID int32, ...) sdkgo.NetworkLoadBalancerProperties
- func IsUpToDate(cr *v1alpha1.NetworkLoadBalancer, observed sdkgo.NetworkLoadBalancer, ...) bool
- func LateInitializer(in *v1alpha1.NetworkLoadBalancerParameters, nlb sdkgo.NetworkLoadBalancer) bool
- func SetStatus(in *v1alpha1.NetworkLoadBalancerObservation, nlb sdkgo.NetworkLoadBalancer)
- type APIClient
- func (cp *APIClient) CheckDuplicateNetworkLoadBalancer(ctx context.Context, datacenterID, nlbName string) (string, error)
- func (cp *APIClient) CreateNetworkLoadBalancer(ctx context.Context, datacenterID string, nlb sdkgo.NetworkLoadBalancer) (sdkgo.NetworkLoadBalancer, error)
- func (cp *APIClient) DeleteNetworkLoadBalancer(ctx context.Context, datacenterID, nlbID string) error
- func (cp *APIClient) GetNetworkLoadBalancerByID(ctx context.Context, datacenterID, nlbID string) (sdkgo.NetworkLoadBalancer, error)
- func (cp *APIClient) UpdateNetworkLoadBalancer(ctx context.Context, datacenterID, nlbID string, ...) (sdkgo.NetworkLoadBalancer, error)
- type Client
Constants ¶
This section is empty.
Variables ¶
var ErrNotFound = errors.New("network load balancer not found")
ErrNotFound no load balancer has been found
Functions ¶
func GenerateCreateInput ¶
func GenerateCreateInput(cr *v1alpha1.NetworkLoadBalancer, listenerLanID, targetLanID int32, publicIPs []string) sdkgo.NetworkLoadBalancer
GenerateCreateInput returns sdkgo.NetworkLoadBalancer for Create requests based on CR spec
func GenerateUpdateInput ¶
func GenerateUpdateInput(cr *v1alpha1.NetworkLoadBalancer, listenerLanID, targetLanID int32, publicIPs []string) sdkgo.NetworkLoadBalancerProperties
GenerateUpdateInput returns sdkgo.NetworkLoadBalancerProperties for Update requests based on CR spec
func IsUpToDate ¶
func IsUpToDate(cr *v1alpha1.NetworkLoadBalancer, observed sdkgo.NetworkLoadBalancer, listenerLan, targetLan int32, ips []string) bool
IsUpToDate returns true if the NetworkLoadBalancer is up-to-date or false otherwise
func LateInitializer ¶
func LateInitializer(in *v1alpha1.NetworkLoadBalancerParameters, nlb sdkgo.NetworkLoadBalancer) bool
LateInitializer fills the empty fields in *v1alpha1.NetworkLoadBalancerParameters with values that might have been provided by the API in sdkgo.NetworkLoadBalancer
func SetStatus ¶
func SetStatus(in *v1alpha1.NetworkLoadBalancerObservation, nlb sdkgo.NetworkLoadBalancer)
SetStatus sets fields of the NetworkLoadBalancerObservation based on sdkgo.NetworkLoadBalancer
Types ¶
type APIClient ¶
type APIClient struct {
*clients.IonosServices
}
APIClient is a wrapper around IONOS Service
func (*APIClient) CheckDuplicateNetworkLoadBalancer ¶
func (cp *APIClient) CheckDuplicateNetworkLoadBalancer(ctx context.Context, datacenterID, nlbName string) (string, error)
CheckDuplicateNetworkLoadBalancer returns the ID of the duplicate Network Load Balancer if any, or an error if multiple Network Load Balancers with the same name are found
func (*APIClient) CreateNetworkLoadBalancer ¶
func (cp *APIClient) CreateNetworkLoadBalancer(ctx context.Context, datacenterID string, nlb sdkgo.NetworkLoadBalancer) (sdkgo.NetworkLoadBalancer, error)
CreateNetworkLoadBalancer based on Datacenter ID and NetworkLoadBalancer
func (*APIClient) DeleteNetworkLoadBalancer ¶
func (cp *APIClient) DeleteNetworkLoadBalancer(ctx context.Context, datacenterID, nlbID string) error
DeleteNetworkLoadBalancer based on Datacenter ID and NetworkLoadBalancer ID
func (*APIClient) GetNetworkLoadBalancerByID ¶
func (cp *APIClient) GetNetworkLoadBalancerByID(ctx context.Context, datacenterID, nlbID string) (sdkgo.NetworkLoadBalancer, error)
GetNetworkLoadBalancerByID based on Datacenter ID and NetworkLoadBalancer ID
func (*APIClient) UpdateNetworkLoadBalancer ¶
func (cp *APIClient) UpdateNetworkLoadBalancer(ctx context.Context, datacenterID, nlbID string, nlbProperties sdkgo.NetworkLoadBalancerProperties) (sdkgo.NetworkLoadBalancer, error)
UpdateNetworkLoadBalancer based on Datacenter ID, NetworkLoadBalancer ID and NetworkLoadBalancerProperties
type Client ¶
type Client interface { CheckDuplicateNetworkLoadBalancer(ctx context.Context, datacenterID, nlbName string) (string, error) GetNetworkLoadBalancerByID(ctx context.Context, datacenterID, NetworkLoadBalancerID string) (sdkgo.NetworkLoadBalancer, error) CreateNetworkLoadBalancer(ctx context.Context, datacenterID string, nlb sdkgo.NetworkLoadBalancer) (sdkgo.NetworkLoadBalancer, error) UpdateNetworkLoadBalancer(ctx context.Context, datacenterID, nlbID string, nlbProperties sdkgo.NetworkLoadBalancerProperties) (sdkgo.NetworkLoadBalancer, error) DeleteNetworkLoadBalancer(ctx context.Context, datacenterID, nlbID string) error }
Client is a wrapper around IONOS Service Network Load Balancer methods