Documentation
¶
Index ¶
- Variables
- type AccessLogSubscription
- type AccessLogSubscriptionSummary
- type AuthPolicy
- type DNSOptions
- type DomainVerification
- type DomainVerificationSummary
- type Handler
- 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 HeaderMatch
- type HealthCheckConfig
- type InMemoryBackend
- func (b *InMemoryBackend) AccountID() string
- func (b *InMemoryBackend) BatchUpdateRule(serviceID, listenerID string, updates []*RuleUpdate) ([]*RuleUpdateSuccess, []*RuleUpdateFailure, error)
- func (b *InMemoryBackend) CreateAccessLogSubscription(ctx context.Context, resourceID, destinationArn, logType string, ...) (*AccessLogSubscription, error)
- func (b *InMemoryBackend) CreateListener(serviceID, name, protocol string, port int32, defaultAction *RuleAction, ...) (*Listener, error)
- func (b *InMemoryBackend) CreateResourceConfiguration(ctx context.Context, ...) (*ResourceConfiguration, error)
- func (b *InMemoryBackend) CreateResourceGateway(ctx context.Context, ...) (*ResourceGateway, error)
- func (b *InMemoryBackend) CreateRule(serviceID, listenerID, name string, priority int32, action *RuleAction, ...) (*Rule, error)
- func (b *InMemoryBackend) CreateService(ctx context.Context, name, authType, certificateArn, customDomainName string, ...) (*Service, error)
- func (b *InMemoryBackend) CreateServiceNetwork(ctx context.Context, name, authType string, tags map[string]string) (*ServiceNetwork, error)
- func (b *InMemoryBackend) CreateServiceNetworkResourceAssociation(ctx context.Context, ...) (*ServiceNetworkResourceAssociation, error)
- func (b *InMemoryBackend) CreateServiceNetworkServiceAssociation(ctx context.Context, serviceNetworkID, serviceID string, ...) (*ServiceNetworkServiceAssociation, error)
- func (b *InMemoryBackend) CreateServiceNetworkVpcAssociation(ctx context.Context, serviceNetworkID, vpcID string, securityGroupIDs []string, ...) (*ServiceNetworkVpcAssociation, error)
- func (b *InMemoryBackend) CreateTargetGroup(ctx context.Context, name, tgType string, config *TargetGroupConfig, ...) (*TargetGroup, error)
- func (b *InMemoryBackend) DeleteAccessLogSubscription(alsID string) error
- func (b *InMemoryBackend) DeleteAuthPolicy(resourceID string) error
- func (b *InMemoryBackend) DeleteDomainVerification(id string) error
- func (b *InMemoryBackend) DeleteListener(serviceID, listenerID string) error
- func (b *InMemoryBackend) DeleteResourceConfiguration(id string) error
- func (b *InMemoryBackend) DeleteResourceEndpointAssociation(_ string) error
- func (b *InMemoryBackend) DeleteResourceGateway(id string) (*ResourceGateway, error)
- func (b *InMemoryBackend) DeleteResourcePolicy(resourceArn string) error
- func (b *InMemoryBackend) DeleteRule(serviceID, listenerID, ruleID string) error
- func (b *InMemoryBackend) DeleteService(serviceID string) (*Service, error)
- func (b *InMemoryBackend) DeleteServiceNetwork(snID string) error
- func (b *InMemoryBackend) DeleteServiceNetworkResourceAssociation(id string) (*ServiceNetworkResourceAssociation, error)
- func (b *InMemoryBackend) DeleteServiceNetworkServiceAssociation(snsaID string) error
- func (b *InMemoryBackend) DeleteServiceNetworkVpcAssociation(snvaID string) error
- func (b *InMemoryBackend) DeleteTargetGroup(tgID string) error
- func (b *InMemoryBackend) DeregisterTargets(tgID string, targets []*Target) ([]*TargetFailure, error)
- func (b *InMemoryBackend) GetAccessLogSubscription(alsID string) (*AccessLogSubscription, error)
- func (b *InMemoryBackend) GetAuthPolicy(resourceID string) (*AuthPolicy, error)
- func (b *InMemoryBackend) GetDomainVerification(id string) (*DomainVerification, error)
- func (b *InMemoryBackend) GetListener(serviceID, listenerID string) (*Listener, error)
- func (b *InMemoryBackend) GetResourceConfiguration(id string) (*ResourceConfiguration, error)
- func (b *InMemoryBackend) GetResourceGateway(id string) (*ResourceGateway, error)
- func (b *InMemoryBackend) GetResourcePolicy(resourceArn string) (string, error)
- func (b *InMemoryBackend) GetRule(serviceID, listenerID, ruleID string) (*Rule, error)
- func (b *InMemoryBackend) GetService(serviceID string) (*Service, error)
- func (b *InMemoryBackend) GetServiceNetwork(snID string) (*ServiceNetwork, error)
- func (b *InMemoryBackend) GetServiceNetworkResourceAssociation(id string) (*ServiceNetworkResourceAssociation, error)
- func (b *InMemoryBackend) GetServiceNetworkServiceAssociation(snsaID string) (*ServiceNetworkServiceAssociation, error)
- func (b *InMemoryBackend) GetServiceNetworkVpcAssociation(snvaID string) (*ServiceNetworkVpcAssociation, error)
- func (b *InMemoryBackend) GetTargetGroup(tgID string) (*TargetGroup, error)
- func (b *InMemoryBackend) ListAccessLogSubscriptions(_ context.Context, resourceID string, maxResults int32, nextToken string) ([]*AccessLogSubscriptionSummary, string, error)
- func (b *InMemoryBackend) ListDomainVerifications(ctx context.Context, maxResults int32, nextToken string) ([]*DomainVerificationSummary, string, error)
- func (b *InMemoryBackend) ListListeners(serviceID string, maxResults int32, nextToken string) ([]*ListenerSummary, string, error)
- func (b *InMemoryBackend) ListResourceConfigurations(ctx context.Context, ...) ([]*ResourceConfigurationSummary, string, error)
- func (b *InMemoryBackend) ListResourceEndpointAssociations(_ context.Context, _ int32, _ string) ([]*ResourceEndpointAssociationSummary, string, error)
- func (b *InMemoryBackend) ListResourceGateways(ctx context.Context, maxResults int32, nextToken string) ([]*ResourceGatewaySummary, string, error)
- func (b *InMemoryBackend) ListRules(serviceID, listenerID string, maxResults int32, nextToken string) ([]*RuleSummary, string, error)
- func (b *InMemoryBackend) ListServiceNetworkResourceAssociations(ctx context.Context, ...) ([]*ServiceNetworkResourceAssociationSummary, string, error)
- func (b *InMemoryBackend) ListServiceNetworkServiceAssociations(ctx context.Context, serviceNetworkID, serviceID string, maxResults int32, ...) ([]*ServiceNetworkServiceAssociationSummary, string, error)
- func (b *InMemoryBackend) ListServiceNetworkVpcAssociations(ctx context.Context, serviceNetworkID, vpcID string, maxResults int32, ...) ([]*ServiceNetworkVpcAssociationSummary, string, error)
- func (b *InMemoryBackend) ListServiceNetworkVpcEndpointAssociations(_ context.Context, _ string, _ int32, _ string) ([]*ServiceNetworkVpcEndpointAssociationSummary, string, error)
- func (b *InMemoryBackend) ListServiceNetworks(ctx context.Context, maxResults int32, nextToken string) ([]*ServiceNetworkSummary, string, error)
- func (b *InMemoryBackend) ListServices(ctx context.Context, maxResults int32, nextToken string) ([]*ServiceSummary, string, error)
- func (b *InMemoryBackend) ListTagsForResource(resourceArn string) (map[string]string, error)
- func (b *InMemoryBackend) ListTargetGroups(ctx context.Context, tgType, serviceArn string, maxResults int32, ...) ([]*TargetGroupSummary, string, error)
- func (b *InMemoryBackend) ListTargets(_ context.Context, tgID string, filters []Target, maxResults int32, ...) ([]*TargetSummary, string, error)
- func (b *InMemoryBackend) PutAuthPolicy(resourceID, policy string) (*AuthPolicy, error)
- func (b *InMemoryBackend) PutResourcePolicy(resourceArn, policy string) error
- func (b *InMemoryBackend) Region() string
- func (b *InMemoryBackend) RegisterTargets(tgID string, targets []*Target) ([]*TargetFailure, error)
- 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) StartDomainVerification(ctx context.Context, domainName string, tags map[string]string) (*DomainVerification, error)
- func (b *InMemoryBackend) TagResource(resourceArn string, tags map[string]string) error
- func (b *InMemoryBackend) TaggedResources() []TaggedEntry
- func (b *InMemoryBackend) UntagResource(resourceArn string, keys []string) error
- func (b *InMemoryBackend) UpdateAccessLogSubscription(alsID, destinationArn string) (*AccessLogSubscription, error)
- func (b *InMemoryBackend) UpdateListener(serviceID, listenerID string, defaultAction *RuleAction) (*Listener, error)
- func (b *InMemoryBackend) UpdateResourceConfiguration(id string, allowAssociationToShareableServiceNetwork *bool, ...) (*ResourceConfiguration, error)
- func (b *InMemoryBackend) UpdateResourceGateway(id string, securityGroupIDs []string) (*ResourceGateway, error)
- func (b *InMemoryBackend) UpdateRule(serviceID, listenerID, ruleID string, priority int32, action *RuleAction, ...) (*Rule, error)
- func (b *InMemoryBackend) UpdateService(serviceID, authType, certificateArn string) (*Service, error)
- func (b *InMemoryBackend) UpdateServiceNetwork(snID, authType string) (*ServiceNetwork, error)
- func (b *InMemoryBackend) UpdateServiceNetworkVpcAssociation(snvaID string, securityGroupIDs []string) (*ServiceNetworkVpcAssociation, error)
- func (b *InMemoryBackend) UpdateTargetGroup(tgID string, healthCheck *HealthCheckConfig) (*TargetGroup, error)
- type Listener
- type ListenerSummary
- type Provider
- type ResourceConfiguration
- type ResourceConfigurationDefinition
- type ResourceConfigurationSummary
- type ResourceEndpointAssociationSummary
- type ResourceGateway
- type ResourceGatewaySummary
- type Rule
- type RuleAction
- type RuleMatch
- type RuleSummary
- type RuleUpdate
- type RuleUpdateFailure
- type RuleUpdateSuccess
- type Service
- type ServiceNetwork
- type ServiceNetworkResourceAssociation
- type ServiceNetworkResourceAssociationSummary
- type ServiceNetworkServiceAssociation
- type ServiceNetworkServiceAssociationSummary
- type ServiceNetworkSummary
- type ServiceNetworkVpcAssociation
- type ServiceNetworkVpcAssociationSummary
- type ServiceNetworkVpcEndpointAssociationSummary
- type ServiceSummary
- type StorageBackend
- type TaggedEntry
- type Target
- type TargetFailure
- type TargetGroup
- type TargetGroupConfig
- type TargetGroupSummary
- type TargetSummary
- type WeightedTargetGroup
Constants ¶
This section is empty.
Variables ¶
var ( // ErrNotFound is returned when a resource does not exist. ErrNotFound = awserr.New("ResourceNotFoundException", awserr.ErrNotFound) // ErrAlreadyExists is returned when a resource already exists with the same name. ErrAlreadyExists = awserr.New("ConflictException", awserr.ErrAlreadyExists) // ErrInvalidParameter is returned for invalid input. ErrInvalidParameter = awserr.New("ValidationException", awserr.ErrInvalidParameter) // ErrDependencyConflict is returned when a delete is rejected because a // dependent resource still references the target (e.g. a service that is // still associated with a service network, a service network that still // has service or VPC associations, or a target group still referenced by // a listener rule). Real AWS returns ConflictException for all of these, // same as ErrAlreadyExists, but is kept as a distinct sentinel so callers // can tell "duplicate name" apart from "in use" via errors.Is. ErrDependencyConflict = awserr.New("ConflictException", awserr.ErrConflict) )
var ErrNilAppContext = errors.New("AppContext is required")
ErrNilAppContext is returned when Provider.Init is called with a nil AppContext.
Functions ¶
This section is empty.
Types ¶
type AccessLogSubscription ¶
type AccessLogSubscription struct {
CreatedAt time.Time
LastUpdatedAt time.Time
ARN string
ID string
ResourceARN string
ResourceID string
DestinationARN string
ServiceNetworkLogType string
}
AccessLogSubscription represents a VPC Lattice access log subscription.
type AccessLogSubscriptionSummary ¶
type AccessLogSubscriptionSummary struct {
CreatedAt time.Time
LastUpdatedAt time.Time
ARN string
ID string
ResourceARN string
ResourceID string
DestinationARN string
ServiceNetworkLogType string
}
AccessLogSubscriptionSummary is a summary for list responses.
type AuthPolicy ¶
AuthPolicy represents an auth policy on a VPC Lattice resource.
type DNSOptions ¶ added in v1.3.1
DNSOptions carries the DNS configuration options accepted by CreateServiceNetworkVpcAssociation (the real SDK's types.DnsOptions) -- set only at creation time, real AWS has no update path for it.
type DomainVerification ¶ added in v1.3.1
type DomainVerification struct {
CreatedAt time.Time
LastVerifiedTime *time.Time
ARN string
ID string
DomainName string
Status string
}
DomainVerification represents a custom domain ownership verification.
type DomainVerificationSummary ¶ added in v1.3.1
type DomainVerificationSummary struct {
CreatedAt time.Time
LastVerifiedTime *time.Time
ARN string
ID string
DomainName string
Status string
}
DomainVerificationSummary is a summary for list responses.
type Handler ¶
type Handler struct {
Backend StorageBackend
}
Handler handles VPC Lattice HTTP requests.
func (*Handler) ExtractOperation ¶
ExtractOperation classifies the request into an operation name.
func (*Handler) ExtractResource ¶
ExtractResource returns the primary resource identifier.
func (*Handler) GetSupportedOperations ¶
GetSupportedOperations returns all supported operations.
func (*Handler) Handler ¶
func (h *Handler) Handler() echo.HandlerFunc
Handler returns the Echo handler function for VPC Lattice requests.
func (*Handler) MatchPriority ¶
MatchPriority returns the routing priority.
func (*Handler) Restore ¶
Restore implements persistence.Persistable by delegating to the backend. See the Snapshot doc comment above for why this delegation is new.
func (*Handler) RouteMatcher ¶
RouteMatcher returns a function that matches VPC Lattice API requests.
func (*Handler) Snapshot ¶
Snapshot implements persistence.Persistable by delegating to the backend.
Prior to Phase 3.3, Handler had no Snapshot/Restore of its own even though InMemoryBackend implemented both (dead wiring: cli.go's setupPersistence type-asserts each registered service.Registerable -- here, *Handler -- against a persistable{Snapshot,Restore} interface, and only registers it with the persistence.Manager if that assertion succeeds; since Handler never declared these methods, VPC Lattice was silently never registered and never persisted). This delegation is what actually wires VPC Lattice into the persistence Manager.
type HeaderMatch ¶
type HeaderMatch struct {
Name string `json:"name"`
MatchType string `json:"matchType"`
MatchValue string `json:"matchValue"`
CaseSensitive bool `json:"caseSensitive"`
}
HeaderMatch is an HTTP header match condition.
type HealthCheckConfig ¶
type HealthCheckConfig struct {
Protocol string `json:"protocol,omitempty"`
ProtocolVersion string `json:"protocolVersion,omitempty"`
Path string `json:"path,omitempty"`
MatcherHTTPCode string `json:"matcherHttpCode,omitempty"`
Port int32 `json:"port,omitempty"`
HealthyThresholdCount int32 `json:"healthyThresholdCount,omitempty"`
UnhealthyThresholdCount int32 `json:"unhealthyThresholdCount,omitempty"`
HealthCheckIntervalSeconds int32 `json:"healthCheckIntervalSeconds,omitempty"`
HealthCheckTimeoutSeconds int32 `json:"healthCheckTimeoutSeconds,omitempty"`
Enabled bool `json:"enabled,omitempty"`
}
HealthCheckConfig is the health check configuration for a target group.
type InMemoryBackend ¶
type InMemoryBackend struct {
// contains filtered or unexported fields
}
InMemoryBackend is an in-memory implementation of StorageBackend.
func NewInMemoryBackend ¶
func NewInMemoryBackend(accountID, region string) *InMemoryBackend
NewInMemoryBackend creates a new InMemoryBackend.
func (*InMemoryBackend) AccountID ¶
func (b *InMemoryBackend) AccountID() string
AccountID returns the configured account ID.
func (*InMemoryBackend) BatchUpdateRule ¶
func (b *InMemoryBackend) BatchUpdateRule( serviceID, listenerID string, updates []*RuleUpdate, ) ([]*RuleUpdateSuccess, []*RuleUpdateFailure, error)
BatchUpdateRule updates multiple rules atomically.
func (*InMemoryBackend) CreateAccessLogSubscription ¶
func (b *InMemoryBackend) CreateAccessLogSubscription( ctx context.Context, resourceID, destinationArn, logType string, tags map[string]string, ) (*AccessLogSubscription, error)
CreateAccessLogSubscription creates an access log subscription.
func (*InMemoryBackend) CreateListener ¶
func (b *InMemoryBackend) CreateListener( serviceID, name, protocol string, port int32, defaultAction *RuleAction, tags map[string]string, ) (*Listener, error)
CreateListener creates a listener on a service.
func (*InMemoryBackend) CreateResourceConfiguration ¶ added in v1.3.1
func (b *InMemoryBackend) CreateResourceConfiguration( ctx context.Context, name, resourceType, protocol, resourceGatewayIdentifier, resourceConfigurationGroupIdentifier string, allowAssociationToShareableServiceNetwork bool, portRanges []string, definition *ResourceConfigurationDefinition, customDomainName, domainVerificationID, groupDomain string, tags map[string]string, ) (*ResourceConfiguration, error)
CreateResourceConfiguration creates a new resource configuration. resourceGatewayIdentifier and resourceConfigurationGroupIdentifier are both optional and, when non-empty, must resolve to an existing resource gateway / GROUP-type resource configuration respectively -- a CHILD configuration inherits its ResourceGatewayId from the parent GROUP, per CreateResourceConfigurationInput's doc comment. groupDomain, when non-empty, is stored directly (real API: settable on GROUP-type create); a CHILD with no explicit groupDomain inherits its parent GROUP's value.
func (*InMemoryBackend) CreateResourceGateway ¶ added in v1.3.1
func (b *InMemoryBackend) CreateResourceGateway( ctx context.Context, name, vpcID, ipAddressType, resourceConfigDNSResolution string, ipv4AddressesPerENI int32, securityGroupIDs, subnetIDs []string, tags map[string]string, ) (*ResourceGateway, error)
CreateResourceGateway creates a new resource gateway.
func (*InMemoryBackend) CreateRule ¶
func (b *InMemoryBackend) CreateRule( serviceID, listenerID, name string, priority int32, action *RuleAction, match *RuleMatch, tags map[string]string, ) (*Rule, error)
CreateRule creates a listener rule.
func (*InMemoryBackend) CreateService ¶
func (b *InMemoryBackend) CreateService( ctx context.Context, name, authType, certificateArn, customDomainName string, tags map[string]string, ) (*Service, error)
CreateService creates a new service.
func (*InMemoryBackend) CreateServiceNetwork ¶
func (b *InMemoryBackend) CreateServiceNetwork( ctx context.Context, name, authType string, tags map[string]string, ) (*ServiceNetwork, error)
CreateServiceNetwork creates a new service network.
func (*InMemoryBackend) CreateServiceNetworkResourceAssociation ¶ added in v1.3.1
func (b *InMemoryBackend) CreateServiceNetworkResourceAssociation( ctx context.Context, serviceNetworkIdentifier, resourceConfigurationIdentifier string, privateDNSEnabled bool, tags map[string]string, ) (*ServiceNetworkResourceAssociation, error)
CreateServiceNetworkResourceAssociation associates a resource configuration with a service network.
func (*InMemoryBackend) CreateServiceNetworkServiceAssociation ¶
func (b *InMemoryBackend) CreateServiceNetworkServiceAssociation( ctx context.Context, serviceNetworkID, serviceID string, tags map[string]string, ) (*ServiceNetworkServiceAssociation, error)
CreateServiceNetworkServiceAssociation creates a service-to-network association.
func (*InMemoryBackend) CreateServiceNetworkVpcAssociation ¶
func (b *InMemoryBackend) CreateServiceNetworkVpcAssociation( ctx context.Context, serviceNetworkID, vpcID string, securityGroupIDs []string, privateDNSEnabled bool, dnsOptions *DNSOptions, tags map[string]string, ) (*ServiceNetworkVpcAssociation, error)
CreateServiceNetworkVpcAssociation creates a VPC-to-network association.
func (*InMemoryBackend) CreateTargetGroup ¶
func (b *InMemoryBackend) CreateTargetGroup( ctx context.Context, name, tgType string, config *TargetGroupConfig, tags map[string]string, ) (*TargetGroup, error)
CreateTargetGroup creates a target group.
func (*InMemoryBackend) DeleteAccessLogSubscription ¶
func (b *InMemoryBackend) DeleteAccessLogSubscription(alsID string) error
DeleteAccessLogSubscription deletes an access log subscription.
func (*InMemoryBackend) DeleteAuthPolicy ¶
func (b *InMemoryBackend) DeleteAuthPolicy(resourceID string) error
DeleteAuthPolicy deletes the auth policy for a resource.
func (*InMemoryBackend) DeleteDomainVerification ¶ added in v1.3.1
func (b *InMemoryBackend) DeleteDomainVerification(id string) error
DeleteDomainVerification deletes a domain verification.
func (*InMemoryBackend) DeleteListener ¶
func (b *InMemoryBackend) DeleteListener(serviceID, listenerID string) error
DeleteListener deletes a listener and its rules.
func (*InMemoryBackend) DeleteResourceConfiguration ¶ added in v1.3.1
func (b *InMemoryBackend) DeleteResourceConfiguration(id string) error
DeleteResourceConfiguration deletes a resource configuration. Real AWS rejects the delete with ConflictException while any ServiceNetworkResourceAssociation or CHILD configuration still references it.
func (*InMemoryBackend) DeleteResourceEndpointAssociation ¶ added in v1.3.1
func (b *InMemoryBackend) DeleteResourceEndpointAssociation(_ string) error
DeleteResourceEndpointAssociation always reports not found -- no association can ever exist in this backend, see the family doc comment above.
func (*InMemoryBackend) DeleteResourceGateway ¶ added in v1.3.1
func (b *InMemoryBackend) DeleteResourceGateway(id string) (*ResourceGateway, error)
DeleteResourceGateway deletes a resource gateway. Real AWS rejects the delete with ConflictException while any resource configuration still references the gateway (CreateResourceConfiguration's ResourceGatewayIdentifier).
func (*InMemoryBackend) DeleteResourcePolicy ¶
func (b *InMemoryBackend) DeleteResourcePolicy(resourceArn string) error
DeleteResourcePolicy deletes a resource policy.
func (*InMemoryBackend) DeleteRule ¶
func (b *InMemoryBackend) DeleteRule(serviceID, listenerID, ruleID string) error
DeleteRule deletes a rule.
func (*InMemoryBackend) DeleteService ¶
func (b *InMemoryBackend) DeleteService(serviceID string) (*Service, error)
DeleteService deletes a service. Real AWS rejects the delete with ConflictException while the service is still associated with a service network, and otherwise cascades the delete through the service's listeners, listener rules, resource policy, auth policy, and access log subscriptions -- see the DeleteService doc comment in aws-sdk-go-v2/service/vpclattice's api_op_DeleteService.go.
func (*InMemoryBackend) DeleteServiceNetwork ¶
func (b *InMemoryBackend) DeleteServiceNetwork(snID string) error
DeleteServiceNetwork deletes a service network. Real AWS rejects the delete with ConflictException while any service or VPC is still associated with the service network, and otherwise cascades the delete through the service network's resource policy, auth policy, and access log subscriptions -- see the DeleteServiceNetwork doc comment in aws-sdk-go-v2/service/vpclattice's api_op_DeleteServiceNetwork.go.
func (*InMemoryBackend) DeleteServiceNetworkResourceAssociation ¶ added in v1.3.1
func (b *InMemoryBackend) DeleteServiceNetworkResourceAssociation( id string, ) (*ServiceNetworkResourceAssociation, error)
DeleteServiceNetworkResourceAssociation deletes a SNRA.
func (*InMemoryBackend) DeleteServiceNetworkServiceAssociation ¶
func (b *InMemoryBackend) DeleteServiceNetworkServiceAssociation(snsaID string) error
DeleteServiceNetworkServiceAssociation deletes a SNSA.
func (*InMemoryBackend) DeleteServiceNetworkVpcAssociation ¶
func (b *InMemoryBackend) DeleteServiceNetworkVpcAssociation(snvaID string) error
DeleteServiceNetworkVpcAssociation deletes a SNVA.
func (*InMemoryBackend) DeleteTargetGroup ¶
func (b *InMemoryBackend) DeleteTargetGroup(tgID string) error
DeleteTargetGroup deletes a target group. Real AWS rejects the delete with ConflictException while the target group is still referenced by a listener rule (or, per the doc comment, while creation is still in progress -- not applicable here, since this backend's Create paths are synchronous) -- see the DeleteTargetGroup doc comment in aws-sdk-go-v2/service/vpclattice's api_op_DeleteTargetGroup.go.
func (*InMemoryBackend) DeregisterTargets ¶
func (b *InMemoryBackend) DeregisterTargets( tgID string, targets []*Target, ) ([]*TargetFailure, error)
DeregisterTargets deregisters targets from a target group.
func (*InMemoryBackend) GetAccessLogSubscription ¶
func (b *InMemoryBackend) GetAccessLogSubscription(alsID string) (*AccessLogSubscription, error)
GetAccessLogSubscription returns an access log subscription.
func (*InMemoryBackend) GetAuthPolicy ¶
func (b *InMemoryBackend) GetAuthPolicy(resourceID string) (*AuthPolicy, error)
GetAuthPolicy returns the auth policy for a resource.
func (*InMemoryBackend) GetDomainVerification ¶ added in v1.3.1
func (b *InMemoryBackend) GetDomainVerification(id string) (*DomainVerification, error)
GetDomainVerification returns a domain verification.
func (*InMemoryBackend) GetListener ¶
func (b *InMemoryBackend) GetListener(serviceID, listenerID string) (*Listener, error)
GetListener returns a listener.
func (*InMemoryBackend) GetResourceConfiguration ¶ added in v1.3.1
func (b *InMemoryBackend) GetResourceConfiguration(id string) (*ResourceConfiguration, error)
GetResourceConfiguration returns a resource configuration.
func (*InMemoryBackend) GetResourceGateway ¶ added in v1.3.1
func (b *InMemoryBackend) GetResourceGateway(id string) (*ResourceGateway, error)
GetResourceGateway returns a resource gateway.
func (*InMemoryBackend) GetResourcePolicy ¶
func (b *InMemoryBackend) GetResourcePolicy(resourceArn string) (string, error)
GetResourcePolicy returns a resource policy.
func (*InMemoryBackend) GetRule ¶
func (b *InMemoryBackend) GetRule(serviceID, listenerID, ruleID string) (*Rule, error)
GetRule returns a rule.
func (*InMemoryBackend) GetService ¶
func (b *InMemoryBackend) GetService(serviceID string) (*Service, error)
GetService returns a service by ID or ARN.
func (*InMemoryBackend) GetServiceNetwork ¶
func (b *InMemoryBackend) GetServiceNetwork(snID string) (*ServiceNetwork, error)
GetServiceNetwork returns a service network.
func (*InMemoryBackend) GetServiceNetworkResourceAssociation ¶ added in v1.3.1
func (b *InMemoryBackend) GetServiceNetworkResourceAssociation(id string) (*ServiceNetworkResourceAssociation, error)
GetServiceNetworkResourceAssociation returns a SNRA.
func (*InMemoryBackend) GetServiceNetworkServiceAssociation ¶
func (b *InMemoryBackend) GetServiceNetworkServiceAssociation( snsaID string, ) (*ServiceNetworkServiceAssociation, error)
GetServiceNetworkServiceAssociation returns a SNSA by ID or ARN.
func (*InMemoryBackend) GetServiceNetworkVpcAssociation ¶
func (b *InMemoryBackend) GetServiceNetworkVpcAssociation( snvaID string, ) (*ServiceNetworkVpcAssociation, error)
GetServiceNetworkVpcAssociation returns a SNVA.
func (*InMemoryBackend) GetTargetGroup ¶
func (b *InMemoryBackend) GetTargetGroup(tgID string) (*TargetGroup, error)
GetTargetGroup returns a target group.
func (*InMemoryBackend) ListAccessLogSubscriptions ¶
func (b *InMemoryBackend) ListAccessLogSubscriptions( _ context.Context, resourceID string, maxResults int32, nextToken string, ) ([]*AccessLogSubscriptionSummary, string, error)
ListAccessLogSubscriptions lists access log subscriptions for a resource.
func (*InMemoryBackend) ListDomainVerifications ¶ added in v1.3.1
func (b *InMemoryBackend) ListDomainVerifications( ctx context.Context, maxResults int32, nextToken string, ) ([]*DomainVerificationSummary, string, error)
ListDomainVerifications returns a paginated list of domain verifications.
func (*InMemoryBackend) ListListeners ¶
func (b *InMemoryBackend) ListListeners( serviceID string, maxResults int32, nextToken string, ) ([]*ListenerSummary, string, error)
ListListeners lists listeners for a service.
func (*InMemoryBackend) ListResourceConfigurations ¶ added in v1.3.1
func (b *InMemoryBackend) ListResourceConfigurations( ctx context.Context, resourceGatewayIdentifier, resourceConfigurationGroupIdentifier string, maxResults int32, nextToken string, ) ([]*ResourceConfigurationSummary, string, error)
ListResourceConfigurations returns a paginated list of resource configurations, optionally filtered by resource gateway or group parent.
func (*InMemoryBackend) ListResourceEndpointAssociations ¶ added in v1.3.1
func (b *InMemoryBackend) ListResourceEndpointAssociations( _ context.Context, _ int32, _ string, ) ([]*ResourceEndpointAssociationSummary, string, error)
ListResourceEndpointAssociations always returns an empty page -- see the family doc comment above.
func (*InMemoryBackend) ListResourceGateways ¶ added in v1.3.1
func (b *InMemoryBackend) ListResourceGateways( ctx context.Context, maxResults int32, nextToken string, ) ([]*ResourceGatewaySummary, string, error)
ListResourceGateways returns a paginated list of resource gateways.
func (*InMemoryBackend) ListRules ¶
func (b *InMemoryBackend) ListRules( serviceID, listenerID string, maxResults int32, nextToken string, ) ([]*RuleSummary, string, error)
ListRules lists rules for a listener.
func (*InMemoryBackend) ListServiceNetworkResourceAssociations ¶ added in v1.3.1
func (b *InMemoryBackend) ListServiceNetworkResourceAssociations( ctx context.Context, serviceNetworkIdentifier, resourceConfigurationIdentifier string, maxResults int32, nextToken string, ) ([]*ServiceNetworkResourceAssociationSummary, string, error)
ListServiceNetworkResourceAssociations lists SNRAs with optional filters.
func (*InMemoryBackend) ListServiceNetworkServiceAssociations ¶
func (b *InMemoryBackend) ListServiceNetworkServiceAssociations( ctx context.Context, serviceNetworkID, serviceID string, maxResults int32, nextToken string, ) ([]*ServiceNetworkServiceAssociationSummary, string, error)
ListServiceNetworkServiceAssociations lists SNSAs with optional filters.
func (*InMemoryBackend) ListServiceNetworkVpcAssociations ¶
func (b *InMemoryBackend) ListServiceNetworkVpcAssociations( ctx context.Context, serviceNetworkID, vpcID string, maxResults int32, nextToken string, ) ([]*ServiceNetworkVpcAssociationSummary, string, error)
ListServiceNetworkVpcAssociations lists SNVAs with optional filters.
func (*InMemoryBackend) ListServiceNetworkVpcEndpointAssociations ¶ added in v1.3.1
func (b *InMemoryBackend) ListServiceNetworkVpcEndpointAssociations( _ context.Context, _ string, _ int32, _ string, ) ([]*ServiceNetworkVpcEndpointAssociationSummary, string, error)
ListServiceNetworkVpcEndpointAssociations always returns an empty page -- see the family doc comment above.
func (*InMemoryBackend) ListServiceNetworks ¶
func (b *InMemoryBackend) ListServiceNetworks( ctx context.Context, maxResults int32, nextToken string, ) ([]*ServiceNetworkSummary, string, error)
ListServiceNetworks returns a paginated list of service networks.
func (*InMemoryBackend) ListServices ¶
func (b *InMemoryBackend) ListServices( ctx context.Context, maxResults int32, nextToken string, ) ([]*ServiceSummary, string, error)
ListServices returns a paginated list of services.
func (*InMemoryBackend) ListTagsForResource ¶
func (b *InMemoryBackend) ListTagsForResource(resourceArn string) (map[string]string, error)
ListTagsForResource returns tags for a resource.
func (*InMemoryBackend) ListTargetGroups ¶
func (b *InMemoryBackend) ListTargetGroups( ctx context.Context, tgType, serviceArn string, maxResults int32, nextToken string, ) ([]*TargetGroupSummary, string, error)
ListTargetGroups lists target groups with optional filters.
func (*InMemoryBackend) ListTargets ¶
func (b *InMemoryBackend) ListTargets( _ context.Context, tgID string, filters []Target, maxResults int32, nextToken string, ) ([]*TargetSummary, string, error)
ListTargets lists registered targets for a target group.
func (*InMemoryBackend) PutAuthPolicy ¶
func (b *InMemoryBackend) PutAuthPolicy(resourceID, policy string) (*AuthPolicy, error)
PutAuthPolicy sets an auth policy on a resource.
func (*InMemoryBackend) PutResourcePolicy ¶
func (b *InMemoryBackend) PutResourcePolicy(resourceArn, policy string) error
PutResourcePolicy sets a resource policy. resourceArn accepts an ID or ARN (see resolvePolicyResourceARN in auth_policy.go for why it's normalized).
func (*InMemoryBackend) Region ¶
func (b *InMemoryBackend) Region() string
Region returns the configured region.
func (*InMemoryBackend) RegisterTargets ¶
func (b *InMemoryBackend) RegisterTargets( tgID string, targets []*Target, ) ([]*TargetFailure, error)
RegisterTargets registers targets to a target group.
func (*InMemoryBackend) Restore ¶
func (b *InMemoryBackend) Restore(ctx context.Context, data []byte) error
Restore deserializes state from JSON.
func (*InMemoryBackend) Snapshot ¶
func (b *InMemoryBackend) Snapshot(ctx context.Context) []byte
Snapshot serializes current state to JSON.
func (*InMemoryBackend) StartDomainVerification ¶ added in v1.3.1
func (b *InMemoryBackend) StartDomainVerification( ctx context.Context, domainName string, tags map[string]string, ) (*DomainVerification, error)
StartDomainVerification begins ownership verification for a custom domain name. Real AWS returns a TXT record for the caller to publish and polls public DNS for it; this backend has no DNS to observe, so the verification is created and stays PENDING forever -- see storedDomainVerification's doc comment.
func (*InMemoryBackend) TagResource ¶
func (b *InMemoryBackend) TagResource(resourceArn string, tags map[string]string) error
TagResource adds tags to a resource.
func (*InMemoryBackend) TaggedResources ¶ added in v1.3.1
func (b *InMemoryBackend) TaggedResources() []TaggedEntry
TaggedResources returns every VPC Lattice resource ARN that currently has at least one tag applied via TagResource.
func (*InMemoryBackend) UntagResource ¶
func (b *InMemoryBackend) UntagResource(resourceArn string, keys []string) error
UntagResource removes tags from a resource.
func (*InMemoryBackend) UpdateAccessLogSubscription ¶
func (b *InMemoryBackend) UpdateAccessLogSubscription( alsID, destinationArn string, ) (*AccessLogSubscription, error)
UpdateAccessLogSubscription updates the destination ARN.
func (*InMemoryBackend) UpdateListener ¶
func (b *InMemoryBackend) UpdateListener( serviceID, listenerID string, defaultAction *RuleAction, ) (*Listener, error)
UpdateListener updates the default action of a listener.
func (*InMemoryBackend) UpdateResourceConfiguration ¶ added in v1.3.1
func (b *InMemoryBackend) UpdateResourceConfiguration( id string, allowAssociationToShareableServiceNetwork *bool, portRanges []string, definition *ResourceConfigurationDefinition, ) (*ResourceConfiguration, error)
UpdateResourceConfiguration updates a resource configuration's AllowShareableAssoc/PortRanges/ ResourceConfigurationDefinition -- the only fields UpdateResourceConfigurationInput accepts besides the identifier.
func (*InMemoryBackend) UpdateResourceGateway ¶ added in v1.3.1
func (b *InMemoryBackend) UpdateResourceGateway(id string, securityGroupIDs []string) (*ResourceGateway, error)
UpdateResourceGateway updates a resource gateway's security groups -- the only field UpdateResourceGatewayInput accepts besides the identifier.
func (*InMemoryBackend) UpdateRule ¶
func (b *InMemoryBackend) UpdateRule( serviceID, listenerID, ruleID string, priority int32, action *RuleAction, match *RuleMatch, ) (*Rule, error)
UpdateRule updates a rule.
func (*InMemoryBackend) UpdateService ¶
func (b *InMemoryBackend) UpdateService( serviceID, authType, certificateArn string, ) (*Service, error)
UpdateService updates a service.
func (*InMemoryBackend) UpdateServiceNetwork ¶
func (b *InMemoryBackend) UpdateServiceNetwork(snID, authType string) (*ServiceNetwork, error)
UpdateServiceNetwork updates a service network.
func (*InMemoryBackend) UpdateServiceNetworkVpcAssociation ¶
func (b *InMemoryBackend) UpdateServiceNetworkVpcAssociation( snvaID string, securityGroupIDs []string, ) (*ServiceNetworkVpcAssociation, error)
UpdateServiceNetworkVpcAssociation updates security groups on a SNVA.
func (*InMemoryBackend) UpdateTargetGroup ¶
func (b *InMemoryBackend) UpdateTargetGroup( tgID string, healthCheck *HealthCheckConfig, ) (*TargetGroup, error)
UpdateTargetGroup updates a target group's health check config.
type Listener ¶
type Listener struct {
DefaultAction *RuleAction
CreatedAt time.Time
LastUpdatedAt time.Time
ARN string
ID string
ServiceARN string
ServiceID string
Name string
Protocol string
Port int32
}
Listener represents a VPC Lattice listener.
type ListenerSummary ¶
type ListenerSummary struct {
CreatedAt time.Time
LastUpdatedAt time.Time
ARN string
ID string
Name string
Protocol string
Port int32
}
ListenerSummary is a listener entry for list responses.
type Provider ¶
type Provider struct{}
Provider implements service.Provider for the VPC Lattice service.
func (*Provider) Init ¶
func (p *Provider) Init(ctx *service.AppContext) (service.Registerable, error)
Init initializes the VPC Lattice backend and handler.
type ResourceConfiguration ¶ added in v1.3.1
type ResourceConfiguration struct {
CreatedAt time.Time
LastUpdatedAt time.Time
Definition *ResourceConfigurationDefinition
ARN string
ID string
Name string
Type string
Status string
Protocol string
ResourceGatewayID string
ResourceConfigurationGroupID string
CustomDomainName string
GroupDomain string
DomainVerificationID string
PortRanges []string
}
ResourceConfiguration represents a VPC Lattice resource configuration.
type ResourceConfigurationDefinition ¶ added in v1.3.1
type ResourceConfigurationDefinition struct {
Kind string // "arnResource" | "dnsResource" | "ipResource"
ArnValue string
DomainName string
IPAddressType string
IPAddress string
}
ResourceConfigurationDefinition identifies the underlying resource a ResourceConfiguration points at (types.ResourceConfigurationDefinition, a wire union of arnResource/dnsResource/ipResource). Exactly one of ArnValue/DomainName+IPAddressType/IPAddress is populated, selected by Kind.
type ResourceConfigurationSummary ¶ added in v1.3.1
type ResourceConfigurationSummary struct {
CreatedAt time.Time
LastUpdatedAt time.Time
ARN string
ID string
Name string
Type string
Status string
ResourceGatewayID string
ResourceConfigurationGroupID string
CustomDomainName string
GroupDomain string
DomainVerificationID string
}
ResourceConfigurationSummary is a resource configuration entry for list responses.
type ResourceEndpointAssociationSummary ¶ added in v1.3.1
type ResourceEndpointAssociationSummary struct {
CreatedAt time.Time
ARN string
ID string
ResourceConfigurationARN string
ResourceConfigurationID string
VpcEndpointID string
VpcEndpointOwner string
}
ResourceEndpointAssociationSummary is a summary for list responses. Real AWS populates this from EC2 VPC endpoints of type Resource pointed at a ResourceConfiguration -- vpc-lattice itself has no Create operation for this resource. This backend has no EC2 VPC-endpoint cross-service modeling, so ListResourceEndpointAssociations always returns empty (an honest reflection of "never created", not a fabricated entry) -- see service_network_resource_associations.go.
type ResourceGateway ¶ added in v1.3.1
type ResourceGateway struct {
CreatedAt time.Time
LastUpdatedAt time.Time
ARN string
ID string
Name string
VpcID string
IPAddressType string
ResourceConfigDNSResolution string
Status string
SecurityGroupIDs []string
SubnetIDs []string
Ipv4AddressesPerEni int32
}
ResourceGateway represents a VPC Lattice resource gateway -- a point of ingress into a VPC where a resource (behind a ResourceConfiguration) resides.
type ResourceGatewaySummary ¶ added in v1.3.1
type ResourceGatewaySummary struct {
CreatedAt time.Time
LastUpdatedAt time.Time
ARN string
ID string
Name string
VpcID string
IPAddressType string
ResourceConfigDNSResolution string
Status string
SecurityGroupIDs []string
SubnetIDs []string
Ipv4AddressesPerEni int32
}
ResourceGatewaySummary is a resource gateway entry for list responses.
type Rule ¶
type Rule struct {
Action *RuleAction
Match *RuleMatch
CreatedAt time.Time
LastUpdatedAt time.Time
ARN string
ID string
Name string
Priority int32
IsDefault bool
}
Rule represents a VPC Lattice listener rule.
type RuleAction ¶
type RuleAction struct {
ForwardTargetGroups []*WeightedTargetGroup `json:"forwardTargetGroups,omitempty"`
FixedResponseStatusCode int32 `json:"fixedResponseStatusCode,omitempty"`
IsFixedResponse bool `json:"isFixedResponse,omitempty"`
}
RuleAction is the action for a listener rule.
type RuleMatch ¶
type RuleMatch struct {
HTTPMethod string `json:"httpMethod,omitempty"`
PathMatchType string `json:"pathMatchType,omitempty"`
PathMatchValue string `json:"pathMatchValue,omitempty"`
HeaderMatches []*HeaderMatch `json:"headerMatches,omitempty"`
PathCaseSensitive bool `json:"pathCaseSensitive,omitempty"`
}
RuleMatch is the match conditions for a listener rule.
type RuleSummary ¶
type RuleSummary struct {
CreatedAt time.Time
LastUpdatedAt time.Time
ARN string
ID string
Name string
Priority int32
IsDefault bool
}
RuleSummary is a rule entry for list responses.
type RuleUpdate ¶
type RuleUpdate struct {
Action *RuleAction
Match *RuleMatch
RuleIdentifier string
Priority int32
}
RuleUpdate is an update spec for BatchUpdateRule.
type RuleUpdateFailure ¶
RuleUpdateFailure is a failed rule update result.
type RuleUpdateSuccess ¶
type RuleUpdateSuccess struct {
Action *RuleAction
Match *RuleMatch
ARN string
ID string
Name string
Priority int32
IsDefault bool
}
RuleUpdateSuccess is a successful rule update result.
type Service ¶
type Service struct {
CreatedAt time.Time
LastUpdatedAt time.Time
ARN string
ID string
Name string
AuthType string
CertificateArn string
CustomDomainName string
DNSName string
HostedZoneID string
Status string
}
Service represents a VPC Lattice service.
type ServiceNetwork ¶
type ServiceNetwork struct {
CreatedAt time.Time
LastUpdatedAt time.Time
ARN string
ID string
Name string
AuthType string
NumberOfAssociatedServices int64
NumberOfAssociatedVPCs int64
}
ServiceNetwork represents a VPC Lattice service network.
type ServiceNetworkResourceAssociation ¶ added in v1.3.1
type ServiceNetworkResourceAssociation struct {
CreatedAt time.Time
LastUpdatedAt time.Time
ARN string
ID string
ResourceConfigurationARN string
ResourceConfigurationID string
ResourceConfigurationName string
ServiceNetworkARN string
ServiceNetworkID string
ServiceNetworkName string
Status string
CreatedBy string
PrivateDNSEnabled bool
}
ServiceNetworkResourceAssociation associates a resource configuration with a service network.
type ServiceNetworkResourceAssociationSummary ¶ added in v1.3.1
type ServiceNetworkResourceAssociationSummary struct {
CreatedAt time.Time
ARN string
ID string
ResourceConfigurationARN string
ResourceConfigurationID string
ResourceConfigurationName string
ServiceNetworkARN string
ServiceNetworkID string
ServiceNetworkName string
Status string
}
ServiceNetworkResourceAssociationSummary is a summary for list responses.
type ServiceNetworkServiceAssociation ¶
type ServiceNetworkServiceAssociation struct {
CreatedAt time.Time
ARN string
ID string
ServiceARN string
ServiceID string
ServiceName string
ServiceNetworkARN string
ServiceNetworkID string
ServiceNetworkName string
Status string
CreatedBy string
CustomDomainName string
DNSName string
HostedZoneID string
}
ServiceNetworkServiceAssociation is a service-to-service-network association.
type ServiceNetworkServiceAssociationSummary ¶
type ServiceNetworkServiceAssociationSummary struct {
CreatedAt time.Time
ARN string
ID string
ServiceARN string
ServiceID string
ServiceName string
ServiceNetworkARN string
ServiceNetworkID string
ServiceNetworkName string
Status string
CustomDomainName string
DNSName string
HostedZoneID string
}
ServiceNetworkServiceAssociationSummary is a summary for list responses.
type ServiceNetworkSummary ¶
type ServiceNetworkSummary struct {
CreatedAt time.Time
ARN string
ID string
Name string
NumberOfAssociatedServices int64
NumberOfAssociatedVPCs int64
NumberOfAssociatedResourceConfigurations int64
}
ServiceNetworkSummary is a service network entry for list responses.
type ServiceNetworkVpcAssociation ¶
type ServiceNetworkVpcAssociation struct {
DNSOptions *DNSOptions
CreatedAt time.Time
LastUpdatedAt time.Time
ARN string
ID string
VpcID string
ServiceNetworkARN string
ServiceNetworkID string
ServiceNetworkName string
Status string
CreatedBy string
SecurityGroupIDs []string
PrivateDNSEnabled bool
}
ServiceNetworkVpcAssociation is a VPC-to-service-network association.
type ServiceNetworkVpcAssociationSummary ¶
type ServiceNetworkVpcAssociationSummary struct {
DNSOptions *DNSOptions
CreatedAt time.Time
ARN string
ID string
VpcID string
ServiceNetworkARN string
ServiceNetworkID string
ServiceNetworkName string
Status string
PrivateDNSEnabled bool
}
ServiceNetworkVpcAssociationSummary is a summary for list responses.
type ServiceNetworkVpcEndpointAssociationSummary ¶ added in v1.3.1
type ServiceNetworkVpcEndpointAssociationSummary struct {
CreatedAt time.Time
ID string
ServiceNetworkARN string
ServiceNetworkID string
VpcEndpointID string
VpcID string
VpcEndpointOwner string
}
ServiceNetworkVpcEndpointAssociationSummary is a summary for list responses. Same structural note as ResourceEndpointAssociationSummary: populated from EC2 VPC endpoints of type ServiceNetwork, which this backend doesn't model.
type ServiceSummary ¶
type ServiceSummary struct {
CreatedAt time.Time
LastUpdatedAt time.Time
ARN string
ID string
Name string
CustomDomainName string
DNSName string
HostedZoneID string
Status string
}
ServiceSummary is a service entry for list responses.
type StorageBackend ¶
type StorageBackend interface {
CreateService(
ctx context.Context,
name, authType, certificateArn, customDomainName string,
tags map[string]string,
) (*Service, error)
GetService(serviceID string) (*Service, error)
UpdateService(serviceID, authType, certificateArn string) (*Service, error)
DeleteService(serviceID string) (*Service, error)
ListServices(ctx context.Context, maxResults int32, nextToken string) ([]*ServiceSummary, string, error)
CreateServiceNetwork(ctx context.Context, name, authType string, tags map[string]string) (*ServiceNetwork, error)
GetServiceNetwork(snID string) (*ServiceNetwork, error)
UpdateServiceNetwork(snID, authType string) (*ServiceNetwork, error)
DeleteServiceNetwork(snID string) error
ListServiceNetworks(
ctx context.Context,
maxResults int32,
nextToken string,
) ([]*ServiceNetworkSummary, string, error)
CreateServiceNetworkServiceAssociation(
ctx context.Context,
serviceNetworkID, serviceID string,
tags map[string]string,
) (*ServiceNetworkServiceAssociation, error)
GetServiceNetworkServiceAssociation(snsaID string) (*ServiceNetworkServiceAssociation, error)
DeleteServiceNetworkServiceAssociation(snsaID string) error
ListServiceNetworkServiceAssociations(
ctx context.Context,
serviceNetworkID, serviceID string,
maxResults int32,
nextToken string,
) ([]*ServiceNetworkServiceAssociationSummary, string, error)
CreateServiceNetworkVpcAssociation(
ctx context.Context,
serviceNetworkID, vpcID string,
securityGroupIDs []string,
privateDNSEnabled bool,
dnsOptions *DNSOptions,
tags map[string]string,
) (*ServiceNetworkVpcAssociation, error)
GetServiceNetworkVpcAssociation(snvaID string) (*ServiceNetworkVpcAssociation, error)
UpdateServiceNetworkVpcAssociation(
snvaID string,
securityGroupIDs []string,
) (*ServiceNetworkVpcAssociation, error)
DeleteServiceNetworkVpcAssociation(snvaID string) error
ListServiceNetworkVpcAssociations(
ctx context.Context,
serviceNetworkID, vpcID string,
maxResults int32,
nextToken string,
) ([]*ServiceNetworkVpcAssociationSummary, string, error)
CreateListener(
serviceID, name, protocol string,
port int32,
defaultAction *RuleAction,
tags map[string]string,
) (*Listener, error)
GetListener(serviceID, listenerID string) (*Listener, error)
UpdateListener(serviceID, listenerID string, defaultAction *RuleAction) (*Listener, error)
DeleteListener(serviceID, listenerID string) error
ListListeners(
serviceID string,
maxResults int32,
nextToken string,
) ([]*ListenerSummary, string, error)
CreateRule(
serviceID, listenerID, name string,
priority int32,
action *RuleAction,
match *RuleMatch,
tags map[string]string,
) (*Rule, error)
GetRule(serviceID, listenerID, ruleID string) (*Rule, error)
UpdateRule(
serviceID, listenerID, ruleID string,
priority int32,
action *RuleAction,
match *RuleMatch,
) (*Rule, error)
DeleteRule(serviceID, listenerID, ruleID string) error
ListRules(
serviceID, listenerID string,
maxResults int32,
nextToken string,
) ([]*RuleSummary, string, error)
BatchUpdateRule(
serviceID, listenerID string,
updates []*RuleUpdate,
) ([]*RuleUpdateSuccess, []*RuleUpdateFailure, error)
CreateTargetGroup(
ctx context.Context,
name, tgType string,
config *TargetGroupConfig,
tags map[string]string,
) (*TargetGroup, error)
GetTargetGroup(tgID string) (*TargetGroup, error)
UpdateTargetGroup(tgID string, healthCheck *HealthCheckConfig) (*TargetGroup, error)
DeleteTargetGroup(tgID string) error
ListTargetGroups(
ctx context.Context,
tgType, serviceArn string,
maxResults int32,
nextToken string,
) ([]*TargetGroupSummary, string, error)
RegisterTargets(tgID string, targets []*Target) ([]*TargetFailure, error)
DeregisterTargets(tgID string, targets []*Target) ([]*TargetFailure, error)
ListTargets(
ctx context.Context,
tgID string,
filters []Target,
maxResults int32,
nextToken string,
) ([]*TargetSummary, string, error)
CreateAccessLogSubscription(
ctx context.Context,
resourceID, destinationArn, logType string,
tags map[string]string,
) (*AccessLogSubscription, error)
GetAccessLogSubscription(alsID string) (*AccessLogSubscription, error)
UpdateAccessLogSubscription(alsID, destinationArn string) (*AccessLogSubscription, error)
DeleteAccessLogSubscription(alsID string) error
ListAccessLogSubscriptions(
ctx context.Context,
resourceID string,
maxResults int32,
nextToken string,
) ([]*AccessLogSubscriptionSummary, string, error)
CreateResourceGateway(
ctx context.Context,
name, vpcID, ipAddressType, resourceConfigDNSResolution string,
ipv4AddressesPerENI int32,
securityGroupIDs, subnetIDs []string,
tags map[string]string,
) (*ResourceGateway, error)
GetResourceGateway(id string) (*ResourceGateway, error)
UpdateResourceGateway(id string, securityGroupIDs []string) (*ResourceGateway, error)
DeleteResourceGateway(id string) (*ResourceGateway, error)
ListResourceGateways(
ctx context.Context,
maxResults int32,
nextToken string,
) ([]*ResourceGatewaySummary, string, error)
CreateResourceConfiguration(
ctx context.Context,
name, resourceType, protocol, resourceGatewayIdentifier, resourceConfigurationGroupIdentifier string,
allowAssociationToShareableServiceNetwork bool,
portRanges []string,
definition *ResourceConfigurationDefinition,
customDomainName, domainVerificationID, groupDomain string,
tags map[string]string,
) (*ResourceConfiguration, error)
GetResourceConfiguration(id string) (*ResourceConfiguration, error)
UpdateResourceConfiguration(
id string,
allowAssociationToShareableServiceNetwork *bool,
portRanges []string,
definition *ResourceConfigurationDefinition,
) (*ResourceConfiguration, error)
DeleteResourceConfiguration(id string) error
ListResourceConfigurations(
ctx context.Context,
resourceGatewayIdentifier, resourceConfigurationGroupIdentifier string,
maxResults int32,
nextToken string,
) ([]*ResourceConfigurationSummary, string, error)
CreateServiceNetworkResourceAssociation(
ctx context.Context,
serviceNetworkIdentifier, resourceConfigurationIdentifier string,
privateDNSEnabled bool,
tags map[string]string,
) (*ServiceNetworkResourceAssociation, error)
GetServiceNetworkResourceAssociation(id string) (*ServiceNetworkResourceAssociation, error)
DeleteServiceNetworkResourceAssociation(id string) (*ServiceNetworkResourceAssociation, error)
ListServiceNetworkResourceAssociations(
ctx context.Context,
serviceNetworkIdentifier, resourceConfigurationIdentifier string,
maxResults int32,
nextToken string,
) ([]*ServiceNetworkResourceAssociationSummary, string, error)
StartDomainVerification(
ctx context.Context,
domainName string,
tags map[string]string,
) (*DomainVerification, error)
GetDomainVerification(id string) (*DomainVerification, error)
DeleteDomainVerification(id string) error
ListDomainVerifications(
ctx context.Context,
maxResults int32,
nextToken string,
) ([]*DomainVerificationSummary, string, error)
ListResourceEndpointAssociations(
ctx context.Context,
maxResults int32,
nextToken string,
) ([]*ResourceEndpointAssociationSummary, string, error)
DeleteResourceEndpointAssociation(id string) error
ListServiceNetworkVpcEndpointAssociations(
ctx context.Context,
serviceNetworkIdentifier string,
maxResults int32,
nextToken string,
) ([]*ServiceNetworkVpcEndpointAssociationSummary, string, error)
PutAuthPolicy(resourceID, policy string) (*AuthPolicy, error)
GetAuthPolicy(resourceID string) (*AuthPolicy, error)
DeleteAuthPolicy(resourceID string) error
PutResourcePolicy(resourceArn, policy string) error
GetResourcePolicy(resourceArn string) (string, error)
DeleteResourcePolicy(resourceArn string) error
TagResource(resourceArn string, tags map[string]string) error
UntagResource(resourceArn string, keys []string) error
ListTagsForResource(resourceArn string) (map[string]string, error)
AccountID() string
Region() string
Reset()
Snapshot(ctx context.Context) []byte
Restore(ctx context.Context, data []byte) error
}
StorageBackend is the interface for VPC Lattice storage operations.
type TaggedEntry ¶ added in v1.3.1
TaggedEntry pairs a resource ARN with its tags.
type TargetFailure ¶
TargetFailure is a target registration/deregistration failure.
type TargetGroup ¶
type TargetGroup struct {
CreatedAt time.Time
LastUpdatedAt time.Time
ARN string
ID string
Name string
Type string
Status string
Config *TargetGroupConfig
ServiceARNs []string
}
TargetGroup represents a VPC Lattice target group.
type TargetGroupConfig ¶
type TargetGroupConfig struct {
HealthCheck *HealthCheckConfig `json:"healthCheck,omitempty"`
Protocol string `json:"protocol,omitempty"`
ProtocolVersion string `json:"protocolVersion,omitempty"`
VpcID string `json:"vpcId,omitempty"`
IPAddressType string `json:"ipAddressType,omitempty"`
LambdaEventStructureVersion string `json:"lambdaEventStructureVersion,omitempty"`
Port int32 `json:"port,omitempty"`
}
TargetGroupConfig is the configuration for a target group.
type TargetGroupSummary ¶
type TargetGroupSummary struct {
CreatedAt time.Time
LastUpdatedAt time.Time
ARN string
ID string
Name string
Type string
Status string
Protocol string
VpcID string
IPAddressType string
LambdaEventStructureVersion string
ServiceARNs []string
Port int32
}
TargetGroupSummary is a target group entry for list responses.
type TargetSummary ¶
TargetSummary is a target entry for list responses.
type WeightedTargetGroup ¶
type WeightedTargetGroup struct {
TargetGroupID string `json:"targetGroupId"`
Weight int32 `json:"weight"`
}
WeightedTargetGroup is a weighted target group for forward actions.
Source Files
¶
- access_log_subscriptions.go
- auth_policy.go
- domain_verifications.go
- errors.go
- handler.go
- handler_access_log_subscriptions.go
- handler_auth_policy.go
- handler_domain_verifications.go
- handler_listeners.go
- handler_resource_configurations.go
- handler_resource_gateways.go
- handler_resource_policy.go
- handler_rules.go
- handler_service_network_associations.go
- handler_service_network_resource_associations.go
- handler_service_networks.go
- handler_services.go
- handler_tags.go
- handler_target_groups.go
- handler_targets.go
- interfaces.go
- listeners.go
- models.go
- persistence.go
- provider.go
- resource_configurations.go
- resource_gateways.go
- resource_policy.go
- rules.go
- service_network_associations.go
- service_network_resource_associations.go
- service_networks.go
- services.go
- store.go
- store_setup.go
- tags.go
- target_groups.go
- targets.go