Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion lambdas/service/.chalice/config.json.template.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,14 @@
"api_handler": chalice.vpc_lambda_config(app_name),
service.generate_manifest.name: {
"lambda_timeout": config.service_lambda_timeout,
"lambda_memory_size": 3009 if config.deployment.is_stable else 2048,
# Creating verbatim PFB manifests for large AnVIL datasets
# requires more memory than the default, so we raise it to
# the maximum.
"lambda_memory_size": (
10240 if config.deployment.is_stable and config.is_anvil_enabled()
else 3009 if config.deployment.is_stable
else 2048
),
},
service.update_health_cache.name: {
"lambda_memory_size": 160,
Expand Down
12 changes: 12 additions & 0 deletions src/azul/infra/terraform.py
Original file line number Diff line number Diff line change
Expand Up @@ -785,6 +785,18 @@ def resource_items(resource_type: str) -> Iterable[tuple[str, MutableJSON]]:
package_zip = str(self.package_zip_path(app_name))
resource['source_code_hash'] = '${filebase64sha256("%s")}' % package_zip
resource['filename'] = package_zip
# Creating verbatim PFB manifests for large AnVIL datasets requires
# more ephemeral storage than the default, so we raise it to the
# maximum. We have to inject this here since Chalice doesn't support
# configuring the ephemeral storage.
if (
app_name == 'service'
and resource_name == f'{app_name}_{config.manifest_sfn}'
and config.deployment.is_stable
and config.is_anvil_enabled()
):
assert 'ephemeral_storage' not in resource
resource['ephemeral_storage'] = {'size': 10240}

# Replace any references to unqualified function ARNs in the OpenAPI
# spec emitted by Chalice with references to the alias.
Expand Down
Loading