localstack-core 4.6.1.dev30__py3-none-any.whl → 4.6.1.dev32__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (31) hide show
  1. localstack/services/lambda_/event_source_mapping/esm_worker_factory.py +5 -5
  2. localstack/services/lambda_/invocation/assignment.py +1 -23
  3. localstack/services/lambda_/invocation/counting_service.py +0 -21
  4. localstack/services/lambda_/invocation/docker_runtime_executor.py +5 -4
  5. localstack/services/lambda_/invocation/execution_environment.py +1 -18
  6. localstack/services/lambda_/invocation/executor_endpoint.py +4 -4
  7. localstack/services/lambda_/invocation/lambda_models.py +1 -0
  8. localstack/services/lambda_/invocation/lambda_service.py +3 -0
  9. localstack/services/lambda_/invocation/version_manager.py +25 -0
  10. localstack/services/lambda_/lambda_debug_mode/ldm.py +375 -0
  11. localstack/services/lambda_/lambda_debug_mode/ldm_config_file.py +178 -0
  12. localstack/services/lambda_/lambda_debug_mode/ldm_types.py +11 -0
  13. localstack/services/lambda_/lambda_debug_mode/ldm_utils.py +43 -0
  14. localstack/services/lambda_/provider.py +14 -14
  15. localstack/utils/aws/client_types.py +1 -0
  16. localstack/version.py +2 -2
  17. {localstack_core-4.6.1.dev30.dist-info → localstack_core-4.6.1.dev32.dist-info}/METADATA +1 -1
  18. {localstack_core-4.6.1.dev30.dist-info → localstack_core-4.6.1.dev32.dist-info}/RECORD +27 -26
  19. localstack_core-4.6.1.dev32.dist-info/plux.json +1 -0
  20. localstack/utils/lambda_debug_mode/lambda_debug_mode.py +0 -41
  21. localstack/utils/lambda_debug_mode/lambda_debug_mode_config.py +0 -230
  22. localstack/utils/lambda_debug_mode/lambda_debug_mode_session.py +0 -175
  23. localstack_core-4.6.1.dev30.dist-info/plux.json +0 -1
  24. /localstack/{utils → services/lambda_}/lambda_debug_mode/__init__.py +0 -0
  25. {localstack_core-4.6.1.dev30.data → localstack_core-4.6.1.dev32.data}/scripts/localstack +0 -0
  26. {localstack_core-4.6.1.dev30.data → localstack_core-4.6.1.dev32.data}/scripts/localstack-supervisor +0 -0
  27. {localstack_core-4.6.1.dev30.data → localstack_core-4.6.1.dev32.data}/scripts/localstack.bat +0 -0
  28. {localstack_core-4.6.1.dev30.dist-info → localstack_core-4.6.1.dev32.dist-info}/WHEEL +0 -0
  29. {localstack_core-4.6.1.dev30.dist-info → localstack_core-4.6.1.dev32.dist-info}/entry_points.txt +0 -0
  30. {localstack_core-4.6.1.dev30.dist-info → localstack_core-4.6.1.dev32.dist-info}/licenses/LICENSE.txt +0 -0
  31. {localstack_core-4.6.1.dev30.dist-info → localstack_core-4.6.1.dev32.dist-info}/top_level.txt +0 -0
@@ -1,230 +0,0 @@
1
- from __future__ import annotations
2
-
3
- import logging
4
- from typing import Optional
5
-
6
- import yaml
7
- from pydantic import BaseModel, Field, ValidationError
8
- from yaml import Loader, MappingNode, MarkedYAMLError, SafeLoader
9
-
10
- from localstack.aws.api.lambda_ import Arn
11
-
12
- LOG = logging.getLogger(__name__)
13
-
14
-
15
- class LambdaDebugConfig(BaseModel):
16
- debug_port: Optional[int] = Field(None, alias="debug-port")
17
- enforce_timeouts: bool = Field(False, alias="enforce-timeouts")
18
-
19
-
20
- class LambdaDebugModeConfig(BaseModel):
21
- # Bindings of Lambda function Arn and the respective debugging configuration.
22
- functions: dict[Arn, LambdaDebugConfig]
23
-
24
-
25
- class LambdaDebugModeConfigException(Exception): ...
26
-
27
-
28
- class UnknownLambdaArnFormat(LambdaDebugModeConfigException):
29
- unknown_lambda_arn: str
30
-
31
- def __init__(self, unknown_lambda_arn: str):
32
- self.unknown_lambda_arn = unknown_lambda_arn
33
-
34
- def __str__(self):
35
- return f"UnknownLambdaArnFormat: '{self.unknown_lambda_arn}'"
36
-
37
-
38
- class PortAlreadyInUse(LambdaDebugModeConfigException):
39
- port_number: int
40
-
41
- def __init__(self, port_number: int):
42
- self.port_number = port_number
43
-
44
- def __str__(self):
45
- return f"PortAlreadyInUse: '{self.port_number}'"
46
-
47
-
48
- class DuplicateLambdaDebugConfig(LambdaDebugModeConfigException):
49
- lambda_arn_debug_config_first: str
50
- lambda_arn_debug_config_second: str
51
-
52
- def __init__(self, lambda_arn_debug_config_first: str, lambda_arn_debug_config_second: str):
53
- self.lambda_arn_debug_config_first = lambda_arn_debug_config_first
54
- self.lambda_arn_debug_config_second = lambda_arn_debug_config_second
55
-
56
- def __str__(self):
57
- return (
58
- f"DuplicateLambdaDebugConfig: Lambda debug configuration in '{self.lambda_arn_debug_config_first}' "
59
- f"is redefined in '{self.lambda_arn_debug_config_second}'"
60
- )
61
-
62
-
63
- class _LambdaDebugModeConfigPostProcessingState:
64
- ports_used: set[int]
65
-
66
- def __init__(self):
67
- self.ports_used = set()
68
-
69
-
70
- class _SafeLoaderWithDuplicateCheck(SafeLoader):
71
- def __init__(self, stream):
72
- super().__init__(stream)
73
- self.add_constructor(
74
- yaml.resolver.BaseResolver.DEFAULT_MAPPING_TAG,
75
- self._construct_mappings_with_duplicate_check,
76
- )
77
-
78
- @staticmethod
79
- def _construct_mappings_with_duplicate_check(loader: Loader, node: MappingNode, deep=False):
80
- # Constructs yaml bindings, whilst checking for duplicate mapping key definitions, raising a
81
- # MarkedYAMLError when one is found.
82
- mapping = dict()
83
- for key_node, value_node in node.value:
84
- key = loader.construct_object(key_node, deep=deep)
85
- if key in mapping:
86
- # Create a MarkedYAMLError to indicate the duplicate key issue
87
- raise MarkedYAMLError(
88
- context="while constructing a mapping",
89
- context_mark=node.start_mark,
90
- problem=f"found duplicate key: {key}",
91
- problem_mark=key_node.start_mark,
92
- )
93
- value = loader.construct_object(value_node, deep=deep)
94
- mapping[key] = value
95
- return mapping
96
-
97
-
98
- def from_yaml_string(yaml_string: str) -> Optional[LambdaDebugModeConfig]:
99
- try:
100
- data = yaml.load(yaml_string, _SafeLoaderWithDuplicateCheck)
101
- except yaml.YAMLError as yaml_error:
102
- LOG.error(
103
- "Could not parse yaml lambda debug mode configuration file due to: %s",
104
- yaml_error,
105
- )
106
- data = None
107
- if not data:
108
- return None
109
- config = LambdaDebugModeConfig(**data)
110
- return config
111
-
112
-
113
- def post_process_lambda_debug_mode_config(config: LambdaDebugModeConfig) -> None:
114
- _post_process_lambda_debug_mode_config(
115
- post_processing_state=_LambdaDebugModeConfigPostProcessingState(), config=config
116
- )
117
-
118
-
119
- def _post_process_lambda_debug_mode_config(
120
- post_processing_state: _LambdaDebugModeConfigPostProcessingState, config: LambdaDebugModeConfig
121
- ):
122
- config_functions = config.functions
123
- lambda_arns = list(config_functions.keys())
124
- for lambda_arn in lambda_arns:
125
- qualified_lambda_arn = _to_qualified_lambda_function_arn(lambda_arn)
126
- if lambda_arn != qualified_lambda_arn:
127
- if qualified_lambda_arn in config_functions:
128
- raise DuplicateLambdaDebugConfig(
129
- lambda_arn_debug_config_first=lambda_arn,
130
- lambda_arn_debug_config_second=qualified_lambda_arn,
131
- )
132
- config_functions[qualified_lambda_arn] = config_functions.pop(lambda_arn)
133
-
134
- for lambda_arn, lambda_debug_config in config_functions.items():
135
- _post_process_lambda_debug_config(
136
- post_processing_state=post_processing_state, lambda_debug_config=lambda_debug_config
137
- )
138
-
139
-
140
- def _to_qualified_lambda_function_arn(lambda_arn: Arn) -> Arn:
141
- """
142
- Returns the $LATEST qualified version of a structurally unqualified version of a lambda Arn iff this
143
- is detected to be structurally unqualified. Otherwise, it returns the given string.
144
- Example:
145
- - arn:aws:lambda:eu-central-1:000000000000:function:functionname:$LATEST ->
146
- unchanged
147
-
148
- - arn:aws:lambda:eu-central-1:000000000000:function:functionname ->
149
- arn:aws:lambda:eu-central-1:000000000000:function:functionname:$LATEST
150
-
151
- - arn:aws:lambda:eu-central-1:000000000000:function:functionname: ->
152
- exception UnknownLambdaArnFormat
153
-
154
- - arn:aws:lambda:eu-central-1:000000000000:function ->
155
- exception UnknownLambdaArnFormat
156
- """
157
-
158
- if not lambda_arn:
159
- return lambda_arn
160
- lambda_arn_parts = lambda_arn.split(":")
161
- lambda_arn_parts_len = len(lambda_arn_parts)
162
-
163
- # The arn is qualified and with a non-empy qualifier.
164
- is_qualified = lambda_arn_parts_len == 8
165
- if is_qualified and lambda_arn_parts[-1]:
166
- return lambda_arn
167
-
168
- # Unknown lambda arn format.
169
- is_unqualified = lambda_arn_parts_len == 7
170
- if not is_unqualified:
171
- raise UnknownLambdaArnFormat(unknown_lambda_arn=lambda_arn)
172
-
173
- # Structure-wise, the arn is missing the qualifier.
174
- qualifier = "$LATEST"
175
- arn_tail = f":{qualifier}" if is_unqualified else qualifier
176
- qualified_lambda_arn = lambda_arn + arn_tail
177
- return qualified_lambda_arn
178
-
179
-
180
- def _post_process_lambda_debug_config(
181
- post_processing_state: _LambdaDebugModeConfigPostProcessingState,
182
- lambda_debug_config: LambdaDebugConfig,
183
- ) -> None:
184
- debug_port: Optional[int] = lambda_debug_config.debug_port
185
- if debug_port is None:
186
- return
187
- if debug_port in post_processing_state.ports_used:
188
- raise PortAlreadyInUse(port_number=debug_port)
189
- post_processing_state.ports_used.add(debug_port)
190
-
191
-
192
- def load_lambda_debug_mode_config(yaml_string: str) -> Optional[LambdaDebugModeConfig]:
193
- # Attempt to parse the yaml string.
194
- try:
195
- yaml_data = yaml.load(yaml_string, _SafeLoaderWithDuplicateCheck)
196
- except yaml.YAMLError as yaml_error:
197
- LOG.error(
198
- "Could not parse yaml lambda debug mode configuration file due to: %s",
199
- yaml_error,
200
- )
201
- yaml_data = None
202
- if not yaml_data:
203
- return None
204
-
205
- # Attempt to build the LambdaDebugModeConfig object from the yaml object.
206
- try:
207
- config = LambdaDebugModeConfig(**yaml_data)
208
- except ValidationError as validation_error:
209
- validation_errors = validation_error.errors() or list()
210
- error_messages = [
211
- f"When parsing '{err.get('loc', '')}': {err.get('msg', str(err))}"
212
- for err in validation_errors
213
- ]
214
- LOG.error(
215
- "Unable to parse lambda debug mode configuration file due to errors: %s",
216
- error_messages,
217
- )
218
- return None
219
-
220
- # Attempt to post_process the configuration.
221
- try:
222
- post_process_lambda_debug_mode_config(config)
223
- except LambdaDebugModeConfigException as lambda_debug_mode_error:
224
- LOG.error(
225
- "Invalid lambda debug mode configuration due to: %s",
226
- lambda_debug_mode_error,
227
- )
228
- config = None
229
-
230
- return config
@@ -1,175 +0,0 @@
1
- from __future__ import annotations
2
-
3
- import logging
4
- import os
5
- import time
6
- from threading import Event, Thread
7
- from typing import Optional
8
-
9
- from localstack.aws.api.lambda_ import Arn
10
- from localstack.config import LAMBDA_DEBUG_MODE, LAMBDA_DEBUG_MODE_CONFIG_PATH
11
- from localstack.utils.lambda_debug_mode.lambda_debug_mode_config import (
12
- LambdaDebugConfig,
13
- LambdaDebugModeConfig,
14
- load_lambda_debug_mode_config,
15
- )
16
- from localstack.utils.objects import singleton_factory
17
-
18
- LOG = logging.getLogger(__name__)
19
-
20
-
21
- class LambdaDebugModeSession:
22
- _is_lambda_debug_mode: bool
23
-
24
- _configuration_file_path: Optional[str]
25
- _watch_thread: Optional[Thread]
26
- _initialised_event: Optional[Event]
27
- _stop_event: Optional[Event]
28
- _config: Optional[LambdaDebugModeConfig]
29
-
30
- def __init__(self):
31
- self._is_lambda_debug_mode = bool(LAMBDA_DEBUG_MODE)
32
-
33
- # Disabled Lambda Debug Mode state initialisation.
34
- self._configuration_file_path = None
35
- self._watch_thread = None
36
- self._initialised_event = None
37
- self._stop_event = None
38
- self._config = None
39
-
40
- # Lambda Debug Mode is not enabled: leave as disabled state and return.
41
- if not self._is_lambda_debug_mode:
42
- return
43
-
44
- # Lambda Debug Mode is enabled.
45
- # Instantiate the configuration requirements if a configuration file is given.
46
- self._configuration_file_path = LAMBDA_DEBUG_MODE_CONFIG_PATH
47
- if not self._configuration_file_path:
48
- return
49
-
50
- # A configuration file path is given: initialised the resources to load and watch the file.
51
-
52
- # Signal and block on first loading to ensure this is enforced from the very first
53
- # invocation, as this module is not loaded at startup. The LambdaDebugModeConfigWatch
54
- # thread will then take care of updating the configuration periodically and asynchronously.
55
- # This may somewhat slow down the first upstream thread loading this module, but not
56
- # future calls. On the other hand, avoiding this mechanism means that first Lambda calls
57
- # occur with no Debug configuration.
58
- self._initialised_event = Event()
59
-
60
- # Signals when a shutdown signal from the application is registered.
61
- self._stop_event = Event()
62
-
63
- self._watch_thread = Thread(
64
- target=self._watch_logic, args=(), daemon=True, name="LambdaDebugModeConfigWatch"
65
- )
66
- self._watch_thread.start()
67
-
68
- @staticmethod
69
- @singleton_factory
70
- def get() -> LambdaDebugModeSession:
71
- """Returns a singleton instance of the Lambda Debug Mode session."""
72
- return LambdaDebugModeSession()
73
-
74
- def ensure_running(self) -> None:
75
- # Nothing to start.
76
- if self._watch_thread is None or self._watch_thread.is_alive():
77
- return
78
- try:
79
- self._watch_thread.start()
80
- except Exception as exception:
81
- exception_str = str(exception)
82
- # The thread was already restarted by another process.
83
- if (
84
- isinstance(exception, RuntimeError)
85
- and exception_str
86
- and "threads can only be started once" in exception_str
87
- ):
88
- return
89
- LOG.error(
90
- "Lambda Debug Mode could not restart the "
91
- "hot reloading of the configuration file, '%s'",
92
- exception_str,
93
- )
94
-
95
- def signal_stop(self) -> None:
96
- stop_event = self._stop_event
97
- if stop_event is not None:
98
- stop_event.set()
99
-
100
- def _load_lambda_debug_mode_config(self):
101
- yaml_configuration_string = None
102
- try:
103
- with open(self._configuration_file_path, "r") as df:
104
- yaml_configuration_string = df.read()
105
- except FileNotFoundError:
106
- LOG.error(
107
- "Error: The file lambda debug config file '%s' was not found.",
108
- self._configuration_file_path,
109
- )
110
- except IsADirectoryError:
111
- LOG.error(
112
- "Error: Expected a lambda debug config file but found a directory at '%s'.",
113
- self._configuration_file_path,
114
- )
115
- except PermissionError:
116
- LOG.error(
117
- "Error: Permission denied while trying to read the lambda debug config file '%s'.",
118
- self._configuration_file_path,
119
- )
120
- except Exception as ex:
121
- LOG.error(
122
- "Error: An unexpected error occurred while reading lambda debug config '%s': '%s'",
123
- self._configuration_file_path,
124
- ex,
125
- )
126
- if not yaml_configuration_string:
127
- return None
128
-
129
- self._config = load_lambda_debug_mode_config(yaml_configuration_string)
130
- if self._config is not None:
131
- LOG.info("Lambda Debug Mode is now enforcing the latest configuration.")
132
- else:
133
- LOG.warning(
134
- "Lambda Debug Mode could not load the latest configuration due to an error, "
135
- "check logs for more details."
136
- )
137
-
138
- def _config_file_epoch_last_modified_or_now(self) -> int:
139
- try:
140
- modified_time = os.path.getmtime(self._configuration_file_path)
141
- return int(modified_time)
142
- except Exception as e:
143
- LOG.warning("Lambda Debug Mode could not access the configuration file: %s", e)
144
- epoch_now = int(time.time())
145
- return epoch_now
146
-
147
- def _watch_logic(self) -> None:
148
- # TODO: consider relying on system calls (watchdog lib for cross-platform support)
149
- # instead of monitoring last modified dates.
150
- # Run the first load and signal as initialised.
151
- epoch_last_loaded: int = self._config_file_epoch_last_modified_or_now()
152
- self._load_lambda_debug_mode_config()
153
- self._initialised_event.set()
154
-
155
- # Monitor for file changes whilst the application is running.
156
- while not self._stop_event.is_set():
157
- time.sleep(1)
158
- epoch_last_modified = self._config_file_epoch_last_modified_or_now()
159
- if epoch_last_modified > epoch_last_loaded:
160
- epoch_last_loaded = epoch_last_modified
161
- self._load_lambda_debug_mode_config()
162
-
163
- def _get_initialised_config(self) -> Optional[LambdaDebugModeConfig]:
164
- # Check the session is not initialising, and if so then wait for initialisation to finish.
165
- # Note: the initialisation event is otherwise left set since after first initialisation has terminated.
166
- if self._initialised_event is not None:
167
- self._initialised_event.wait()
168
- return self._config
169
-
170
- def is_lambda_debug_mode(self) -> bool:
171
- return self._is_lambda_debug_mode
172
-
173
- def debug_config_for(self, lambda_arn: Arn) -> Optional[LambdaDebugConfig]:
174
- config = self._get_initialised_config()
175
- return config.functions.get(lambda_arn) if config else None
@@ -1 +0,0 @@
1
- {"localstack.cloudformation.resource_providers": ["AWS::StepFunctions::Activity=localstack.services.stepfunctions.resource_providers.aws_stepfunctions_activity_plugin:StepFunctionsActivityProviderPlugin", "AWS::CloudFormation::WaitConditionHandle=localstack.services.cloudformation.resource_providers.aws_cloudformation_waitconditionhandle_plugin:CloudFormationWaitConditionHandleProviderPlugin", "AWS::SQS::QueuePolicy=localstack.services.sqs.resource_providers.aws_sqs_queuepolicy_plugin:SQSQueuePolicyProviderPlugin", "AWS::IAM::Role=localstack.services.iam.resource_providers.aws_iam_role_plugin:IAMRoleProviderPlugin", "AWS::ApiGateway::UsagePlan=localstack.services.apigateway.resource_providers.aws_apigateway_usageplan_plugin:ApiGatewayUsagePlanProviderPlugin", "AWS::OpenSearchService::Domain=localstack.services.opensearch.resource_providers.aws_opensearchservice_domain_plugin:OpenSearchServiceDomainProviderPlugin", "AWS::IAM::ServiceLinkedRole=localstack.services.iam.resource_providers.aws_iam_servicelinkedrole_plugin:IAMServiceLinkedRoleProviderPlugin", "AWS::ApiGateway::Deployment=localstack.services.apigateway.resource_providers.aws_apigateway_deployment_plugin:ApiGatewayDeploymentProviderPlugin", "AWS::CloudWatch::Alarm=localstack.services.cloudwatch.resource_providers.aws_cloudwatch_alarm_plugin:CloudWatchAlarmProviderPlugin", "AWS::EC2::TransitGateway=localstack.services.ec2.resource_providers.aws_ec2_transitgateway_plugin:EC2TransitGatewayProviderPlugin", "AWS::ApiGateway::Resource=localstack.services.apigateway.resource_providers.aws_apigateway_resource_plugin:ApiGatewayResourceProviderPlugin", "AWS::Events::EventBus=localstack.services.events.resource_providers.aws_events_eventbus_plugin:EventsEventBusProviderPlugin", "AWS::SNS::TopicPolicy=localstack.services.sns.resource_providers.aws_sns_topicpolicy_plugin:SNSTopicPolicyProviderPlugin", "AWS::Scheduler::ScheduleGroup=localstack.services.scheduler.resource_providers.aws_scheduler_schedulegroup_plugin:SchedulerScheduleGroupProviderPlugin", "AWS::EC2::VPCEndpoint=localstack.services.ec2.resource_providers.aws_ec2_vpcendpoint_plugin:EC2VPCEndpointProviderPlugin", "AWS::KMS::Alias=localstack.services.kms.resource_providers.aws_kms_alias_plugin:KMSAliasProviderPlugin", "AWS::SecretsManager::Secret=localstack.services.secretsmanager.resource_providers.aws_secretsmanager_secret_plugin:SecretsManagerSecretProviderPlugin", "AWS::Logs::LogGroup=localstack.services.logs.resource_providers.aws_logs_loggroup_plugin:LogsLogGroupProviderPlugin", "AWS::SSM::MaintenanceWindowTarget=localstack.services.ssm.resource_providers.aws_ssm_maintenancewindowtarget_plugin:SSMMaintenanceWindowTargetProviderPlugin", "AWS::Kinesis::StreamConsumer=localstack.services.kinesis.resource_providers.aws_kinesis_streamconsumer_plugin:KinesisStreamConsumerProviderPlugin", "AWS::Events::EventBusPolicy=localstack.services.events.resource_providers.aws_events_eventbuspolicy_plugin:EventsEventBusPolicyProviderPlugin", "AWS::EC2::Instance=localstack.services.ec2.resource_providers.aws_ec2_instance_plugin:EC2InstanceProviderPlugin", "AWS::IAM::Policy=localstack.services.iam.resource_providers.aws_iam_policy_plugin:IAMPolicyProviderPlugin", "AWS::EC2::Subnet=localstack.services.ec2.resource_providers.aws_ec2_subnet_plugin:EC2SubnetProviderPlugin", "AWS::Lambda::EventSourceMapping=localstack.services.lambda_.resource_providers.aws_lambda_eventsourcemapping_plugin:LambdaEventSourceMappingProviderPlugin", "AWS::Lambda::LayerVersion=localstack.services.lambda_.resource_providers.aws_lambda_layerversion_plugin:LambdaLayerVersionProviderPlugin", "AWS::ApiGateway::Method=localstack.services.apigateway.resource_providers.aws_apigateway_method_plugin:ApiGatewayMethodProviderPlugin", "AWS::KMS::Key=localstack.services.kms.resource_providers.aws_kms_key_plugin:KMSKeyProviderPlugin", "AWS::EC2::VPCGatewayAttachment=localstack.services.ec2.resource_providers.aws_ec2_vpcgatewayattachment_plugin:EC2VPCGatewayAttachmentProviderPlugin", "AWS::SSM::MaintenanceWindow=localstack.services.ssm.resource_providers.aws_ssm_maintenancewindow_plugin:SSMMaintenanceWindowProviderPlugin", "AWS::Route53::HealthCheck=localstack.services.route53.resource_providers.aws_route53_healthcheck_plugin:Route53HealthCheckProviderPlugin", "AWS::Lambda::LayerVersionPermission=localstack.services.lambda_.resource_providers.aws_lambda_layerversionpermission_plugin:LambdaLayerVersionPermissionProviderPlugin", "AWS::ApiGateway::Account=localstack.services.apigateway.resource_providers.aws_apigateway_account_plugin:ApiGatewayAccountProviderPlugin", "AWS::ApiGateway::BasePathMapping=localstack.services.apigateway.resource_providers.aws_apigateway_basepathmapping_plugin:ApiGatewayBasePathMappingProviderPlugin", "AWS::Events::Rule=localstack.services.events.resource_providers.aws_events_rule_plugin:EventsRuleProviderPlugin", "AWS::Lambda::Version=localstack.services.lambda_.resource_providers.aws_lambda_version_plugin:LambdaVersionProviderPlugin", "AWS::EC2::DHCPOptions=localstack.services.ec2.resource_providers.aws_ec2_dhcpoptions_plugin:EC2DHCPOptionsProviderPlugin", "AWS::IAM::AccessKey=localstack.services.iam.resource_providers.aws_iam_accesskey_plugin:IAMAccessKeyProviderPlugin", "AWS::ApiGateway::DomainName=localstack.services.apigateway.resource_providers.aws_apigateway_domainname_plugin:ApiGatewayDomainNameProviderPlugin", "AWS::DynamoDB::GlobalTable=localstack.services.dynamodb.resource_providers.aws_dynamodb_globaltable_plugin:DynamoDBGlobalTableProviderPlugin", "AWS::CertificateManager::Certificate=localstack.services.certificatemanager.resource_providers.aws_certificatemanager_certificate_plugin:CertificateManagerCertificateProviderPlugin", "AWS::StepFunctions::StateMachine=localstack.services.stepfunctions.resource_providers.aws_stepfunctions_statemachine_plugin:StepFunctionsStateMachineProviderPlugin", "AWS::Lambda::Permission=localstack.services.lambda_.resource_providers.aws_lambda_permission_plugin:LambdaPermissionProviderPlugin", "AWS::ApiGateway::RequestValidator=localstack.services.apigateway.resource_providers.aws_apigateway_requestvalidator_plugin:ApiGatewayRequestValidatorProviderPlugin", "AWS::CloudFormation::Stack=localstack.services.cloudformation.resource_providers.aws_cloudformation_stack_plugin:CloudFormationStackProviderPlugin", "AWS::Logs::LogStream=localstack.services.logs.resource_providers.aws_logs_logstream_plugin:LogsLogStreamProviderPlugin", "AWS::EC2::PrefixList=localstack.services.ec2.resource_providers.aws_ec2_prefixlist_plugin:EC2PrefixListProviderPlugin", "AWS::SNS::Subscription=localstack.services.sns.resource_providers.aws_sns_subscription_plugin:SNSSubscriptionProviderPlugin", "AWS::EC2::NatGateway=localstack.services.ec2.resource_providers.aws_ec2_natgateway_plugin:EC2NatGatewayProviderPlugin", "AWS::SQS::Queue=localstack.services.sqs.resource_providers.aws_sqs_queue_plugin:SQSQueueProviderPlugin", "AWS::ECR::Repository=localstack.services.ecr.resource_providers.aws_ecr_repository_plugin:ECRRepositoryProviderPlugin", "AWS::Lambda::Function=localstack.services.lambda_.resource_providers.aws_lambda_function_plugin:LambdaFunctionProviderPlugin", "AWS::CloudFormation::Macro=localstack.services.cloudformation.resource_providers.aws_cloudformation_macro_plugin:CloudFormationMacroProviderPlugin", "AWS::SSM::MaintenanceWindowTask=localstack.services.ssm.resource_providers.aws_ssm_maintenancewindowtask_plugin:SSMMaintenanceWindowTaskProviderPlugin", "AWS::EC2::NetworkAcl=localstack.services.ec2.resource_providers.aws_ec2_networkacl_plugin:EC2NetworkAclProviderPlugin", "AWS::KinesisFirehose::DeliveryStream=localstack.services.kinesisfirehose.resource_providers.aws_kinesisfirehose_deliverystream_plugin:KinesisFirehoseDeliveryStreamProviderPlugin", "AWS::SecretsManager::RotationSchedule=localstack.services.secretsmanager.resource_providers.aws_secretsmanager_rotationschedule_plugin:SecretsManagerRotationScheduleProviderPlugin", "AWS::EC2::VPC=localstack.services.ec2.resource_providers.aws_ec2_vpc_plugin:EC2VPCProviderPlugin", "AWS::CloudWatch::CompositeAlarm=localstack.services.cloudwatch.resource_providers.aws_cloudwatch_compositealarm_plugin:CloudWatchCompositeAlarmProviderPlugin", "AWS::ApiGateway::GatewayResponse=localstack.services.apigateway.resource_providers.aws_apigateway_gatewayresponse_plugin:ApiGatewayGatewayResponseProviderPlugin", "AWS::Scheduler::Schedule=localstack.services.scheduler.resource_providers.aws_scheduler_schedule_plugin:SchedulerScheduleProviderPlugin", "AWS::Logs::SubscriptionFilter=localstack.services.logs.resource_providers.aws_logs_subscriptionfilter_plugin:LogsSubscriptionFilterProviderPlugin", "AWS::Lambda::CodeSigningConfig=localstack.services.lambda_.resource_providers.aws_lambda_codesigningconfig_plugin:LambdaCodeSigningConfigProviderPlugin", "AWS::Lambda::Alias=localstack.services.lambda_.resource_providers.lambda_alias_plugin:LambdaAliasProviderPlugin", "AWS::S3::Bucket=localstack.services.s3.resource_providers.aws_s3_bucket_plugin:S3BucketProviderPlugin", "AWS::EC2::KeyPair=localstack.services.ec2.resource_providers.aws_ec2_keypair_plugin:EC2KeyPairProviderPlugin", "AWS::CDK::Metadata=localstack.services.cdk.resource_providers.cdk_metadata_plugin:LambdaAliasProviderPlugin", "AWS::DynamoDB::Table=localstack.services.dynamodb.resource_providers.aws_dynamodb_table_plugin:DynamoDBTableProviderPlugin", "AWS::ApiGateway::RestApi=localstack.services.apigateway.resource_providers.aws_apigateway_restapi_plugin:ApiGatewayRestApiProviderPlugin", "AWS::Events::Connection=localstack.services.events.resource_providers.aws_events_connection_plugin:EventsConnectionProviderPlugin", "AWS::ApiGateway::ApiKey=localstack.services.apigateway.resource_providers.aws_apigateway_apikey_plugin:ApiGatewayApiKeyProviderPlugin", "AWS::IAM::Group=localstack.services.iam.resource_providers.aws_iam_group_plugin:IAMGroupProviderPlugin", "AWS::Route53::RecordSet=localstack.services.route53.resource_providers.aws_route53_recordset_plugin:Route53RecordSetProviderPlugin", "AWS::S3::BucketPolicy=localstack.services.s3.resource_providers.aws_s3_bucketpolicy_plugin:S3BucketPolicyProviderPlugin", "AWS::IAM::ServerCertificate=localstack.services.iam.resource_providers.aws_iam_servercertificate_plugin:IAMServerCertificateProviderPlugin", "AWS::Kinesis::Stream=localstack.services.kinesis.resource_providers.aws_kinesis_stream_plugin:KinesisStreamProviderPlugin", "AWS::IAM::User=localstack.services.iam.resource_providers.aws_iam_user_plugin:IAMUserProviderPlugin", "AWS::CloudFormation::WaitCondition=localstack.services.cloudformation.resource_providers.aws_cloudformation_waitcondition_plugin:CloudFormationWaitConditionProviderPlugin", "AWS::ApiGateway::UsagePlanKey=localstack.services.apigateway.resource_providers.aws_apigateway_usageplankey_plugin:ApiGatewayUsagePlanKeyProviderPlugin", "AWS::EC2::SecurityGroup=localstack.services.ec2.resource_providers.aws_ec2_securitygroup_plugin:EC2SecurityGroupProviderPlugin", "AWS::Lambda::EventInvokeConfig=localstack.services.lambda_.resource_providers.aws_lambda_eventinvokeconfig_plugin:LambdaEventInvokeConfigProviderPlugin", "AWS::SecretsManager::ResourcePolicy=localstack.services.secretsmanager.resource_providers.aws_secretsmanager_resourcepolicy_plugin:SecretsManagerResourcePolicyProviderPlugin", "AWS::SSM::Parameter=localstack.services.ssm.resource_providers.aws_ssm_parameter_plugin:SSMParameterProviderPlugin", "AWS::SSM::PatchBaseline=localstack.services.ssm.resource_providers.aws_ssm_patchbaseline_plugin:SSMPatchBaselineProviderPlugin", "AWS::EC2::SubnetRouteTableAssociation=localstack.services.ec2.resource_providers.aws_ec2_subnetroutetableassociation_plugin:EC2SubnetRouteTableAssociationProviderPlugin", "AWS::Redshift::Cluster=localstack.services.redshift.resource_providers.aws_redshift_cluster_plugin:RedshiftClusterProviderPlugin", "AWS::IAM::InstanceProfile=localstack.services.iam.resource_providers.aws_iam_instanceprofile_plugin:IAMInstanceProfileProviderPlugin", "AWS::IAM::ManagedPolicy=localstack.services.iam.resource_providers.aws_iam_managedpolicy_plugin:IAMManagedPolicyProviderPlugin", "AWS::ApiGateway::Model=localstack.services.apigateway.resource_providers.aws_apigateway_model_plugin:ApiGatewayModelProviderPlugin", "AWS::EC2::RouteTable=localstack.services.ec2.resource_providers.aws_ec2_routetable_plugin:EC2RouteTableProviderPlugin", "AWS::ResourceGroups::Group=localstack.services.resource_groups.resource_providers.aws_resourcegroups_group_plugin:ResourceGroupsGroupProviderPlugin", "AWS::EC2::Route=localstack.services.ec2.resource_providers.aws_ec2_route_plugin:EC2RouteProviderPlugin", "AWS::SecretsManager::SecretTargetAttachment=localstack.services.secretsmanager.resource_providers.aws_secretsmanager_secrettargetattachment_plugin:SecretsManagerSecretTargetAttachmentProviderPlugin", "AWS::Lambda::Url=localstack.services.lambda_.resource_providers.aws_lambda_url_plugin:LambdaUrlProviderPlugin", "AWS::EC2::InternetGateway=localstack.services.ec2.resource_providers.aws_ec2_internetgateway_plugin:EC2InternetGatewayProviderPlugin", "AWS::Events::ApiDestination=localstack.services.events.resource_providers.aws_events_apidestination_plugin:EventsApiDestinationProviderPlugin", "AWS::SES::EmailIdentity=localstack.services.ses.resource_providers.aws_ses_emailidentity_plugin:SESEmailIdentityProviderPlugin", "AWS::EC2::TransitGatewayAttachment=localstack.services.ec2.resource_providers.aws_ec2_transitgatewayattachment_plugin:EC2TransitGatewayAttachmentProviderPlugin", "AWS::SNS::Topic=localstack.services.sns.resource_providers.aws_sns_topic_plugin:SNSTopicProviderPlugin", "AWS::Elasticsearch::Domain=localstack.services.opensearch.resource_providers.aws_elasticsearch_domain_plugin:ElasticsearchDomainProviderPlugin", "AWS::ApiGateway::Stage=localstack.services.apigateway.resource_providers.aws_apigateway_stage_plugin:ApiGatewayStageProviderPlugin"], "localstack.packages": ["ffmpeg/community=localstack.packages.plugins:ffmpeg_package", "java/community=localstack.packages.plugins:java_package", "terraform/community=localstack.packages.plugins:terraform_package", "opensearch/community=localstack.services.opensearch.plugins:opensearch_package", "kinesis-mock/community=localstack.services.kinesis.plugins:kinesismock_package", "elasticsearch/community=localstack.services.es.plugins:elasticsearch_package", "vosk/community=localstack.services.transcribe.plugins:vosk_package", "jpype-jsonata/community=localstack.services.stepfunctions.plugins:jpype_jsonata_package", "lambda-java-libs/community=localstack.services.lambda_.plugins:lambda_java_libs", "lambda-runtime/community=localstack.services.lambda_.plugins:lambda_runtime_package", "dynamodb-local/community=localstack.services.dynamodb.plugins:dynamodb_local_package"], "localstack.openapi.spec": ["localstack=localstack.plugins:CoreOASPlugin"], "localstack.hooks.on_infra_start": ["delete_cached_certificate=localstack.plugins:delete_cached_certificate", "deprecation_warnings=localstack.plugins:deprecation_warnings", "_run_init_scripts_on_start=localstack.runtime.init:_run_init_scripts_on_start", "_publish_config_as_analytics_event=localstack.runtime.analytics:_publish_config_as_analytics_event", "_publish_container_info=localstack.runtime.analytics:_publish_container_info", "_patch_botocore_endpoint_in_memory=localstack.aws.client:_patch_botocore_endpoint_in_memory", "_patch_botocore_json_parser=localstack.aws.client:_patch_botocore_json_parser", "_patch_cbor2=localstack.aws.client:_patch_cbor2", "init_response_mutation_handler=localstack.aws.handlers.response:init_response_mutation_handler", "eager_load_services=localstack.services.plugins:eager_load_services", "apply_aws_runtime_patches=localstack.aws.patches:apply_aws_runtime_patches", "conditionally_enable_debugger=localstack.dev.debugger.plugins:conditionally_enable_debugger", "setup_dns_configuration_on_host=localstack.dns.plugins:setup_dns_configuration_on_host", "start_dns_server=localstack.dns.plugins:start_dns_server", "register_cloudformation_deploy_ui=localstack.services.cloudformation.plugins:register_cloudformation_deploy_ui", "apply_runtime_patches=localstack.runtime.patches:apply_runtime_patches", "register_swagger_endpoints=localstack.http.resources.swagger.plugins:register_swagger_endpoints", "register_custom_endpoints=localstack.services.lambda_.plugins:register_custom_endpoints", "validate_configuration=localstack.services.lambda_.plugins:validate_configuration"], "localstack.init.runner": ["py=localstack.runtime.init:PythonScriptRunner", "sh=localstack.runtime.init:ShellScriptRunner"], "localstack.hooks.on_infra_ready": ["_run_init_scripts_on_ready=localstack.runtime.init:_run_init_scripts_on_ready"], "localstack.hooks.on_infra_shutdown": ["_run_init_scripts_on_shutdown=localstack.runtime.init:_run_init_scripts_on_shutdown", "publish_metrics=localstack.utils.analytics.metrics.publisher:publish_metrics", "stop_server=localstack.dns.plugins:stop_server", "run_on_after_service_shutdown_handlers=localstack.runtime.shutdown:run_on_after_service_shutdown_handlers", "run_shutdown_handlers=localstack.runtime.shutdown:run_shutdown_handlers", "shutdown_services=localstack.runtime.shutdown:shutdown_services", "remove_custom_endpoints=localstack.services.lambda_.plugins:remove_custom_endpoints"], "localstack.aws.provider": ["acm:default=localstack.services.providers:acm", "apigateway:default=localstack.services.providers:apigateway", "apigateway:legacy=localstack.services.providers:apigateway_legacy", "apigateway:next_gen=localstack.services.providers:apigateway_next_gen", "config:default=localstack.services.providers:awsconfig", "cloudformation:default=localstack.services.providers:cloudformation", "cloudformation:engine-v2=localstack.services.providers:cloudformation_v2", "cloudwatch:default=localstack.services.providers:cloudwatch", "cloudwatch:v1=localstack.services.providers:cloudwatch_v1", "cloudwatch:v2=localstack.services.providers:cloudwatch_v2", "dynamodb:default=localstack.services.providers:dynamodb", "dynamodb:v2=localstack.services.providers:dynamodb_v2", "dynamodbstreams:default=localstack.services.providers:dynamodbstreams", "dynamodbstreams:v2=localstack.services.providers:dynamodbstreams_v2", "ec2:default=localstack.services.providers:ec2", "es:default=localstack.services.providers:es", "events:default=localstack.services.providers:events", "events:legacy=localstack.services.providers:events_legacy", "events:v1=localstack.services.providers:events_v1", "events:v2=localstack.services.providers:events_v2", "firehose:default=localstack.services.providers:firehose", "iam:default=localstack.services.providers:iam", "kinesis:default=localstack.services.providers:kinesis", "kms:default=localstack.services.providers:kms", "lambda:default=localstack.services.providers:lambda_", "lambda:asf=localstack.services.providers:lambda_asf", "lambda:v2=localstack.services.providers:lambda_v2", "logs:default=localstack.services.providers:logs", "opensearch:default=localstack.services.providers:opensearch", "redshift:default=localstack.services.providers:redshift", "resource-groups:default=localstack.services.providers:resource_groups", "resourcegroupstaggingapi:default=localstack.services.providers:resourcegroupstaggingapi", "route53:default=localstack.services.providers:route53", "route53resolver:default=localstack.services.providers:route53resolver", "s3:default=localstack.services.providers:s3", "s3control:default=localstack.services.providers:s3control", "scheduler:default=localstack.services.providers:scheduler", "secretsmanager:default=localstack.services.providers:secretsmanager", "ses:default=localstack.services.providers:ses", "sns:default=localstack.services.providers:sns", "sqs:default=localstack.services.providers:sqs", "ssm:default=localstack.services.providers:ssm", "stepfunctions:default=localstack.services.providers:stepfunctions", "stepfunctions:v2=localstack.services.providers:stepfunctions_v2", "sts:default=localstack.services.providers:sts", "support:default=localstack.services.providers:support", "swf:default=localstack.services.providers:swf", "transcribe:default=localstack.services.providers:transcribe"], "localstack.lambda.runtime_executor": ["docker=localstack.services.lambda_.invocation.plugins:DockerRuntimeExecutorPlugin"], "localstack.hooks.configure_localstack_container": ["_mount_machine_file=localstack.utils.analytics.metadata:_mount_machine_file"], "localstack.hooks.prepare_host": ["prepare_host_machine_id=localstack.utils.analytics.metadata:prepare_host_machine_id"], "localstack.runtime.components": ["aws=localstack.aws.components:AwsComponents"], "localstack.runtime.server": ["hypercorn=localstack.runtime.server.plugins:HypercornRuntimeServerPlugin", "twisted=localstack.runtime.server.plugins:TwistedRuntimeServerPlugin"]}