Microservices are one of the latest trends in architecture design.
Made popular by the introduction of Amazon Lambda, Google Cloud Functions and Azure Functions. They seem to offer a way to structure code as a set of independent services that interact together to work as one, making each part simpler and offering an easy way to scale up. But just as every other technology they bring their own set of challenges.
Join us on lessons we learned while converting simple application to work on Lambda.
20. https://www.linkedin.com/pulse/aws-lambda-container-lifetime-config-refresh-frederik-willaert
Q: Typically, how long can I expect a container to live if it’s idle?
A: The "official" answer to all of these questions goes something like,
"We reserve the right to make changes to better serve customers and
so I can't give you a response that's guaranteed to remain accurate."
But that said, in the current implementation we'll typically consider a
function a candidate for what we call "fast spindown" if we haven't
seen it used in the last five minutes. This can vary by event type,
function and account history, etc. but is generally the case.
26. #!/programmer
create EC2 instance
add instance to VPC and setup firewall
install Jenkins
for (service of services):
create service and configure package.JSON
run claudia create manually
create GitHub repository
create SSH key-pair*
add Jenkins as webhook
add SSH key-pair
create Jenkins project
configure Jenkins
push local repo to Github
hope it all works!
28. #!/programmer
create EC2 instance
add instance to VPC and setup firewall
install Jenkins
for (service of services):
create service and configure package.JSON
run claudia create manually
create GitHub repository
create SSH key-pair
add Jenkins as webhook
add SSH key-pair
create Jenkins project
configure Jenkins
push local repo to Github
hope it all works!
32. One, last thing :)
Always redeploy functions after changing configuration!
Because changes only take place when new function version gets deployed.
33. Big thanks to Gordan and Damir.
Blog post (covering most of the presentation)
Soon on Axilis.com blog
Book (recommended by Damir)
Building Microservices by Sam Newman
Introduction:
https://app.pluralsight.com/library/courses/microservices-architecture/table-of-contents
https://www.nginx.com/blog/introduction-to-microservices/
VPC Example:
https://gist.github.com/reggi/dc5f2620b7b4f515e68e46255ac042a7
References:
https://claudiajs.com/claudia-api-builder.html
https://www.linkedin.com/pulse/aws-lambda-container-lifetime-config-refresh-frederik-willaert
https://medium.com/@tjholowaychuk/dos-and-don-ts-of-aws-lambda-7dfcab7ad115#.937xuhm3a
http://docs.aws.amazon.com/lambda/latest/dg/limits.html