DevNet Associate DEVASC 200-901 Official Certification Guide by Adrian Iliesiu (z-lib.org)

(andrew) #1

When writing code, you create a function that you call
repeatedly at different places in the code to make it more
efficient. Serverless deployment uses the same write
once/use may times concept: You write some code and
then call it remotely through your application.


Serverless applications typically execute some type of
application logic but do not store data. Your calling
application is expected to handle that part of it. For
example, say you want to create a function that converts
images you receive to a universal size and shape. You can
then load this function into a serverless offering from
AWS, and any time you receive a new picture, it is sent to
the function and returned in the correct format (see
Figure 13-13).


Figure 13-13 Serverless Image Resizing Example


The whole idea behind serverless and why a customer
may want to use it is that it doesn’t require dedicated
hardware or resources to be set aside for these periodic
processes. The customer pays for the resources used, and
then the services are shut down until needed again; this
is a better cost model. The following are some of the
advantages of serverless deployment:


Cost: Serverless can be significantly cheaper than prepaying for
infrastructure that is underutilized. The pay-as-you-go computing
model means you are not charged for time your service is not being
used.
Free download pdf