broker_base

package
v4.0.0+incompatible Latest Latest
Warning

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

Go to latest
Published: Oct 1, 2018 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BrokerBase

type BrokerBase struct {
	AccountManager models.ServiceAccountManager
	HttpConfig     *jwt.Config
	ProjectId      string
	Logger         lager.Logger
}

BrokerBase is the reference bind and unbind implementation for brokers that bind and unbind with only Service Accounts.

func (*BrokerBase) Bind

func (b *BrokerBase) Bind(instanceID, bindingID string, details brokerapi.BindDetails) (models.ServiceBindingCredentials, error)

Bind creates a service account with access to the provisioned resource with the given instance.

func (*BrokerBase) BuildInstanceCredentials

func (b *BrokerBase) BuildInstanceCredentials(bindDetails models.ServiceBindingCredentials, instanceDetails models.ServiceInstanceDetails) (map[string]string, error)

BuildInstanceCredentials combines the bind credentials with the connection information in the instance details to get a full set of connection details.

func (*BrokerBase) DeprovisionsAsync

func (b *BrokerBase) DeprovisionsAsync() bool

DeprovisionsAsync indicates if deprovisioning must be done asynchronously.

func (*BrokerBase) LastOperationWasDelete

func (b *BrokerBase) LastOperationWasDelete(instanceId string) (bool, error)

LastOperationWasDelete is used during polling of async operations to determine if the workflow is a provision or deprovision flow based off the type of the most recent operation.

func (*BrokerBase) PollInstance

func (b *BrokerBase) PollInstance(instanceID string) (bool, error)

PollInstance does nothing but return an error because Base services are provisioned synchronously so this method should not be called.

func (*BrokerBase) ProvisionsAsync

func (b *BrokerBase) ProvisionsAsync() bool

ProvisionsAsync indicates if provisioning must be done asynchronously.

func (*BrokerBase) Unbind

Unbind deletes the created service account from the GCP Project.

Jump to

Keyboard shortcuts

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