spring-cloud-function
spring-cloud-function copied to clipboard
Improve startuptime (without native compile)
This is related to https://github.com/spring-cloud/spring-cloud-function/issues/852
We have done experiments based on AWS lambda.
- springfranework+ lambda handler
- spring cloud Function + lambda handler(via dep)
In both cases the business code was just returning a static get request as response. While execution time was the same the startup for 2 was factors slower than with 1. I assume there is to much bloat from spring boot loaded without need? Maybe the pure function relevant deps and beans (if not explicit added as starter dep into the pom) shall be used on function apps and spring boot is not dedicated enough for that dedicated requirements of spring cloud function. It would also help to understand if spring aot or spring boot thin layout are helpers in that direction but I would wish when using spring cloud function I get the best of domain of class and don‘t need to tune manually on spring boot deps afterwards. Deps shall be optin not opt out. Everything even without native compilation shall be optimized on startup time and performance. If this topics already covered I’ a happy to get some insights how they are and why 1 is so much faster. I want to use spring cloud function as a base in future and not need to choose between native compile or custom projects setup as 1. Thanks for your contribution to the project and giving advice