Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Sowing the Seeds of Software Development: What Can You Do with Serverless – In 2021!

Sowing the Seeds of Software Development: What Can You Do with Serverless – In 2021!

AWS User Group Peru Conference, January 24th, 2021

Serverless is always evolving (faster than any definition) and each year new capabilities simplify existing workloads and enable new applications to be implemented in an easier, more efficient way. At AWS, we focused our efforts to increase performance, give options on how to package and deploy, optimize costs for faster interactions, and simplify service integrations. Looking at some of the updates from re:Invent 2020, our yearly learning conference, we introduce the reasoning behind the new features, and how to use them to reduce architecture complexity, including real world examples of what AWS customers are doing, so that you can focus on creating value for YOUR customers.

Danilo Poccia

January 24, 2021
Tweet

More Decks by Danilo Poccia

Other Decks in Programming

Transcript

  1. © 2021, Amazon Web Services, Inc. or its Affiliates.
    Danilo Poccia
    Chief Evangelist (EMEA)
    @danilop
    Sowing the Seeds of
    Software Development
    What Can You Do with Serverless – In 2021

    View Slide

  2. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.

    View Slide

  3. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    Photo by Jeremy Bishop on Unsplash

    View Slide

  4. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    We have an idea
    for a new
    web/mobile app!
    How can we build
    it quickly and put
    it in the hands of
    customers?

    View Slide

  5. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    I want to build a mobile app that helps my
    customers store and analyze videos taken with
    their smartphone.
    You can use a serverless architecture to focus
    on the features you want to build. It’ll be much
    easier to scale up if needed. You’ll also be
    driven to think about security as you build it.
    Serverless
    Com
    puting

    View Slide

  6. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    Serverless function
    API Call
    File uploaded
    Database updated
    Your code
    Your business logic
    Its own permissions
    Something happens
    Event
    Serverless function
    Serverless function
    Serverless function
    Serverless
    Com
    puting

    View Slide

  7. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    Analysis
    Function
    Videos
    Results
    Get Results
    HTTP API
    Upload
    Get
    Serverless
    Com
    puting
    Event
    Write
    Read
    Event

    View Slide

  8. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    Many functions used by my app return very
    quickly, often in less than 20ms.
    Billing
    &
    Cost O
    ptim
    ization
    Billing granularity for Lambda functions has
    been reduced from 100ms down to 1ms with
    no minimum duration. This lowers the price
    for most Lambda functions, more so for short
    duration functions.

    View Slide

  9. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    REPORT RequestId: 35a7e0cb-4902-490d-b8d3-eb315dded660
    Duration: 27.40 ms Billed Duration: 100 ms
    Memory Size: 1024 MB Max Memory Used: 472 MB
    Before
    With 1ms billing granularity
    REPORT RequestId: a24d03b5-429d-4ca3-a490-878a52a0182f
    Duration: 27.55 ms Billed Duration: 28 ms
    Memory Size: 1024 MB Max Memory Used: 472 MB
    1m
    s Billing
    Granularity

    View Slide

  10. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    Lambda functions now can have up to 10 GB of
    memory and 6 vCPUs. This is more than a 3x
    increase compared to previous limits.
    I want to be able to process
    high resolution videos.
    Large
    Functions

    View Slide

  11. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    https://twitter.com/mooyoul/status/1334205430839472129
    FFm
    peg
    First Case
    Study

    View Slide

  12. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    M
    L
    Inference
    w
    ith
    PyTorch
    https://aws.amazon.com/blogs/aws/new-for-aws-lambda-functions-with-up-to-10-gb-of-memory-and-6-vcpus/
    Same Costs
    5x Faster

    View Slide

  13. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    I want to process videos faster. It’ll give a
    better customer experience, and with a
    serverless architecture will also be cheaper!
    AVX2
    support
    AWS Lambda now supports Advanced Vector
    Extensions 2 (AVX2), an extension to the x86
    instruction set architecture that enables
    running a set of highly
    parallelizable operations simultaneously.

    View Slide

  14. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates. Source: https://unsplash.com/photos/IMXhx6qhvf0. Photo credit: Daniel Seßler.
    Bicubic filter
    Bilinear filter Lanczos filter
    Im
    age
    Resizing
    U
    sing
    AVX2
    https://aws.amazon.com/blogs/compute/creating-faster-aws-lambda-functions-with-avx2/

    View Slide

  15. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    Im
    age
    Resizing
    U
    sing
    AVX2
    Filter Without AVX2 With AVX2
    Performance
    improvement
    Bilinear 105 ms 71 ms 32%
    Bicubic 122 ms 73 ms 40%
    Lanczos 136 ms 77 ms 43%
    https://aws.amazon.com/blogs/compute/creating-faster-aws-lambda-functions-with-avx2/

    View Slide

  16. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    The Lambda functions analyzing videos need
    many large dependencies. Also, I want to use a
    custom machine learning model to extract
    more information.
    Packaging
    &
    Deploym
    ent
    AWS Lambda now supports container images
    as a packaging format with an image size up to
    10 GB. This also helps if you invested in
    container tooling for your development
    workflows.

    View Slide

  17. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    FROM public.ecr.aws/lambda/nodejs:latest
    COPY app.js package*.json ./
    RUN npm install
    CMD [ "app.lambdaHandler" ]
    Dockerfile
    Dockerfile
    U
    sing
    ECR
    Public
    https://aws.amazon.com/blogs/aws/new-for-aws-lambda-container-image-support/
    You can use base container images prepared
    by AWS and shared via Docker Hub and
    Amazon Elastic Container Registry
    (ECR) Public.

    View Slide

  18. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    With serverless I can use small functions that
    react to events. But now my main function is
    becoming too big, mixing different
    functionalities such as video resizing and using
    a custom machine learning model.
    O
    rchestration
    &
    Choreography
    You can decompose a large function is small
    tasks that you can execute (and retry)
    independently from each other.
    AWS Step Functions now supports
    Synchronous Express Workflows.

    View Slide

  19. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    Synchronous
    Express W
    orkflow
    s
    https://aws.amazon.com/blogs/compute/new-synchronous-express-workflows-for-aws-step-functions/

    View Slide

  20. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    I want to understand better what my functions
    are doing in production.
    Observability is key! To help you with that,
    Amazon CloudWatch Lambda Insights is now
    generally available. Also, have a look a the
    AWS Distro for OpenTelemetry.
    O
    bservability
    &
    Governance

    View Slide

  21. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    CloudW
    atch
    Lam
    bda
    Insights
    https://aws.amazon.com/blogs/aws/using-amazon-cloudwatch-lambda-insights-to-improve-operational-visibility/

    View Slide

  22. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    I want to use S3 as the source of truth while
    processing images and extracting metadata.
    Isn’t S3 eventually consistent while updating
    objects? I have the same issue with my data
    lake where I store and analyze my logs and
    application data.
    Storage
    Amazon S3 now delivers strong
    read-after-write consistency
    automatically for all applications.

    View Slide

  23. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    Storage

    View Slide

  24. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    I want to keep my data at rest encrypted.
    Storage
    Amazon S3 Bucket Keys reduce the costs of
    Server-Side Encryption with AWS Key
    Management Service (SSE-KMS)

    View Slide

  25. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    Storage

    View Slide

  26. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    I want to use DynamoDB for its low latency
    and on-demand scalability, but I am not
    familiar with NoSQL and its syntax.
    Database
    You now can use a SQL-compatible query
    language to query, insert, update, and delete
    table data in Amazon DynamoDB.
    Also, the NoSQL Workbench can help you
    design your data model and build your
    operations.

    View Slide

  27. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    N
    oSQ
    L
    W
    orkbench

    View Slide

  28. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    I want to create a chatbot to simplify customer
    interactions and give access to customer
    support. I’d like each customer to use their
    native language.
    N
    atural
    Language
    Support
    Amazon Lex has added language support for
    French, Spanish, Italian, Canadian French,
    German, and Latin American Spanish.

    View Slide

  29. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    M
    ulti-Language
    Chatbot

    View Slide

  30. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    I want to use the chatbot
    from my contact center.
    N
    atural
    Language
    Support
    Amazon Connect now supports Amazon Lex
    chatbots for French, Spanish, Italian and
    Canadian French, Latin American Spanish, and
    German.

    View Slide

  31. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    Sentiment Analysis & User Insights
    Cloud-native Contact Center Reference Architecture for Multilingual IT Service Desk
    This reference architecture provides an omnichannel experience
    for end users calling the IT Service Desk (SD) using one or more
    support channels of their choice, such as a landline phone using
    public switched telephone network (PSTN), a softphone from
    their client device, or from their smartphone using an internet
    connection.
    The SD agent, working from a corporate office, uses a web-based
    softphone (CCP) from an internet browser to connect to Amazon
    Connect and interact with end users by answering calls,
    performing web chats, or setting their status in the CCP UI. SD
    agents can also use a traditional telephone service using the
    PSTN.
    SD agents can also connect to Amazon Connect remotely
    through internet connectivity from their home office. All data
    exchanged with Amazon Connect is protected in transit between
    the user’s web browser and Amazon Connect using TLS 1.2 or
    above encryption standards.
    Amazon Connect provides inbound/outbound voice channel,
    web, and mobile chat capabilities with skills-based routing. As
    part of the initial configuration, Amazon Connect enables you to
    claim the phone number and define the support queues, contact
    flows, and routing profiles, which can notify users through email
    or SMS about the status of the ticket. Using Connect Tasks, SD
    agents and managers can automate manual tasks such as user
    follow-ups, setup reminders, and more.
    Amazon Connect integrates with customers’ customer
    relationship management (CRM) or any business intelligence (BI)
    applications hosted in AWS or an on-premise location, or any of
    the existing IT Service Management (ITSM) ticketing tools like
    ServiceNow to pull caller information. This is achieved either by
    using connectors developed by the AWS Partner ecosystem, or by
    creating a custom integration connector using AWS Lambda.
    Further integrating Amazon Connect with Amazon Lex, you can
    create intelligent conversational chatbots to automate high
    volume user contacts without increasing the number of SD
    agents, and without compromising end users experience. End
    users are able perform self-service tasks such as password
    change, procurement of IT accessories, or scheduling meetings
    using natural conversation language with Amazon Lex. In
    conjunction with the contact flows feature in Amazon Connect,
    businesses can turn automated interactions into natural
    conversations to improve end-user experience.
    To improve the efficiency and quality of the contact handling, IT
    SD can gain end-user insights using Amazon Transcribe and
    Amazon Translate to convert speech to text from the voice
    recording stored in Amazon S3. By leveraging Amazon
    Comprehend, SD agents can then analyze the key topics and
    relationships in any given text using Amazon Athena. Amazon
    Macie can be used to protect sensitive data stored in the call
    recording, and focus on the incident or problem context. With this
    analysis, the IT SD can identify user sentiments, and address the
    common issue or a trend that impacts end users’ productivity or
    satisfaction.
    Amazon Connect enables the SD agents to see real-time metrics
    such as SD agents logged in, call abandon rates, number of calls
    handled, SD agent activity status, and so on. This is done by
    analyzing contact trace records (CTRs) using Amazon Kinesis
    Data Streams and Lambda functions, storing them in Amazon
    Redshift, and viewing them on the Amazon Quicksight
    dashboard.
    © 2021, Amazon Web Services, Inc. or its affiliates. All rights reserved.
    Use AWS building blocks for modernizing the IT service desk with an intelligent, omnichannel-based contact center capability using
    Amazon Connect. This reference architecture supports voice, web, mobile, and conversational chatbot channels, including end user
    sentiment analysis, automation, real-time analytics dashboard, and reporting.
    Phone, Speech Assistant, Web and Chat
    Voice & Chat Support Channel
    Inbound &
    Outbound Voice
    Analytics & Reporting
    Internet
    Amazon Kinesis
    Data Firehose
    Amazon Kinesis
    Data Streams
    Mobile
    client
    End Users
    Client
    Client
    Service Desk
    Agents
    Office Contact
    Control Pane
    (CCP)
    Customer
    GW (Primary)
    Remote
    Service Desk
    Agents
    Internet
    GW
    Customer
    GW (Backup)
    Contact
    Control Pane
    (CCP)
    CRM System
    BI System
    Internet
    Conversational Bot Support Channel
    NLP based Bots capability
    Amazon Lex
    Amazon
    DynamoDB
    Amazon Lex
    Validation
    Lambda function
    Amazon SMS
    Events
    AWS Lambda
    Amazon Connect
    Contact
    Flows
    Amazon
    Redshift
    AWS Lambda
    Amazon S3
    Amazon
    QuickSight
    Amazon
    Transcribe
    Amazon
    Comprehend
    Amazon Macie
    Amazon S3
    (stores call
    recording)
    Amazon
    Athena
    Metrics
    Call
    Recordings
    Amazon
    Translate
    Amazon
    QuickSight
    Amazon S3
    Machine Learning
    capabilities
    PSTN
    AWS S2S VPN
    AWS Direct
    Connect
    1
    2
    4
    3
    5
    6
    7
    Integration with 3rd
    party systems (A)
    A. Amazon Connect is an open platform, providing out-of-the-box integrations for leading CRM tools such as Salesforce and Zendesk, Workforce Management (WFM) tools, and analytics tools. Using Lambda, customers
    can create their own integration to their existing ITSM or CRM products. To learn more about various APN partners who have created a custom integration connector with their product to leverage Amazon Connect, see
    Amazon Connect Partners.
    B. Amazon Connect Integration offers a Quick Start guide to organizations using ServiceNow as their ticketing tool. Organizations can use Lambda functions to jumpstart their integration of ServiceNow and Amazon
    Connect, resulting in one unified ITSM UI for SD agents and end users.
    1
    2
    3
    4
    5
    6
    7
    AWS Reference Architecture
    (B)
    E-mail
    notification
    Text
    messages
    Amazon
    Connect
    Tasks
    for
    automation
    AWS
    Lambda
    Customer Workloads
    Customer Location
    APN Partners
    ServiceNow
    Contact Center
    Reference
    Architecture

    View Slide

  32. © 2021, Amazon Web Services, Inc. or its Affiliates.
    © 2021, Amazon Web Services, Inc. or its Affiliates.
    Photo by veeterzy on Unsplash

    View Slide

  33. © 2021, Amazon Web Services, Inc. or its Affiliates.
    Thank you!
    Please give me your feeback J
    Danilo Poccia
    Chief Evangelist (EMEA)
    @danilop

    View Slide