Slide 1

Slide 1 text

Welcome to the closing keynote of Track 2!

Slide 2

Slide 2 text

Develop and test your AWS-powered Spring Boot application locally

Slide 3

Slide 3 text

[email protected] @tinyg210 tinyg210 Anca Ghenade DevRel Engineer @ LocalStack

Slide 4

Slide 4 text

How does one go around developing applications using AWS services?

Slide 5

Slide 5 text

1. The Software Ninjas are tasked with developing a new web application on AWS Cloud

Slide 6

Slide 6 text

2. Developing on a local machine, they soon find out that there are lots of dependencies with resources in the cloud

Slide 7

Slide 7 text

3. They realize that the dev & test loop is extremely slow and tedious. Every local change needs to be packaged and uploaded to the cloud for testing.

Slide 8

Slide 8 text

4. Now the Software Ninja has a red build on their feature branch, but can’t efficiently test and debug their code in the CI/CD pipeline.

Slide 9

Slide 9 text

5. The whole team is using Git flow for development - one CI build per feature branch. There is an explosion of different environments required for development (branches x developers).

Slide 10

Slide 10 text

6. The Ninja manager approaches the team and complains that AWS dev/test resources are not being cleaned up properly causing cost spikes.

Slide 11

Slide 11 text

So the developer experience sucks. 󰤆

Slide 12

Slide 12 text

What about testing your AWS-powered applications?

Slide 13

Slide 13 text

How much of your system you can test Cloud emulation Full cloud emulation with service integration 3 Staging environments Highest fidelity because it actually runs in the cloud 4 Mocking Mock out cloud APIs 1 Service emulation Replace individual services with local versions 2 Testability of Cloud App Deployments

Slide 14

Slide 14 text

Additional pain points: You’re working in environments that have concerns about: ● Security ● Regulatory compliance ● Data Sovereignty ● Risk Management * We’re talking about banking and healthcare especially here.

Slide 15

Slide 15 text

What is LocalStack? A fully functional local cloud stack that was born out of these exact concerns.

Slide 16

Slide 16 text

How is LocalStack? ● Enables a highly efficient dev & test loop for cloud apps ● Ships as a Docker image, easy to install and start up ● Support for 90-ish services (and growing): ○ compute (Lambda, ECS, EKS) ○ various databases (DynamoDB, RDS) ○ messaging (SQS, Kinesis, MSK) ○ some sophisticated/exotic APIs (Athena, Glue) ● CI integrations & advanced collaboration features ○ redefining the way cloud apps are developed across the lifecycle!

Slide 17

Slide 17 text

AWS vs. LocalStack DEMO

Slide 18

Slide 18 text

“Your application won’t even know the difference”

Slide 19

Slide 19 text

No content

Slide 20

Slide 20 text

Business Logic: ● Shipment entities ● A shipment has one sender and one receiver ● Each participant has an address ● The shipment has weight defined (for ship/plane calculations) ● We need to add the size as a picture ● For size we’re using the IIS (Internet International System) “Banana for scale” Github repo: https://github.com/localstack/shipment-list-demo

Slide 21

Slide 21 text

Github repo: https://github.com/localstack/shipment-list-demo

Slide 22

Slide 22 text

No content

Slide 23

Slide 23 text

Quick recap ● Bean configuration - using Java @Configuration classes ● Java AWS SDK - helps interaction with resources ● Spring Profiles - environment specific configuration ● IaC via Terraform - consistency across environments

Slide 24

Slide 24 text

Switching to LocalStack

Slide 25

Slide 25 text

IaC Tools Developer Tools Language SDKs App Frame- works CI/CD Systems TESTCONTAINERS Copilot

Slide 26

Slide 26 text

No content

Slide 27

Slide 27 text

Because of reasons: ● Most applications are complex in used resources ● Creating resources is time consuming ● Development cycles can be slow - costs developer time ● Resources are tedious to clean up ● If not disposed of properly, resources can be costly ● Interaction between services can be slow on AWS

Slide 28

Slide 28 text

Some benchmarking: AWS LocalStack

Slide 29

Slide 29 text

No content

Slide 30

Slide 30 text

Testcontainers

Slide 31

Slide 31 text

AWS Parity ● AWS Server Framework ○ weekly runs to check parity ○ makes heavy use of botocore ● Snapshot testing ● Metrics collection to track test coverage

Slide 32

Slide 32 text

No content

Slide 33

Slide 33 text

Thank You! Anca Ghenade May 19th, 2023 Barcelona

Slide 34

Slide 34 text

Questions? Anca Ghenade May 19th, 2023 Barcelona

Slide 35

Slide 35 text

[email protected] @tinyg210 tinyg210 Anca Ghenade DevRel Engineer @ LocalStack