Documentation
¶
Index ¶
- Constants
- func Bind(useSSL bool, skipCertValidation bool, host string, port int, username string, ...) (string, map[string]interface{}, error)
- func Deprovision(useSSL bool, skipCertValidation bool, host string, port int, username string, ...) error
- func Poll(useSSL bool, skipCertValidation bool, host string, port int, username string, ...) (string, error)
- func Provision(useSSL bool, skipCertValidation bool, host string, port int, username string, ...) (string, error)
- func Unbind(useSSL bool, skipCertValidation bool, host string, port int, username string, ...) error
- func Update(useSSL bool, skipCertValidation bool, host string, port int, username string, ...) error
- type BindingRequest
- type BindingResponse
- type Catalog
- type Plan
- type ProvisioningRequest
- type Service
- type ServiceMetadata
- type ServicePlanMetadata
- type UpdatingPreviousValues
- type UpdatingRequest
Constants ¶
const ( // OperationProvisioning represents the "provisioning" operation OperationProvisioning = "provisioning" // OperationUpdating represents the "updating" operation OperationUpdating = "updating" // OperationDeprovisioning represents the "deprovisioning" operation OperationDeprovisioning = "deprovisioning" // OperationStateInProgress represents the state of an operation that is still // pending completion OperationStateInProgress = "in progress" // OperationStateSucceeded represents the state of an operation that has // completed successfully OperationStateSucceeded = "succeeded" // OperationStateFailed represents the state of an operation that has // failed OperationStateFailed = "failed" // OperationStateGone is a pseudo oepration state represting the "state" // of an operation against an entity that no longer exists OperationStateGone = "gone" )
Variables ¶
This section is empty.
Functions ¶
func Bind ¶
func Bind( useSSL bool, skipCertValidation bool, host string, port int, username string, password string, instanceID string, params map[string]interface{}, ) (string, map[string]interface{}, error)
Bind carries out binding to an existing service
func Deprovision ¶
func Deprovision( useSSL bool, skipCertValidation bool, host string, port int, username string, password string, instanceID string, ) error
Deprovision initiates deprovisioning of a service instance
func Poll ¶
func Poll( useSSL bool, skipCertValidation bool, host string, port int, username string, password string, instanceID string, operation string, ) (string, error)
Poll polls the status of an instance
func Provision ¶
func Provision( useSSL bool, skipCertValidation bool, host string, port int, username string, password string, serviceID string, planID string, params map[string]interface{}, ) (string, error)
Provision initiates provisioning of a new service instance
Types ¶
type BindingRequest ¶
type BindingRequest struct {
ServiceID string `json:"service_id"`
PlanID string `json:"plan_id"`
Parameters map[string]interface{} `json:"parameters"`
}
BindingRequest represents a request to bind to a service
type BindingResponse ¶
type BindingResponse struct {
Credentials map[string]interface{} `json:"credentials"`
}
BindingResponse represents the response to a binding request
type Catalog ¶
type Catalog struct {
Services []Service `json:"services"`
}
Catalog represents the full set of service/plan offerings provided by a broker
type Plan ¶
type Plan struct {
ID string `json:"id"`
Name string `json:"name"`
Description string `json:"description"`
Free bool `json:"free"`
Metadata *ServicePlanMetadata `json:"metadata,omitempty"`
}
Plan represents a concrete variation of a Service; typically these are different SKUs for the same KIND of service
type ProvisioningRequest ¶
type ProvisioningRequest struct {
ServiceID string `json:"service_id"`
PlanID string `json:"plan_id"`
Parameters map[string]interface{} `json:"parameters"`
}
ProvisioningRequest represents a request to provision a service instance
type Service ¶
type Service struct {
Name string `json:"name"`
ID string `json:"id"`
Description string `json:"description"`
Metadata *ServiceMetadata `json:"metadata,omitempty"`
Plans []Plan `json:"plans"`
Tags []string `json:"tags"`
Bindable bool `json:"bindable"`
PlanUpdatable bool `json:"plan_updateable"` // Misspelling is
}
Service represents a KIND of service
type ServiceMetadata ¶
type ServiceMetadata struct {
DisplayName string `json:"displayName,omitempty"`
ImageURL string `json:"imageUrl,omitempty"`
LongDescription string `json:"longDescription,omitempty"`
ProviderDisplayName string `json:"providerDisplayName,omitempty"`
DocumentationURL string `json:"documentationUrl,omitempty"`
SupportURL string `json:"supportUrl,omitempty"`
}
ServiceMetadata represents optional, extended metadata for a service
type ServicePlanMetadata ¶
type ServicePlanMetadata struct {
DisplayName string `json:"displayName,omitempty"`
Bullets []string `json:"bullets,omitempty"`
}
ServicePlanMetadata represents optional, extended metadata for a plan
type UpdatingPreviousValues ¶
type UpdatingPreviousValues struct {
PlanID string `json:"plan_id"`
}
UpdatingPreviousValues represents the information about the service instance prior to the update
type UpdatingRequest ¶
type UpdatingRequest struct {
ServiceID string `json:"service_id"`
PlanID string `json:"plan_id"`
Parameters map[string]interface{} `json:"parameters"`
PreviousValues UpdatingPreviousValues `json:"previous_values"`
}
UpdatingRequest represents a request to update a service