aws / aws/aws-sam-cli

sam deploy if run with samconfig.toml takes a few minutes (~3 minutes in my case) than passing configuration directly as arguments to sam deploy

Open
#5,185 5 comments 0 reactions 0 assignees View on GitHub
stage/bug-repro stage/needs-investigation
Dominant language
Python
Stars
6.7k
Forks
1.2k
Avg merge
1d 10h
Merged PRs (30d)
52

Description

### Description:
- sam deploy when samconfig.toml is extremely slow as compared to configuring using arguments.
- In my case, it's amounting to 3 minutes.

### Steps to reproduce:
- Create a sam template that takes a few parameters
- There are 2 situations
1. samconfig.toml
- Configure the parameters via `parameter_overrides` section in the samconfig.toml
2. arguments
- Configure everything using arguments, for parameter overrides use `--parameter-overrides`
- Don't use samconfig.toml (delete it)
- Note the time difference between the 2

### Observed result:
#### 1. With samconfig.toml
![image](https://github.com/aws/aws-sam-cli/assets/69104012/a201ea17-df44-41ae-9320-e2d23336104a)

#### 2. With Command Arguments
![image](https://github.com/aws/aws-sam-cli/assets/69104012/d59553b9-59e8-43da-8a4f-d38eb6997fb3)

### Expected result:

### Additional environment details (Ex: Windows, Mac, Amazon Linux etc)
```
{
"version": "1.84.0",
"system": {
"python": "3.8.10",
"os": "Linux-5.15.0-1019-aws-aarch64-with-glibc2.29"
},
"additional_dependencies": {
"docker_engine": "20.10.17",
"aws_cdk": "2.34.2 (build 7abcbc6)",
"terraform": "1.2.6"
},
"available_beta_feature_env_vars": [
"SAM_CLI_BETA_FEATURES",
"SAM_CLI_BETA_BUILD_PERFORMANCE",
"SAM_CLI_BETA_TERRAFORM_SUPPORT",
"SAM_CLI_BETA_RUST_CARGO_LAMBDA"
]
}
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.