Skip to content

Conversation

to-mc
Copy link
Contributor

@to-mc to-mc commented Dec 9, 2019

Issue #, if available: #1305, #413

Description of changes: Update how Logical ID is generated for lambda function version so it takes into account environment variables and memorysize configuration. Changes to these values will now cause an update to the alias when AutoPublishAlias is enabled on the function.

Description of how you validated changes: Translated (sam-translate.py) and deployed function several times with (and without) changing values for env vars and memorysize configuration to confirm expected functionality.

Checklist:

  • Write/update tests
  • make pr passes
  • Update documentation
  • Verify transformed template deploys and application functions as expected
  • Add/update example to examples/2016-10-31

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

Tom McCarthy added 2 commits December 9, 2019 23:02
… changed while AutoPublishAlias is enabled.

Update sam_resources to include function's environment variables and memory config in the input to logical_id_generator which creates SHA hash.
… changed while AutoPublishAlias is enabled.

Update tests which hardcode expected logicalid.
@to-mc to-mc changed the base branch from master to develop December 9, 2019 22:11
@to-mc to-mc changed the title Autopublishalias on envvar change feat: Autopublishalias on envvar change Dec 9, 2019
@to-mc to-mc changed the title feat: Autopublishalias on envvar change feat: Trigger auto publish alias on env var/memorysize change Dec 9, 2019
@to-mc
Copy link
Contributor Author

to-mc commented Dec 10, 2019

Travis build is running against master instead of develop.

@codecov-io
Copy link

codecov-io commented Dec 10, 2019

Codecov Report

Merging #1310 into develop will increase coverage by 0.04%.
The diff coverage is n/a.

Impacted file tree graph

@@             Coverage Diff             @@
##           develop    #1310      +/-   ##
===========================================
+ Coverage    94.38%   94.43%   +0.04%     
===========================================
  Files           78       78              
  Lines         4310     4672     +362     
  Branches       862      932      +70     
===========================================
+ Hits          4068     4412     +344     
- Misses         115      121       +6     
- Partials       127      139      +12
Impacted Files Coverage Δ
samtranslator/model/sam_resources.py 94.17% <0%> (-1.04%) ⬇️
samtranslator/model/apigateway.py 97.1% <0%> (-0.81%) ⬇️
samtranslator/translator/translator.py 98.38% <0%> (-0.65%) ⬇️
samtranslator/model/api/api_generator.py 94.98% <0%> (-0.24%) ⬇️
...lator/plugins/application/serverless_app_plugin.py 83.55% <0%> (ø) ⬆️
samtranslator/model/naming.py 100% <0%> (ø) ⬆️
...amtranslator/policy_template_processor/template.py 100% <0%> (ø) ⬆️
...mtranslator/policy_template_processor/processor.py 100% <0%> (ø) ⬆️
...nslator/model/preferences/deployment_preference.py 100% <0%> (ø) ⬆️
samtranslator/plugins/api/implicit_api_plugin.py 98.23% <0%> (ø) ⬆️
... and 42 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c03ff29...5775e1f. Read the comment docs.

@keetonian keetonian assigned praneetap and unassigned keetonian Jan 31, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants