dataplaneconfig

package
v2.2.0 Latest Latest
Warning

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

Go to latest
Published: Jul 23, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DataplaneConfig

type DataplaneConfig struct {
	ProjectID    string    `json:"project_id"`
	Enabled      bool      `json:"enabled"`
	TargetBucket string    `json:"target_bucket,omitempty"`
	UpdatedAt    time.Time `json:"updated_at"`
	UpdatedBy    string    `json:"updated_by"`
}

DataplaneConfig holds the per-project dataplane routing configuration returned by the Hermes API.

type DeleteResult

type DeleteResult struct {
	gophercloud.ErrResult
}

DeleteResult represents the result of a Delete operation.

func Delete

func Delete(ctx context.Context, c *gophercloud.ServiceClient, projectID string) (r DeleteResult)

Delete removes the dataplane configuration for the given project. Deleting a non-existent config is a no-op (returns 204).

type GetResult

type GetResult struct {
	gophercloud.Result
}

GetResult represents the result of a Get operation.

func Get

func Get(ctx context.Context, c *gophercloud.ServiceClient, projectID string) (r GetResult)

Get retrieves the dataplane configuration for the given project. Returns the default (disabled) config when none has been set.

func (GetResult) Extract

func (r GetResult) Extract() (*DataplaneConfig, error)

Extract interprets a GetResult as a DataplaneConfig.

func (GetResult) ExtractInto

func (r GetResult) ExtractInto(v any) error

ExtractInto is used by Extract.

type PutOpts

type PutOpts struct {
	Enabled      bool   `json:"enabled"`
	TargetBucket string `json:"target_bucket,omitempty"`
}

PutOpts specifies the fields for a Put request.

type PutResult

type PutResult struct {
	gophercloud.Result
}

PutResult represents the result of a Put operation.

func Put

func Put(ctx context.Context, c *gophercloud.ServiceClient, projectID string, opts PutOpts) (r PutResult)

Put creates or replaces the dataplane configuration for the given project.

func (PutResult) Extract

func (r PutResult) Extract() (*DataplaneConfig, error)

Extract interprets a PutResult as a DataplaneConfig.

func (PutResult) ExtractInto

func (r PutResult) ExtractInto(v any) error

ExtractInto is used by Extract.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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