redis

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Nov 9, 2026 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConfigKeys added in v1.0.0

func ConfigKeys() []string

ConfigKeys lists every mock-config key the plugin accepts (aliases included).

func DefaultPorts added in v1.0.0

func DefaultPorts() map[string]string

DefaultPorts returns the host port used for each port key when the config does not set it.

Types

type RedisConfig

type RedisConfig struct {
	Image         string `json:"image"`
	Port          string `json:"port"`
	Password      string `json:"password"`
	ContainerName string `json:"container-name"`
}

RedisConfig holds Redis-specific configuration

type RedisPlugin

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

RedisPlugin implements the ServicePlugin interface for Redis

func NewRedisPlugin

func NewRedisPlugin(dockerClient *docker.Client, logger *zap.Logger) *RedisPlugin

NewRedisPlugin creates a new Redis service plugin

func (*RedisPlugin) GetConnectionInfo

func (p *RedisPlugin) GetConnectionInfo() (*plugin.ConnectionInfo, error)

GetConnectionInfo returns connection details

func (*RedisPlugin) GetLogs

func (p *RedisPlugin) GetLogs(ctx context.Context, opts *plugin.LogOptions) ([]string, error)

GetLogs retrieves service logs

func (*RedisPlugin) IsReady

func (p *RedisPlugin) IsReady(ctx context.Context) (bool, error)

IsReady checks if the Redis service is ready to accept connections

func (*RedisPlugin) Launch

func (p *RedisPlugin) Launch(ctx context.Context, config map[string]interface{}) error

Launch starts the Redis service with given configuration

func (*RedisPlugin) Name

func (p *RedisPlugin) Name() string

Name returns the service identifier

func (*RedisPlugin) Stop

func (p *RedisPlugin) Stop(ctx context.Context) error

Stop terminates the Redis service

Jump to

Keyboard shortcuts

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