In this presentation, learn about the modernization of application development using a modern database with serverless compute. Learn how to quickly build a website or mobile application backed by MongoDB utilizing serverless compute. See how features and functionality are added with lightning speed, showing a toolset designed to increase your productivity as a developer and enable you to focus on building product-differentiating code. This presentation is brought to you by MongoDB, a member of the AWS Partner Network.
Come costruire un'architettura Serverless nel Cloud AWS
Expedite the development lifecycle with MongoDB and serverless - DEM17-S - New York AWS Summit
1. Expedite the Development Lifecycle with MongoDB & Serverless
Drew DiPalma
Senior Product Manager, Cloud
DEM17-S
2. Presentation
UI Components
UI Process Components
Business
Business
Workflow
Business
Components
Business
Entities
Application Facade
Data
Data Access
Components
Data Helper
Utilities
Server
Agents
Data Sources Services
Users
External
Systems
Service
Interface
CrossCutting
Security
OperationalManagement
Communication
Traditional Applications….
• Contain many, separate layers
• Each layer is separate code, infrastructure
• Connecting/maintaining layers is lots of workSecurity
&
Auth
Integration
Business Logic
Data Access
Hosting
Building an Application
3. Traditional Applications….
• Contain many, separate layers
• Each layer is separate code, infrastructure
• Connecting/maintaining layers is lots of work
Building applications with a Serverless Platform....
• No infrastructure to scale/patch/manage
• Simplified service integrations
• Easy to configure security
• Hosted, serverless business logic
Presentation
UI Components
UI Process Components
Business
Business
Workflow
Business
Components
Business
Entities
Application Facade
Data
Data Access
Components
Data Helper
Utilities
Server
Agents
Data Sources Services
Users
External
Systems
Building a Serverless Application
5. Traditional Applications….
• Contain many, separate layers
• Each layer is separate code, infrastructure
• Connecting/maintaining layers is lots of work
Building applications with a Serverless Platform....
• No infrastructure to scale/patch/manage
• Simplified service integrations
• Easy to configure security
• Hosted, serverless business logic
Presentation
UI Components
UI Process Components
Business
Business
Workflow
Business
Components
Business
Entities
Application Facade
Data
Data Access
Components
Data Helper
Utilities
Server
Agents
Data Sources Services
Users
External
Systems
Building a Serverless Application
6. Traditional Applications….
• Contain many, separate layers
• Each layer is separate code, infrastructure
• Connecting/maintaining layers is lots of work
Building applications with a Serverless Platform....
• No infrastructure to scale/patch/manage
• Simplified service integrations
• Easy to configure security
• Hosted, serverless business logic
Presentation
UI Components
UI Process Components
Business
Business
Workflow
Business
Components
Business
Entities
Application Facade
Data
Data Access
Components
Data Helper
Utilities
Server
Agents
Data Sources Services
Users
External
Systems
Building a Serverless Application
7. QueryAnywhere
Simple, streamlined syntax
for data access, robust
access rules, hosting
included
Build full apps for iOS,
Android, Web, and IoT
Functions
Integrate server-side logic +
microservices + cloud
services
Power apps with Server-side
logic, or enable Data as a
Service with custom APIs.
Triggers
Real-time notifications let your
application functions react in
response to database changes
App responds immediately to
change
MongoDB Stitch’s Services for Application Creation
8. Code user authentication
Code data access controls
Provision backend server
Install runtime environment
Add code to make backend HA
Add code to scale backend
Monitor & manage backend infrastructure
Code REST API for frontend to use backend
Code backend application logic
Code application frontend
Code against each external service API
Continuously poll database for changes
Standard Application
Simple JSON Config
Handled automatically by Stitch and Atlas
Code frontend using single SDK/API to
access backend services
MongoDB Atlas + Stitch
Backend
Data Access
Frontend
Provide JS code for Stitch Functions
9. Cloud Infrastructure
Acces Rules & Service Integrations
Application Logic
MongoDB Atlas
Rapidly deploy, dynamically scale, and distribute
databases across regions.
MongoDB Stitch
Serverless platform with integrated authentication,
access rules, functions, and service integrations.
Client Application or Service
Application Logic
Data
MongoDB Stitch SDKs
Native SDKs with integrated authentication, and
providing access to Stitch, Atlas, and integrated
Services.
Modern Applications with MongoDB
10. • Write generic queries from applications
• Respond with precise information based on the
request
SDKs:
• JavaScript, Android, and iOS SDKs
• Integrated Authentication, Database, and Service
requests
Stitch Rules:
• Fine-grained access rules relating to all aspects of
Stitch
• Access to context from users, request, external
services, functions, etc.
Stitch QueryAnywhere
Stitch
(Authentication & Access Rules)
Application
(Stitch SDK)
MongoDB
11. Stitch is a collection of servers that
process application requests
Requests:
• Single actions for Database or Services
• Or executing a Stitch Function
• Integrated with Stitch’s Rules
Functions:
• Scalable, hosted JavaScript (ES6) Functions
• Integrated with application context
• User, Request, Services, Values, etc.
Stitch Functions
addtoCart calcStats … sendMail
Application
(Stitch SDK)
MongoDB
Stitch Functions
12. Stitch Triggers
• Register a Trigger in your app
• Stitch creates, maintains Change Stream
• Monitors for changes
• Runs Functions on matching changes
Benefits of Stitch Triggers
• React to database events in real-time
• Respond with hosted JavaScript functions
• Separate resources from database
• Fully managed environment
• Access to broad application context
Stitch Functions
MongoDB
addtoCart calcStats … sendMail
order
Stitch Triggers