Documentation
¶
Index ¶
- func GenerateAuthToken(seed string, instanceID string) string
- func GenerateReplicationGroupName(instanceID string) string
- type RedisProvider
- func (p *RedisProvider) DeleteCacheParameterGroup(ctx context.Context, instanceID string) error
- func (p *RedisProvider) Deprovision(ctx context.Context, instanceID string, params providers.DeprovisionParameters) error
- func (p *RedisProvider) FindSnapshots(ctx context.Context, instanceID string) ([]providers.SnapshotInfo, error)
- func (p *RedisProvider) GenerateCredentials(ctx context.Context, instanceID, bindingID string) (*providers.Credentials, error)
- func (p *RedisProvider) GetState(ctx context.Context, instanceID string) (providers.ServiceState, string, error)
- func (p *RedisProvider) Provision(ctx context.Context, instanceID string, params providers.ProvisionParameters) error
- func (p *RedisProvider) RevokeCredentials(ctx context.Context, instanceID, bindingID string) error
- func (p *RedisProvider) Update(ctx context.Context, instanceID string, params providers.UpdateParameters) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenerateAuthToken ¶
GenerateAuthToken generates a password based on the given seed and the service instance id
func GenerateReplicationGroupName ¶
GenerateReplicationGroupName generates a valid ElastiCache replication group name A valid name must contain between 1 and 20 alphanumeric characters or hyphens, should start with a letter, and cannot end with a hyphen or contain two consecutive hyphens.
Types ¶
type RedisProvider ¶
type RedisProvider struct {
// contains filtered or unexported fields
}
RedisProvider is the Redis broker provider
func NewProvider ¶
func NewProvider(elasticache providers.ElastiCache, awsAccountID, awsPartition, awsRegion string, logger lager.Logger, authTokenSeed string) *RedisProvider
NewProvider creates a new Redis provider
func (*RedisProvider) DeleteCacheParameterGroup ¶
func (p *RedisProvider) DeleteCacheParameterGroup(ctx context.Context, instanceID string) error
func (*RedisProvider) Deprovision ¶
func (p *RedisProvider) Deprovision(ctx context.Context, instanceID string, params providers.DeprovisionParameters) error
Deprovision deletes the replication group
func (*RedisProvider) FindSnapshots ¶
func (p *RedisProvider) FindSnapshots(ctx context.Context, instanceID string) ([]providers.SnapshotInfo, error)
FindSnapshots returns the list of snapshots found for a given instance ID
func (*RedisProvider) GenerateCredentials ¶
func (p *RedisProvider) GenerateCredentials(ctx context.Context, instanceID, bindingID string) (*providers.Credentials, error)
GenerateCredentials generates the client credentials for a Redis instance and an app
func (*RedisProvider) GetState ¶
func (p *RedisProvider) GetState(ctx context.Context, instanceID string) (providers.ServiceState, string, error)
GetState returns with the state of an existing cluster If the cluster doesn't exist we return with the providers.NonExisting state
func (*RedisProvider) Provision ¶
func (p *RedisProvider) Provision(ctx context.Context, instanceID string, params providers.ProvisionParameters) error
Provision creates a replication group and a cache parameter group
func (*RedisProvider) RevokeCredentials ¶
func (p *RedisProvider) RevokeCredentials(ctx context.Context, instanceID, bindingID string) error
RevokeCredentials revokes the credentials between an app and a Redis instance
The method does nothing because we can't revoke the credentials as there is one common password for a Redis service instance
func (*RedisProvider) Update ¶ added in v0.9.0
func (p *RedisProvider) Update(ctx context.Context, instanceID string, params providers.UpdateParameters) error