serverless-java-container icon indicating copy to clipboard operation
serverless-java-container copied to clipboard

fix: reuse AsyncInitializationWrapper in SpringDelegatingLambdaContainerHandler

Open deki opened this issue 9 months ago • 1 comments

Issue #, if available: #758

Description of changes: Did some testing with this app https://github.com/aws-samples/aws-lambda-java-workshop/tree/main/labs/unicorn-store/software/unicorn-store-spring and 512 MB memory. Comparison between old StreamLambdaHandler implementation: Duration: 648.79 ms Billed Duration: 649 ms Memory Size: 1024 MB Max Memory Used: 333 MB Init Duration: 9747.09 ms and new SpringDelegatingLambdaContainerHandler Duration: 16626.82 ms Billed Duration: 16627 ms Memory Size: 1024 MB Max Memory Used: 330 MB Init Duration: 1344.65 ms

With this change the init is done properly. Threading still needs to be removed from SCF.

By submitting this pull request

  • [X] I confirm that my contribution is made under the terms of the Apache 2.0 license.
  • [X] I confirm that I've made a best effort attempt to update all relevant documentation.

deki avatar May 07 '24 16:05 deki

LGTM

maschnetwork avatar May 07 '24 16:05 maschnetwork

LGTM as well

olegz avatar May 15 '24 15:05 olegz