workspaces

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Jul 8, 2022 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DeleteWorkspaceRequest

type DeleteWorkspaceRequest struct {
	Name string `json:"name"`
}

DeleteWorkspaceRequest the data transfer object to delete a workspace with the provided DNS name

func NewDeleteWorkspaceRequest

func NewDeleteWorkspaceRequest(reader io.Reader) (*DeleteWorkspaceRequest, error)

NewCustomerMigrationRequestFromReader decodes the request and returns after validation and setting the defaults.

func (*DeleteWorkspaceRequest) Validate

func (r *DeleteWorkspaceRequest) Validate() error

Validate validates the values of a delete workspace request

type ProvisionerRequester

type ProvisionerRequester interface {
	GetInstallationByDNS(DNS string, request *cmodel.GetInstallationRequest) (*cmodel.InstallationDTO, error)
	DeleteInstallation(id string) error
}

ProvisionerRequester the interface which describes Provisioner API client

type Service

type Service struct {
	// contains filtered or unexported fields
}

func NewService

func NewService(provisionerClient ProvisionerRequester, workspaceClient *WorkspaceClient, logger log.FieldLogger) *Service

NewService creates a service to make provisioner requests

func (*Service) DeleteWorkspace

func (s *Service) DeleteWorkspace(dnsName string) error

DeleteWorkspace deletes a workspace with the DNS name provided

type WorkspaceClient

type WorkspaceClient struct {
	URL string
	// contains filtered or unexported fields
}

func NewHTTPClient

func NewHTTPClient(URL string, client *http.Client) *WorkspaceClient

NewHTTPClient creates a workspace HTTP client for managing workspace

func (*WorkspaceClient) DeleteWorkspace

func (c *WorkspaceClient) DeleteWorkspace(installationID string) error

DeleteWorkspace makes an http request to delete a workspace

Jump to

Keyboard shortcuts

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