Cloud Native

THE FALL OF THE BACK-END DEVELOPER

sli.do #FITCloudNative

@vithabada

Many aaSes of the Cloud

FaaS / Serverless

Amazon Web Services

Serverless

  • no servers to manage
  • implicitly highly available & scalable
  • pay-per-request pricing model

  • logging & monitoring built-in

sli.do #FITCloudNative

AWS Lambda

  • Hosted piece of code, that handles events
    • limited time of execution (15min)
  • Pricing in 100ms increments
    • based on configured memory
  • Many event sources
  • Integration-specific input and return values
module.exports = async (event) => {
    return {
        statusCode: 200,
        body: "success",
    };
};

sli.do #FITCloudNative

AWS Lambda Pricing

sli.do #FITCloudNative

DEMO

Highly available, horizontally scalable REST API in under 5 minutes.

Pay-per-use pricing +
High-level tooling +
High-level services

  • Multiple environments / versions no longer cost more
    • sandbox environment for each developer
  • Velocity - focus on solutions, not server management
    • production-grade prototypes
  • Binds operational cost to revenue stream
  • Enhanced developer experience

sli.do #FITCloudNative

DEMO

Node.js AWS devstack

Core "low-level" components

Messaging

Compute

Storage

Identity

S3

S3

DynamoDB

Lambda

SQS

SNS

Cognito

Integration

API Gateway

Cloudfront

Serverless = Distributed

SNS / SQS

  • SQS - fully-managed queue
    • buffering
    • offloading work
  • SNS - notification system with pub/sub semantics
    • organized into Topics
    • integration patterns - broadcast

sli.do #FITCloudNative

DynamoDB

  • "Infinitely" scalable key-value database
    • at consistent latency
    • ideal for customer-facing scenarios
  • Pay-per-request + storage
  • Many weird quirks and specifics
    • read the docs first
  • DynamoDB Streams
    • serves as an integration point

sli.do #FITCloudNative

Serverless = Distributed

  • monolith-first rule does not apply
  • focus on integration & orchestration

  • model business semantics & data flow with infrastructure

sli.do #FITCloudNative

"Cloud Native"

  • commit to your cloud provider, no talk about "lock-in"
  • cloud as a framework - leverage the ecosystem to fit your use case

    • high-velocity environment vs. high-stability environment

    • literally - with aws-cdk

  • moving "up" in abstraction, closer to the user / revenue stream source

sli.do #FITCloudNative

DEMO

AppSync

Takeaways for Software Engineers

  • most software will be running in the cloud (AWS)
  • by constantly reducing cost of development, we plotted our demise

 

  • Product development
    • focus on business, use abstracted services
  • Platform development
    • open standards & protocols
    • offer integration with cloud providers
    • API-first, scriptable, programmable

sli.do #FITCloudNative

Takeaways for Computer Scientists / Students

  • study & research distributed systems
    • CRDTs are hot these days
    • look for heuristics, since formally a lot of things can't be done
  • checkout IPFS
    • multi-transport, multi-discovery p2p storage, pubsub, protocol muxer
  • challenges
    • planet-scale PubSub (maps to Actor Model)
    • horizontal bandwidth scaling (partially solved & patented by Qualcomm)
    • scalable verifiable execution
    • coordination-free BFT consensus (impractically "solved" with "Nakamoto consensus")
    • => all of the above for dynamic mesh networks

sli.do #FITCloudNative

Cloud Native

By Vít Habada

Cloud Native

  • 1,122