Documentation
      ¶
    
    
  
    
  
    Index ¶
- Constants
 - type API
 - func (a *API) CreateActiveActiveEndpoint(ctx context.Context, subscription int, regionId int, pscServiceId int, ...) (int, error)
 - func (a *API) CreateActiveActiveService(ctx context.Context, subscription int, regionId int) (int, error)
 - func (a *API) CreateEndpoint(ctx context.Context, subscription int, pscServiceId int, ...) (int, error)
 - func (a *API) CreateService(ctx context.Context, subscription int) (int, error)
 - func (a *API) DeleteActiveActiveEndpoint(ctx context.Context, subscription int, regionId int, pscServiceId int, ...) error
 - func (a *API) DeleteActiveActiveService(ctx context.Context, subscription int, regionId int) error
 - func (a *API) DeleteEndpoint(ctx context.Context, subscription int, pscServiceId int, endpointId int) error
 - func (a *API) DeleteService(ctx context.Context, subscription int) error
 - func (a *API) GetActiveActiveEndpointCreationScripts(ctx context.Context, subscription int, regionId int, pscServiceId int, ...) (*CreationScript, error)
 - func (a *API) GetActiveActiveEndpointDeletionScripts(ctx context.Context, subscription int, regionId int, pscServiceId int, ...) (*DeletionScript, error)
 - func (a *API) GetActiveActiveEndpoints(ctx context.Context, subscription int, regionId int, pscServiceId int) (*PrivateServiceConnectEndpoints, error)
 - func (a *API) GetActiveActiveService(ctx context.Context, subscription int, regionId int) (*PrivateServiceConnectService, error)
 - func (a *API) GetEndpointCreationScripts(ctx context.Context, subscription int, pscServiceId int, endpointId int, ...) (*CreationScript, error)
 - func (a *API) GetEndpointDeletionScripts(ctx context.Context, subscription int, pscServiceId int, endpointId int) (*DeletionScript, error)
 - func (a *API) GetEndpoints(ctx context.Context, subscription int, pscServiceId int) (*PrivateServiceConnectEndpoints, error)
 - func (a *API) GetService(ctx context.Context, subscription int) (*PrivateServiceConnectService, error)
 - func (a *API) UpdateActiveActiveEndpoint(ctx context.Context, subscription int, regionId int, pscServiceId int, ...) error
 - func (a *API) UpdateEndpoint(ctx context.Context, subscription int, pscServiceId int, endpointId int, ...) error
 
- type CreatePrivateServiceConnectEndpoint
 - type CreationScript
 - type DeletionScript
 - type GCPCreationScript
 - type GCPDeletionScript
 - type HttpClient
 - type Log
 - type NotFound
 - type NotFoundActiveActive
 - type PrivateServiceConnectEndpoint
 - type PrivateServiceConnectEndpoints
 - type PrivateServiceConnectService
 - type TaskWaiter
 - type TerraformGCP
 - type TerraformGCPServiceAttachment
 - type UpdatePrivateServiceConnectEndpoint
 
Constants ¶
      View Source
      
  
const ( // ServiceStatusCreateQueued when PSC service creation is queued ServiceStatusCreateQueued = "create-queued" // ServiceStatusDeleteQueued when PSC service deletion is queued ServiceStatusDeleteQueued = "delete-queued" // ServiceStatusInitialized when PSC service provisioning started ServiceStatusInitialized = "initialized" // ServiceStatusCreatePending when PSC service provisioning completed but databases are pending update ServiceStatusCreatePending = "create-pending" // ServiceStatusActive when PSC service is ready ServiceStatusActive = "active" // ServiceStatusDeletePending when infrastructure deletion is completed but databases are pending update ServiceStatusDeletePending = "delete-pending" // ServiceStatusDeleted when PSC service is deleted ServiceStatusDeleted = "deleted" // ServiceStatusProvisionFailed when PSC service has failed while creation/deletion ServiceStatusProvisionFailed = "provision-failed" // ServiceStatusFailed when PSC service failed after it's been reported as active ServiceStatusFailed = "failed" // EndpointStatusInitialized the endpoint was created in the SM but the creation script wasn't yet run EndpointStatusInitialized = "initialized" // EndpointStatusProcessing Processing the status during deletion or creation of 40 endpoints in cloud provider EndpointStatusProcessing = "processing" // EndpointStatusPending the endpoint is waiting for the user to accept or reject it EndpointStatusPending = "pending" // EndpointStatusAcceptPending the user accepted. the endpoint is not yet fully accepted EndpointStatusAcceptPending = "accept-pending" // EndpointStatusActive the endpoint is ready for use EndpointStatusActive = "active" // EndpointStatusDeleted the endpoint was successfully deleted EndpointStatusDeleted = "deleted" // EndpointStatusRejected the endpoint was successfully rejected EndpointStatusRejected = "rejected" // EndpointStatusRejectPending the user rejected. the endpoint is not yet fully rejected EndpointStatusRejectPending = "reject-pending" // EndpointStatusFailed endpoint is in error status EndpointStatusFailed = "failed" // EndpointActionAccept accepts the endpoint EndpointActionAccept = "accept" // EndpointActionReject rejects the endpoint EndpointActionReject = "reject" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type API ¶
type API struct {
	// contains filtered or unexported fields
}
    func NewAPI ¶
func NewAPI(client HttpClient, taskWaiter TaskWaiter, logger Log) *API
func (*API) CreateActiveActiveEndpoint ¶
func (*API) CreateActiveActiveService ¶
func (*API) CreateEndpoint ¶
func (*API) CreateService ¶
func (*API) DeleteActiveActiveEndpoint ¶
func (*API) DeleteActiveActiveService ¶
func (*API) DeleteEndpoint ¶
func (*API) DeleteService ¶
func (*API) GetActiveActiveEndpointCreationScripts ¶
func (*API) GetActiveActiveEndpointDeletionScripts ¶
func (*API) GetActiveActiveEndpoints ¶
func (*API) GetActiveActiveService ¶
func (*API) GetEndpointCreationScripts ¶
func (*API) GetEndpointDeletionScripts ¶
func (*API) GetEndpoints ¶
func (*API) GetService ¶
func (*API) UpdateActiveActiveEndpoint ¶
func (*API) UpdateEndpoint ¶
type CreationScript ¶
type CreationScript struct {
	Script *GCPCreationScript `json:"script,omitempty"`
}
    type DeletionScript ¶
type DeletionScript struct {
	Script *GCPDeletionScript `json:"script,omitempty"`
}
    type GCPCreationScript ¶
type GCPCreationScript struct {
	Bash         *string       `json:"bash,omitempty"`
	Powershell   *string       `json:"powershell,omitempty"`
	TerraformGcp *TerraformGCP `json:"terraformGcp,omitempty"`
}
    type GCPDeletionScript ¶
type HttpClient ¶
type HttpClient interface {
	Get(ctx context.Context, name, path string, responseBody interface{}) error
	GetWithQuery(ctx context.Context, name, path string, query url.Values, responseBody interface{}) error
	Post(ctx context.Context, name, path string, requestBody interface{}, responseBody interface{}) error
	Put(ctx context.Context, name, path string, requestBody interface{}, responseBody interface{}) error
	Delete(ctx context.Context, name, path string, requestBody interface{}, responseBody interface{}) error
}
    type NotFoundActiveActive ¶
type NotFoundActiveActive struct {
	// contains filtered or unexported fields
}
    func (*NotFoundActiveActive) Error ¶
func (f *NotFoundActiveActive) Error() string
type PrivateServiceConnectEndpoint ¶
type PrivateServiceConnectEndpoint struct {
	ID                     *int    `json:"id,omitempty"`
	GCPProjectID           *string `json:"gcpProjectId,omitempty"`
	GCPVPCName             *string `json:"gcpVpcName,omitempty"`
	GCPVPCSubnetName       *string `json:"gcpVpcSubnetName,omitempty"`
	EndpointConnectionName *string `json:"endpointConnectionName,omitempty"`
	Status                 *string `json:"status,omitempty"`
}
    type PrivateServiceConnectEndpoints ¶
type PrivateServiceConnectEndpoints struct {
	PSCServiceID *int                             `json:"pscServiceId,omitempty"`
	Endpoints    []*PrivateServiceConnectEndpoint `json:"endpoints,omitempty"`
}
    type TaskWaiter ¶
type TerraformGCP ¶
type TerraformGCP struct {
	ServiceAttachments []TerraformGCPServiceAttachment `json:"serviceAttachments,omitempty"`
}
    type UpdatePrivateServiceConnectEndpoint ¶
type UpdatePrivateServiceConnectEndpoint struct {
	GCPProjectID           *string `json:"gcpProjectId,omitempty"`
	GCPVPCName             *string `json:"gcpVpcName,omitempty"`
	GCPVPCSubnetName       *string `json:"gcpVpcSubnetName,omitempty"`
	EndpointConnectionName *string `json:"endpointConnectionName,omitempty"`
	Action                 *string `json:"action,omitempty"`
}
     Click to show internal directories. 
   Click to hide internal directories.