Documentation
¶
Index ¶
- Variables
- func ValidateInstanceProfileARN(instanceProfile string) error
- type Application
- type ApplicationVersion
- type ApplicationVersionParams
- type ConfigurationTemplate
- type ConfigurationTemplateParams
- type CreateEnvironmentParams
- type Environment
- type EventRecord
- type Handler
- func (h *Handler) ChaosOperations() []string
- func (h *Handler) ChaosRegions() []string
- func (h *Handler) ChaosServiceName() string
- func (h *Handler) ExtractOperation(c *echo.Context) string
- func (h *Handler) ExtractResource(c *echo.Context) string
- func (h *Handler) GetSupportedOperations() []string
- func (h *Handler) Handler() echo.HandlerFunc
- func (h *Handler) MatchPriority() int
- func (h *Handler) Name() string
- func (h *Handler) Reset()
- func (h *Handler) Restore(ctx context.Context, data []byte) error
- func (h *Handler) RouteMatcher() service.Matcher
- func (h *Handler) Snapshot(ctx context.Context) []byte
- type InMemoryBackend
- func (b *InMemoryBackend) AbortEnvironmentUpdate(_ context.Context, _ string) error
- func (b *InMemoryBackend) AddManagedActionHistory(ctx context.Context, envName, actionID, actionType, actionDesc, status string)
- func (b *InMemoryBackend) ApplyEnvironmentManagedAction(ctx context.Context, envName, actionID string) error
- func (b *InMemoryBackend) AssociateEnvironmentOperationsRole(ctx context.Context, envName, role string) error
- func (b *InMemoryBackend) CheckDNSAvailability(ctx context.Context, cnamePrefix string) (bool, string)
- func (b *InMemoryBackend) ComposeEnvironments(ctx context.Context, appName string) []*Environment
- func (b *InMemoryBackend) CreateApplication(ctx context.Context, name, description string, tags map[string]string) (*Application, error)
- func (b *InMemoryBackend) CreateApplicationVersion(ctx context.Context, appName, versionLabel, description string, ...) (*ApplicationVersion, error)
- func (b *InMemoryBackend) CreateApplicationVersionWithParams(ctx context.Context, appName, versionLabel string, ...) (*ApplicationVersion, error)
- func (b *InMemoryBackend) CreateConfigurationTemplate(ctx context.Context, appName, templateName, description, solutionStack string, ...) (*ConfigurationTemplate, error)
- func (b *InMemoryBackend) CreateConfigurationTemplateWithParams(ctx context.Context, appName, templateName, description, solutionStack string, ...) (*ConfigurationTemplate, error)
- func (b *InMemoryBackend) CreateEnvironment(ctx context.Context, appName, envName, solutionStack, description string, ...) (*Environment, error)
- func (b *InMemoryBackend) CreatePlatformVersion(ctx context.Context, platformName, platformVersion string, ...) (*PlatformVersion, error)
- func (b *InMemoryBackend) CreateStorageLocation(ctx context.Context) string
- func (b *InMemoryBackend) DeleteApplication(ctx context.Context, name string) error
- func (b *InMemoryBackend) DeleteApplicationVersion(ctx context.Context, appName, versionLabel string) error
- func (b *InMemoryBackend) DeleteConfigurationTemplate(ctx context.Context, appName, templateName string) error
- func (b *InMemoryBackend) DeleteEnvironmentConfiguration(_ context.Context, _, _ string) error
- func (b *InMemoryBackend) DeletePlatformVersion(ctx context.Context, platformARN string) (*PlatformVersion, error)
- func (b *InMemoryBackend) DescribeApplicationVersions(ctx context.Context, appName string, versionLabels []string) []*ApplicationVersion
- func (b *InMemoryBackend) DescribeApplications(ctx context.Context, names []string) []*Application
- func (b *InMemoryBackend) DescribeConfigurationTemplates(ctx context.Context, appName string) []*ConfigurationTemplate
- func (b *InMemoryBackend) DescribeEnvironmentHealth(ctx context.Context, envName string) (string, string, error)
- func (b *InMemoryBackend) DescribeEnvironmentManagedActionHistory(ctx context.Context, envName string) []*ManagedActionHistory
- func (b *InMemoryBackend) DescribeEnvironments(ctx context.Context, appName string, envNames []string, envIDs []string) []*Environment
- func (b *InMemoryBackend) DescribeEvents(ctx context.Context, appName, envName string) []*EventRecord
- func (b *InMemoryBackend) DescribePlatformVersion(ctx context.Context, platformARN string) (*PlatformVersion, error)
- func (b *InMemoryBackend) DisassociateEnvironmentOperationsRole(ctx context.Context, envName string) error
- func (b *InMemoryBackend) ListPlatformVersions(ctx context.Context) []*PlatformVersion
- func (b *InMemoryBackend) ListTagsForResource(ctx context.Context, resourceARN string) (map[string]string, error)
- func (b *InMemoryBackend) Region() string
- func (b *InMemoryBackend) Reset()
- func (b *InMemoryBackend) Restore(ctx context.Context, data []byte) error
- func (b *InMemoryBackend) Snapshot(ctx context.Context) []byte
- func (b *InMemoryBackend) SwapEnvironmentCNAMEs(ctx context.Context, sourceEnvName, destEnvName string) error
- func (b *InMemoryBackend) TerminateEnvironment(ctx context.Context, appName, envName string) (*Environment, error)
- func (b *InMemoryBackend) UpdateApplication(ctx context.Context, name, description string) (*Application, error)
- func (b *InMemoryBackend) UpdateApplicationResourceLifecycle(ctx context.Context, appName, serviceRole string) (*Application, error)
- func (b *InMemoryBackend) UpdateApplicationVersion(ctx context.Context, appName, versionLabel, description string) (*ApplicationVersion, error)
- func (b *InMemoryBackend) UpdateConfigurationTemplate(ctx context.Context, appName, templateName, description string) (*ConfigurationTemplate, error)
- func (b *InMemoryBackend) UpdateConfigurationTemplateWithParams(ctx context.Context, appName, templateName string, ...) (*ConfigurationTemplate, error)
- func (b *InMemoryBackend) UpdateEnvironment(ctx context.Context, appName, envName, description, solutionStack string) (*Environment, error)
- func (b *InMemoryBackend) UpdateEnvironmentWithParams(ctx context.Context, appName, envName string, params UpdateEnvironmentParams) (*Environment, error)
- func (b *InMemoryBackend) UpdateTagsForResource(ctx context.Context, resourceARN string, addTags, removeTags map[string]string) error
- type ManagedActionHistory
- type OptionSetting
- type PlatformVersion
- type Provider
- type SourceBuildInformation
- type UpdateConfigurationTemplateParams
- type UpdateEnvironmentParams
Constants ¶
This section is empty.
Variables ¶
var ( // ErrNotFound is returned when a requested resource does not exist. It is // used by name-based lookups (application/environment/version/template), // which AWS surfaces as the generic InvalidParameterValue sender error. ErrNotFound = awserr.New("ResourceNotFoundException", awserr.ErrNotFound) // ErrResourceNotFound is returned specifically when a ListTagsForResource // or UpdateTagsForResource ResourceArn does not match any known resource. // Unlike ErrNotFound, AWS documents this ARN-lookup case as a distinct // modeled exception (ResourceNotFoundException, HTTP 400) rather than // the generic InvalidParameterValue used by name-based CRUD ops -- see // handleOpError's mapping table. ErrResourceNotFound = awserr.New("ResourceNotFoundException", awserr.ErrNotFound) // ErrAlreadyExists is returned when a resource already exists. ErrAlreadyExists = awserr.New("ClientException", awserr.ErrAlreadyExists) // ErrUnknownAction is returned when an unknown action is requested. ErrUnknownAction = awserr.New("UnknownOperationException", awserr.ErrInvalidParameter) // ErrInvalidParameter is returned when a required parameter is missing or invalid. ErrInvalidParameter = awserr.New("InvalidParameterValue", awserr.ErrInvalidParameter) // ErrValidation is returned when request input fails validation. ErrValidation = awserr.New("ValidationException", awserr.ErrInvalidParameter) )
var ErrNilAppContext = errors.New("AppContext is required")
ErrNilAppContext is returned when Provider.Init is called with a nil AppContext.
Functions ¶
func ValidateInstanceProfileARN ¶
ValidateInstanceProfileARN validates that an instance profile ARN has the correct format (improvement #16).
Types ¶
type Application ¶
type Application struct {
Tags map[string]string `json:"tags,omitempty"`
ApplicationName string `json:"applicationName"`
ApplicationARN string `json:"applicationArn"`
Description string `json:"description,omitempty"`
DateCreated string `json:"dateCreated,omitempty"`
DateUpdated string `json:"dateUpdated,omitempty"`
ResourceLifecycleServiceRole string `json:"resourceLifecycleServiceRole,omitempty"`
// contains filtered or unexported fields
}
Application represents an Elastic Beanstalk application.
type ApplicationVersion ¶
type ApplicationVersion struct {
Tags map[string]string `json:"tags,omitempty"`
SourceBuildInformation *SourceBuildInformation `json:"sourceBuildInformation,omitempty"`
ApplicationName string `json:"applicationName"`
VersionLabel string `json:"versionLabel"`
ApplicationVersionARN string `json:"applicationVersionArn"`
Description string `json:"description,omitempty"`
DateCreated string `json:"dateCreated,omitempty"`
DateUpdated string `json:"dateUpdated,omitempty"`
Status string `json:"status"`
S3Bucket string `json:"s3Bucket,omitempty"`
S3Key string `json:"s3Key,omitempty"`
Process bool `json:"process"`
// contains filtered or unexported fields
}
ApplicationVersion represents an Elastic Beanstalk application version.
type ApplicationVersionParams ¶
type ApplicationVersionParams struct {
SourceBuildInformation *SourceBuildInformation
Tags map[string]string
Description string
S3Bucket string
S3Key string
Process bool
AutoCreateApplication bool
}
ApplicationVersionParams holds optional CreateApplicationVersion properties.
type ConfigurationTemplate ¶
type ConfigurationTemplate struct {
Tags map[string]string `json:"tags,omitempty"`
ApplicationName string `json:"applicationName"`
TemplateName string `json:"templateName"`
Description string `json:"description,omitempty"`
DateCreated string `json:"dateCreated,omitempty"`
DateUpdated string `json:"dateUpdated,omitempty"`
SolutionStackName string `json:"solutionStackName,omitempty"`
PlatformArn string `json:"platformArn,omitempty"`
OptionSettings []OptionSetting `json:"optionSettings,omitempty"`
// contains filtered or unexported fields
}
ConfigurationTemplate represents an Elastic Beanstalk configuration template.
type ConfigurationTemplateParams ¶ added in v1.2.0
type ConfigurationTemplateParams struct {
// PlatformArn is the ARN of a custom platform to base the template on.
// Real AWS documents PlatformArn and SolutionStackName as mutually
// exclusive -- see CreateConfigurationTemplateInput.
PlatformArn string
// OptionSettings overrides option values obtained from the solution
// stack/platform for this template.
OptionSettings []OptionSetting
}
ConfigurationTemplateParams holds optional CreateConfigurationTemplate properties beyond the application/template name, description and solution stack.
type CreateEnvironmentParams ¶
type CreateEnvironmentParams struct {
TierType string
TierName string
TierVersion string
CNAMEPrefix string
PlatformARN string
TemplateName string
VersionLabel string
OperationsRole string
LoadBalancerType string
VPCID string
Subnets string
InstanceProfile string
CustomAMI string
OptionSettings []OptionSetting
}
CreateEnvironmentParams holds optional parameters for CreateEnvironment (improvements #1, #5, #14, #15, #16).
type Environment ¶
type Environment struct {
Tags map[string]string `json:"tags,omitempty"`
Status string `json:"status"`
Health string `json:"health"`
EnvironmentName string `json:"environmentName"`
EnvironmentID string `json:"environmentId"`
EnvironmentARN string `json:"environmentArn"`
SolutionStackName string `json:"solutionStackName,omitempty"`
CustomAMI string `json:"customAMI,omitempty"`
TemplateName string `json:"templateName,omitempty"`
VersionLabel string `json:"versionLabel,omitempty"`
Description string `json:"description,omitempty"`
ApplicationName string `json:"applicationName"`
PlatformARN string `json:"platformArn,omitempty"`
TierVersion string `json:"tierVersion,omitempty"`
Tier string `json:"tier,omitempty"`
TierType string `json:"tierType,omitempty"`
TierName string `json:"tierName,omitempty"`
OperationsRole string `json:"operationsRole,omitempty"`
CNAME string `json:"cname,omitempty"`
CNAMEPrefix string `json:"cnamePrefix,omitempty"`
LoadBalancerType string `json:"loadBalancerType,omitempty"`
VPCID string `json:"vpcId,omitempty"`
Subnets string `json:"subnets,omitempty"`
InstanceProfile string `json:"instanceProfile,omitempty"`
DateCreated string `json:"dateCreated,omitempty"`
DateUpdated string `json:"dateUpdated,omitempty"`
Region string `json:"region"`
OptionSettings []OptionSetting `json:"optionSettings,omitempty"`
}
Environment represents an Elastic Beanstalk environment.
type EventRecord ¶
type EventRecord struct {
ApplicationName string `json:"applicationName,omitempty"`
EnvironmentName string `json:"environmentName,omitempty"`
EventDate string `json:"eventDate"`
Message string `json:"message"`
Severity string `json:"severity"`
}
EventRecord represents a single Elastic Beanstalk event.
type Handler ¶
type Handler struct {
Backend *InMemoryBackend
// contains filtered or unexported fields
}
Handler is the Echo HTTP handler for Elastic Beanstalk operations.
func NewHandler ¶
func NewHandler(backend *InMemoryBackend) *Handler
NewHandler creates a new Elastic Beanstalk handler.
func (*Handler) ChaosOperations ¶
ChaosOperations returns all operations that can be fault-injected.
func (*Handler) ChaosRegions ¶
ChaosRegions returns all regions this handler instance handles.
func (*Handler) ChaosServiceName ¶
ChaosServiceName returns the lowercase AWS service name for fault rule matching.
func (*Handler) ExtractOperation ¶
ExtractOperation extracts the Elastic Beanstalk action from the request.
func (*Handler) ExtractResource ¶
ExtractResource extracts a resource identifier from the request.
func (*Handler) GetSupportedOperations ¶
GetSupportedOperations returns the list of supported operations.
func (*Handler) Handler ¶
func (h *Handler) Handler() echo.HandlerFunc
Handler returns the Echo handler function for Elastic Beanstalk requests.
func (*Handler) MatchPriority ¶
MatchPriority returns the routing priority.
func (*Handler) RouteMatcher ¶
RouteMatcher returns a function that matches Elastic Beanstalk requests. Elastic Beanstalk uses the same Version=2010-12-01 as SES, so we disambiguate by matching on the Action field against the list of supported EB operations. We also require Version=2010-12-01 to avoid matching other services (e.g. SNS with Version=2010-03-31 or CloudWatch with Version=2010-08-01) that share the same action names (e.g. ListTagsForResource).
type InMemoryBackend ¶
type InMemoryBackend struct {
// contains filtered or unexported fields
}
InMemoryBackend stores AWS Elastic Beanstalk state in memory.
applications, environments, appVersions, configTemplates, and platformVersions were previously nested by region (outer key = region, e.g. map[string]map[string]*Application). Phase 3.3 of the datalayer refactor replaces each with a flat *store.Table, keyed by the composite "region|id" string (see regionKey), with companion *store.Index instances for per-region scans and ARN/name/CNAME reverse lookups -- see store_setup.go for the full rationale and every keyFn. managedActionHistory, events, and envCounters are deliberately NOT converted: they are slice- or scalar-valued maps with no single-value- per-key shape to model as a store.Table, so they remain plain region-nested maps, unchanged by this refactor.
func NewInMemoryBackend ¶
func NewInMemoryBackend(accountID, region string) *InMemoryBackend
NewInMemoryBackend creates a new InMemoryBackend.
func (*InMemoryBackend) AbortEnvironmentUpdate ¶
func (b *InMemoryBackend) AbortEnvironmentUpdate(_ context.Context, _ string) error
AbortEnvironmentUpdate aborts an in-progress environment configuration update. This is a no-op in the in-memory backend since updates complete instantly.
func (*InMemoryBackend) AddManagedActionHistory ¶
func (b *InMemoryBackend) AddManagedActionHistory( ctx context.Context, envName, actionID, actionType, actionDesc, status string, )
AddManagedActionHistory records a managed action history item for an environment (improvement #4).
func (*InMemoryBackend) ApplyEnvironmentManagedAction ¶
func (b *InMemoryBackend) ApplyEnvironmentManagedAction(ctx context.Context, envName, actionID string) error
ApplyEnvironmentManagedAction applies a scheduled managed action immediately. Records the action in the managed action history (improvement #4).
func (*InMemoryBackend) AssociateEnvironmentOperationsRole ¶
func (b *InMemoryBackend) AssociateEnvironmentOperationsRole( ctx context.Context, envName, role string, ) error
AssociateEnvironmentOperationsRole associates an operations IAM role with an environment.
func (*InMemoryBackend) CheckDNSAvailability ¶
func (b *InMemoryBackend) CheckDNSAvailability(ctx context.Context, cnamePrefix string) (bool, string)
CheckDNSAvailability checks whether the specified CNAME prefix is available. Returns available=true when no existing environment in the request region uses that prefix.
func (*InMemoryBackend) ComposeEnvironments ¶
func (b *InMemoryBackend) ComposeEnvironments(ctx context.Context, appName string) []*Environment
ComposeEnvironments returns existing environments for an application. In a real deployment this would create multiple environments; the stub returns the already-running environments for the given application. Results are sorted by EnvironmentName for deterministic output.
func (*InMemoryBackend) CreateApplication ¶
func (b *InMemoryBackend) CreateApplication( ctx context.Context, name, description string, tags map[string]string, ) (*Application, error)
CreateApplication creates a new Elastic Beanstalk application.
func (*InMemoryBackend) CreateApplicationVersion ¶
func (b *InMemoryBackend) CreateApplicationVersion( ctx context.Context, appName, versionLabel, description string, s3Bucket, s3Key string, tags map[string]string, ) (*ApplicationVersion, error)
CreateApplicationVersion creates a new application version.
func (*InMemoryBackend) CreateApplicationVersionWithParams ¶
func (b *InMemoryBackend) CreateApplicationVersionWithParams( ctx context.Context, appName, versionLabel string, params ApplicationVersionParams, ) (*ApplicationVersion, error)
CreateApplicationVersionWithParams creates a new application version with source and processing state.
func (*InMemoryBackend) CreateConfigurationTemplate ¶
func (b *InMemoryBackend) CreateConfigurationTemplate( ctx context.Context, appName, templateName, description, solutionStack string, tags map[string]string, ) (*ConfigurationTemplate, error)
CreateConfigurationTemplate creates a new configuration template for an application.
func (*InMemoryBackend) CreateConfigurationTemplateWithParams ¶ added in v1.2.0
func (b *InMemoryBackend) CreateConfigurationTemplateWithParams( ctx context.Context, appName, templateName, description, solutionStack string, tags map[string]string, params ConfigurationTemplateParams, ) (*ConfigurationTemplate, error)
CreateConfigurationTemplateWithParams creates a new configuration template, additionally accepting PlatformArn and OptionSettings (improvement: these were previously accepted on the wire but silently dropped, so a template's OptionSettings could never be set at creation time or read back via DescribeConfigurationSettings).
func (*InMemoryBackend) CreateEnvironment ¶
func (b *InMemoryBackend) CreateEnvironment( ctx context.Context, appName, envName, solutionStack, description string, tags map[string]string, params CreateEnvironmentParams, ) (*Environment, error)
CreateEnvironment creates a new Elastic Beanstalk environment.
func (*InMemoryBackend) CreatePlatformVersion ¶
func (b *InMemoryBackend) CreatePlatformVersion( ctx context.Context, platformName, platformVersion string, tags map[string]string, ) (*PlatformVersion, error)
CreatePlatformVersion creates a new custom platform version.
func (*InMemoryBackend) CreateStorageLocation ¶
func (b *InMemoryBackend) CreateStorageLocation(ctx context.Context) string
CreateStorageLocation returns the S3 bucket used for storing Elastic Beanstalk data. The bucket name is fixed per region and account, and creation is idempotent.
func (*InMemoryBackend) DeleteApplication ¶
func (b *InMemoryBackend) DeleteApplication(ctx context.Context, name string) error
DeleteApplication removes an application and all associated environments and versions.
func (*InMemoryBackend) DeleteApplicationVersion ¶
func (b *InMemoryBackend) DeleteApplicationVersion(ctx context.Context, appName, versionLabel string) error
DeleteApplicationVersion removes an application version.
func (*InMemoryBackend) DeleteConfigurationTemplate ¶
func (b *InMemoryBackend) DeleteConfigurationTemplate(ctx context.Context, appName, templateName string) error
DeleteConfigurationTemplate removes a configuration template.
func (*InMemoryBackend) DeleteEnvironmentConfiguration ¶
func (b *InMemoryBackend) DeleteEnvironmentConfiguration(_ context.Context, _, _ string) error
DeleteEnvironmentConfiguration deletes the draft configuration associated with an environment. This is a no-op in the in-memory backend.
func (*InMemoryBackend) DeletePlatformVersion ¶
func (b *InMemoryBackend) DeletePlatformVersion(ctx context.Context, platformARN string) (*PlatformVersion, error)
DeletePlatformVersion removes a platform version by ARN and returns the deleted version.
func (*InMemoryBackend) DescribeApplicationVersions ¶
func (b *InMemoryBackend) DescribeApplicationVersions( ctx context.Context, appName string, versionLabels []string, ) []*ApplicationVersion
DescribeApplicationVersions returns application versions, optionally filtered. Results are sorted by VersionLabel for deterministic output.
func (*InMemoryBackend) DescribeApplications ¶
func (b *InMemoryBackend) DescribeApplications(ctx context.Context, names []string) []*Application
DescribeApplications returns applications, optionally filtered by names. Results are sorted by ApplicationName for deterministic output.
func (*InMemoryBackend) DescribeConfigurationTemplates ¶
func (b *InMemoryBackend) DescribeConfigurationTemplates(ctx context.Context, appName string) []*ConfigurationTemplate
DescribeConfigurationTemplates returns all configuration templates for an application (improvement #17).
func (*InMemoryBackend) DescribeEnvironmentHealth ¶
func (b *InMemoryBackend) DescribeEnvironmentHealth(ctx context.Context, envName string) (string, string, error)
DescribeEnvironmentHealth returns the health and status of an environment by name.
func (*InMemoryBackend) DescribeEnvironmentManagedActionHistory ¶
func (b *InMemoryBackend) DescribeEnvironmentManagedActionHistory( ctx context.Context, envName string, ) []*ManagedActionHistory
DescribeEnvironmentManagedActionHistory returns stored managed action history for an environment (improvement #4).
func (*InMemoryBackend) DescribeEnvironments ¶
func (b *InMemoryBackend) DescribeEnvironments( ctx context.Context, appName string, envNames []string, envIDs []string, ) []*Environment
DescribeEnvironments returns environments, optionally filtered by app/environment names or IDs. Results are sorted by EnvironmentName for deterministic output.
func (*InMemoryBackend) DescribeEvents ¶
func (b *InMemoryBackend) DescribeEvents(ctx context.Context, appName, envName string) []*EventRecord
DescribeEvents returns event records filtered by optional application and environment name. The most recent events are returned first (reverse insertion order).
func (*InMemoryBackend) DescribePlatformVersion ¶
func (b *InMemoryBackend) DescribePlatformVersion(ctx context.Context, platformARN string) (*PlatformVersion, error)
DescribePlatformVersion returns a platform version by ARN.
func (*InMemoryBackend) DisassociateEnvironmentOperationsRole ¶
func (b *InMemoryBackend) DisassociateEnvironmentOperationsRole(ctx context.Context, envName string) error
DisassociateEnvironmentOperationsRole removes the operations role from an environment.
func (*InMemoryBackend) ListPlatformVersions ¶
func (b *InMemoryBackend) ListPlatformVersions(ctx context.Context) []*PlatformVersion
ListPlatformVersions returns all stored platform versions sorted by ARN.
func (*InMemoryBackend) ListTagsForResource ¶
func (b *InMemoryBackend) ListTagsForResource(ctx context.Context, resourceARN string) (map[string]string, error)
ListTagsForResource returns the tags for a resource identified by ARN. Tags are returned sorted by key for deterministic output.
func (*InMemoryBackend) Region ¶
func (b *InMemoryBackend) Region() string
Region returns the AWS region this backend is configured for.
func (*InMemoryBackend) Reset ¶
func (b *InMemoryBackend) Reset()
Reset clears all backend state, resetting to an empty store.
func (*InMemoryBackend) Restore ¶
func (b *InMemoryBackend) Restore(ctx context.Context, data []byte) error
Restore loads backend state from a JSON snapshot. It implements persistence.Persistable.
func (*InMemoryBackend) Snapshot ¶
func (b *InMemoryBackend) Snapshot(ctx context.Context) []byte
Snapshot serialises the backend state to JSON. It implements persistence.Persistable.
func (*InMemoryBackend) SwapEnvironmentCNAMEs ¶
func (b *InMemoryBackend) SwapEnvironmentCNAMEs(ctx context.Context, sourceEnvName, destEnvName string) error
SwapEnvironmentCNAMEs swaps the CNAME values between two environments (improvement #10).
func (*InMemoryBackend) TerminateEnvironment ¶
func (b *InMemoryBackend) TerminateEnvironment(ctx context.Context, appName, envName string) (*Environment, error)
TerminateEnvironment marks an environment as Terminated and removes it from storage.
func (*InMemoryBackend) UpdateApplication ¶
func (b *InMemoryBackend) UpdateApplication(ctx context.Context, name, description string) (*Application, error)
UpdateApplication updates an application's description.
func (*InMemoryBackend) UpdateApplicationResourceLifecycle ¶
func (b *InMemoryBackend) UpdateApplicationResourceLifecycle( ctx context.Context, appName, serviceRole string, ) (*Application, error)
UpdateApplicationResourceLifecycle stores the resource lifecycle service role on the application (improvement #7).
func (*InMemoryBackend) UpdateApplicationVersion ¶
func (b *InMemoryBackend) UpdateApplicationVersion( ctx context.Context, appName, versionLabel, description string, ) (*ApplicationVersion, error)
UpdateApplicationVersion updates an application version's description.
func (*InMemoryBackend) UpdateConfigurationTemplate ¶
func (b *InMemoryBackend) UpdateConfigurationTemplate( ctx context.Context, appName, templateName, description string, ) (*ConfigurationTemplate, error)
UpdateConfigurationTemplate updates a configuration template's description.
func (*InMemoryBackend) UpdateConfigurationTemplateWithParams ¶ added in v1.2.0
func (b *InMemoryBackend) UpdateConfigurationTemplateWithParams( ctx context.Context, appName, templateName string, params UpdateConfigurationTemplateParams, ) (*ConfigurationTemplate, error)
UpdateConfigurationTemplateWithParams updates a configuration template's description and/or option settings (improvement: OptionSettings/ OptionsToRemove were previously accepted on the wire but silently dropped -- see CreateConfigurationTemplateWithParams).
func (*InMemoryBackend) UpdateEnvironment ¶
func (b *InMemoryBackend) UpdateEnvironment( ctx context.Context, appName, envName, description, solutionStack string, ) (*Environment, error)
UpdateEnvironment updates an environment's description or solution stack.
func (*InMemoryBackend) UpdateEnvironmentWithParams ¶
func (b *InMemoryBackend) UpdateEnvironmentWithParams( ctx context.Context, appName, envName string, params UpdateEnvironmentParams, ) (*Environment, error)
UpdateEnvironmentWithParams applies all mutable environment properties.
func (*InMemoryBackend) UpdateTagsForResource ¶
func (b *InMemoryBackend) UpdateTagsForResource( ctx context.Context, resourceARN string, addTags, removeTags map[string]string, ) error
UpdateTagsForResource updates tags on a resource identified by ARN.
type ManagedActionHistory ¶
type ManagedActionHistory struct {
ActionID string `json:"actionId"`
ActionType string `json:"actionType"`
ActionDescription string `json:"actionDescription"`
Status string `json:"status"`
FinishedTime string `json:"finishedTime"`
}
ManagedActionHistory represents a record of a managed action that was applied (improvement #4).
type OptionSetting ¶
type OptionSetting struct {
Namespace string `json:"namespace"`
OptionName string `json:"optionName"`
ResourceName string `json:"resourceName,omitempty"`
Value string `json:"value,omitempty"`
}
OptionSetting is a configured Elastic Beanstalk environment option.
type PlatformVersion ¶
type PlatformVersion struct {
Tags map[string]string `json:"tags,omitempty"`
PlatformArn string `json:"platformArn"`
PlatformName string `json:"platformName"`
PlatformVersion string `json:"platformVersion"`
PlatformStatus string `json:"platformStatus"`
// contains filtered or unexported fields
}
PlatformVersion represents an Elastic Beanstalk platform version.
type Provider ¶
type Provider struct{}
Provider implements service.Provider for the Elastic Beanstalk service.
func (*Provider) Init ¶
func (p *Provider) Init(ctx *service.AppContext) (service.Registerable, error)
Init initializes the Elastic Beanstalk backend and handler.
type SourceBuildInformation ¶
type SourceBuildInformation struct {
SourceType string `json:"sourceType,omitempty"`
SourceRepository string `json:"sourceRepository,omitempty"`
SourceLocation string `json:"sourceLocation,omitempty"`
}
SourceBuildInformation identifies a CodeCommit source for an application version.
type UpdateConfigurationTemplateParams ¶ added in v1.2.0
type UpdateConfigurationTemplateParams struct {
Description string
OptionSettings []OptionSetting
OptionsToRemove []OptionSetting
}
UpdateConfigurationTemplateParams holds the mutable fields accepted by UpdateConfigurationTemplate (real AWS's UpdateConfigurationTemplateInput: Description, OptionSettings, OptionsToRemove -- unlike UpdateEnvironment, there is no SolutionStackName/PlatformArn/TemplateName swap support).
type UpdateEnvironmentParams ¶
type UpdateEnvironmentParams struct {
SolutionStackName string
PlatformARN string
TemplateName string
VersionLabel string
Description string
TierType string
TierName string
TierVersion string
OptionSettings []OptionSetting
OptionsToRemove []OptionSetting
}
UpdateEnvironmentParams holds state changes accepted by UpdateEnvironment.
Source Files
¶
- application_versions.go
- applications.go
- configuration_options.go
- configuration_templates.go
- environments.go
- errors.go
- events.go
- handler.go
- handler_account_attributes.go
- handler_application_versions.go
- handler_applications.go
- handler_configuration_templates.go
- handler_environments.go
- handler_events.go
- handler_instances_health.go
- handler_managed_actions.go
- handler_platforms.go
- handler_storage.go
- handler_tags.go
- managed_actions.go
- models.go
- persistence.go
- platforms.go
- provider.go
- storage.go
- store.go
- store_setup.go
- tags.go