Documentation ¶
Index ¶
- func APIErrorDiagnostics(err error) diag.Diagnostics
- func APIErrorIsNotFound(err error) bool
- func ConfigureClient(providerData any) (*hcloud.Client, diag.Diagnostics)
- func ErrorToDiag(err error) diag.Diagnostics
- func NotFoundDiagnostic(resourceName string, key string, value any) diag.Diagnostic
- func TerraformLabelsToHCloud(ctx context.Context, inputLabels types.Map, outputLabels *map[string]string) diag.Diagnostics
- func WaitForAction(ctx context.Context, c hcloud.ActionWaiter, action *hcloud.Action) error
- func WaitForActions(ctx context.Context, c hcloud.ActionWaiter, actions []*hcloud.Action) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func APIErrorDiagnostics ¶
func APIErrorDiagnostics(err error) diag.Diagnostics
APIErrorDiagnostics creates diagnostics from the errors that occurred during an API requests.
func APIErrorIsNotFound ¶
APIErrorIsNotFound check whether the error is an API request Not Found error.
func ConfigureClient ¶
func ConfigureClient(providerData any) (*hcloud.Client, diag.Diagnostics)
func ErrorToDiag ¶
func ErrorToDiag(err error) diag.Diagnostics
ErrorToDiag creates a terraform diag When some hcloud errors are passed it enriches the default Error() function from them with a few more details to make them more understandable for users
func NotFoundDiagnostic ¶ added in v1.48.0
func NotFoundDiagnostic(resourceName string, key string, value any) diag.Diagnostic
func TerraformLabelsToHCloud ¶
func WaitForAction ¶
WaitForAction uses hcloud.ActionWaiter.WaitFor to wait for the completion of an action.
func WaitForActions ¶
WaitForActions uses hcloud.ActionWaiter.WaitFor to wait for the completion of all actions.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.