4 ms·
With this type of architecture, aren't you creating latency by separating out the "backend" from the database? In the traditional approach the backend server a
by Touche 10y ago
With this type of architecture, aren't you creating latency by separating out the "backend" from the database? In the traditional approach the backend server and database are in the same datacenter, but it seems that's often not the case in FaaS approach, what are the ramifications of that?
- SideburnsOfDoom 10y agoIf you were on AWS, I would expect the Lamdba fn to be running in the same datacenter as the backing dynamodb table, or at least in the same region. dynamodb response times are pretty good - typically under 10 milliseconds.
- Touche 10y agoThanks, is this something you have to be aware of when setting this all up or does Amazon do this for you?
- SideburnsOfDoom 10y agoAWS is far from simple, and there is a lot to learn. For a start, you will need to know what a Region and Availability zone are: http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-regions-availability-zones.html http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-reg... Roughly speaking: A region is a geographic location (e.g. eu-west-1 is in Ireland and eu-central-1 is in Frankfurt, Germany) The "Availability Zones" are separate datacenter buildings in that region connected by fat pipes. For fault-tolerance, it is common to make sure that all of app's parts run across multiple availability zones in the region. This will happen without much manual config. Crossing regions is very different - it's not going to happen automatically, they're pretty much isolated from each other. Only a few extremely-highly-available apps (e.g. netflix) have engineered to cross regions. See https://www.infoq.com/presentations/netflix-failure-multiple-regions https://www.infoq.com/presentations/netflix-failure-multiple...