SlideShare a Scribd company logo
1
Starting from Scratch
with the MEAN Stack
2
Who We Are
Sruti Cheedalla:
Senior Web Developer
Kat Styons:
Web Developer
Matt Cwalinski:
Senior Web Developer
3
Diverse Experience
4
Agenda
Introduction
Sruti Cheedalla
Building with the MEAN Stack
Kat Styons
What’s Next?
Matt Cwalinski
5
Introduction
6
The Problem
7
Travel Photo Contest 2014
8
9
Dynamic form builder that lets you collect user
submissions of text, images and other data
10
11
ADMIN TOOL
12
ADMIN TOOL
13
14
Successful Adoption
15
Successful Adoption
16
Successful Adoption
17
Successful Adoption
18
Photo Credit: Muriel Silva Photography
=
19
20
MongoDB
21
MongoDB ExpressJS
22
MongoDB ExpressJS AngularJS
23
MongoDB ExpressJS AngularJS NodeJS
24
The MEAN Stack
Client
Server
Database
SEND
JSON
POST
TO DB
SEND
JSON
AJAX
25
The MEAN Stack
Database
SEND
JSON
POST
TO DB
26
The MEAN Stack
Server POST
TO DB
SEND
JSON AJAX
SEND
JSON
27
The MEAN Stack
Client
SEND
JSON
AJAX
28
The MEAN Stack
Client
Server
Database
SEND
JSON
POST
TO DB
SEND
JSON
AJAX
29
● Universal end-to-end Workflow
● Focus on speed of development
● Flexible pieces
Value of the MEAN Stack
30
● Universal end-to-end Workflow
Value of the MEAN Stack
31
● Universal end-to-end Workflow
● Focus on speed of development
Value of the MEAN Stack
32
● Universal end-to-end Workflow
● Focus on speed of development
● Flexible pieces
Value of the MEAN Stack
R
33
No MongoDB?
How Dare You!
34
=
Front End
Database Infrastructure
Back End
Full Stack
35
MEAN in the Cloud
36
Building with MEAN Stack
37
What we’ll cover
• Using MongoDB in our project
– NodeJS and MongooseJS
• Life of a submission: See the whole stack
• Custom Mongoose Plugin:
– ElMongoose: Mongoose >> Elastic Search
38
What were we thinking?
Put graphic transition here
39
Structure your data with the app in mind
40
MongoDB vs Relational DB: Viewing a single
submission would have required pulling data from 6 tables if we
had use a relational DB:
- Submissions for
each app have
different form fields
- To make up for
lack of flexibility
this becomes a
complex schema
41
MongoDB vs. Relational DB
With mongo we can store our submissions in a single collection
- All data for a
submission resides in
one document
- This fits with the way
we use submissions
in our app.
42
Using Node and Mongoose
Submission Schema
43
Using Mongoose Models
Submission Schema from previous slide (Submit.js):
Using the schema in server.js (node runs this on start up):
44
Mongoose vs. Mongo Java Driver
• Mongoose
• Mongo Java Driver
45
Life of a submission
46
Life of a Submission
User fills out a form
• Angular has a data model
called $scope
• Each form field is bound
to a key in the object
stored at
$scope.submission
47
Life of a Submission
User Submits the form
• Left: submission json
generated by the form in the
previous slide
• Below: Angular POSTs
submission json to
/submitForm
$scope.submission
hostedController.js
48
Life of a Submission
User Submits the form
• Left: submission json
generated by the form in the
previous slide
• Below: Angular POSTs
submission json to
/submitForm
$scope.submission
hostedController.js
49
Life of a Submission
Request is received by ExpressJS
• Express is listening at port 3000 for all requests
• It’s easy to define routes in express
50
Submission is saved to Mongo
• Left: the json object has not
changed
• Below: submission saved to
Mongo through the Mongoose
Model Sub
Life of a Submission
req.body
51
Jarvis, let’s customize this
52
Search and analytics engine
Hook into your Mongoose Models:
Elastic Search
Fuzzy Matching, Relationships, Complex Aggregations
53
Try ElMongoose
https://www.npmjs.com/package/elmongoose
El
54
ElMongoose: Plugin for syncing data with elastic
search through mongoose.
Hook into your Mongoose Models:
Elastic Search
55
ElMongoose: Plugin for syncing data with elastic
search through mongoose.
Hook into your Mongoose Models:
Elastic Search
56
Hook into your Mongoose Models:
Custom Plugin
You can add methods and hooks to that schema
57
Hook into your Mongoose Models:
Custom Plugin
You can add methods and hooks to that schema
58
Ok... What Now and What’s Next?
59
MEANingful Success?
MongoDB ExpressJS AngularJS NodeJS
60
New Opportunities
Developers Users
61
Opportunities
SaaS
Modular Development
62
Modular Development - What is it?
Modular Development
63
Why Modular Development?
More FlexibleFaster
64
Modular Example
Rolodex Module
(Handles End User Management)
ModuleRoutes Controllers Assets
65
How Modular Development?
CORE PROJECT
Login Rolodex Email
Features
ModuleRoutes Controllers Assets
66
How Modular Development?
Routes Assets
67
How Modular Development?
ModuleRoutes Controllers Assets
CORE Project
ModuleRoutes Controllers Assets
SUB Module
68
How Modular Development?
69
How Modular Development?
gruntfile.js
70
Custom Version of SUB
SUB Application
Login User
Management
Email
71
What do we build with these?
72
SAAS
(Software as a Service)
SaaS
■ Modular Feature Design
■ Single and Multi Tenant Options
73
Single Tenant Application
(Software as a Service)
Application
Database SecurityStorage
74
Single Tenant Application
(Software as a Service)
Application
Database
LOGIN
Storage Security
75
Multi Tenant Application
(Software as a Service)
Application
DatabaseCollection Collection CollectionCollection
76
Multi Tenant Application
(Software as a Service)
Application
DatabaseDeveloper ID Admin ID Party Animal ID
Developer Administrator Party Animal
77
SAAS - How Do We Do It?
(Software as a Service)
78
SAAS - How Do We Do It?
(Software as a Service)
img source: aws.amazon.com
79
SAAS - How Do We Do It?
(Software as a Service)
Tenant Type
User Parameters
Instance Build
New Application
80
SAAS - How Do We Do It?
(Software as a Service)
Tenant Type
User Parameters
Instance Build
New Application
Multi Tenant or Single Tenant?
81
SAAS - How Do We Do It?
(Software as a Service)
(spec file with parameters)
Tenant Type
User Parameters
Instance Build
New Application
82
SAAS - How Do We Do It?
(Software as a Service)
Tenant Type
User Parameters
Instance Build
New Application
83
SAAS - How Do We Do It?
(Software as a Service)
Tenant Type
User Parameters
Instance Build
New Application
84
Why We (heart)
The MEAN Stack
85
MORE OPPORTUNITIES!!!
careers.washingtonpost.com
@wpcareers
● We’re in a unique environment in our team.
● What we are working has visibility.
● We could re-invent ourselves with any challenge.
● If you proved it could work, we could use it.
● Ownership of projects from end to end.
● No Red Tape
● Our work is more fulfilling.
86
Questions?
87
Contact
Matt Cwalinski
LinkedIn: https://www.linkedin.com/in/mcwalinski
Twitter: @mcwalinski
Kat Styons
LinkedIn:https://www.linkedin.com/pub/kat-styons/48/3a4/604
Twitter: @HappyKatTweets
Sruti Cheedalla
LinkedIn:https://www.linkedin.com/in/sruticheedalla
Twitter: @shrootyc
Follow us on Twitter, @SubPlatform!
88
Resources
• MongoDB
• Mongoose.js
• Elasticsearch
• Express.js
• AngularJS
• Node.js
• https://www.npmjs.com/package/elmongoose
• http://coenraets.org/blog/

More Related Content

PPTX
Building your first MEAN application
PPTX
MongoDB Days Silicon Valley: Building Applications with the MEAN Stack
PPTX
Rapid Application Development with MEAN Stack
PDF
Building an E-commerce website in MEAN stack
PPTX
Web Applications Development with MEAN Stack
PPT
Get MEAN! Node.js and the MEAN stack
PPTX
PDF
LAMP is so yesterday, MEAN is so tomorrow! :)
Building your first MEAN application
MongoDB Days Silicon Valley: Building Applications with the MEAN Stack
Rapid Application Development with MEAN Stack
Building an E-commerce website in MEAN stack
Web Applications Development with MEAN Stack
Get MEAN! Node.js and the MEAN stack
LAMP is so yesterday, MEAN is so tomorrow! :)

What's hot (19)

PPTX
FULL stack -> MEAN stack
PDF
Beginning MEAN Stack
PDF
The MEAN stack - SoCalCodeCamp - june 29th 2014
PPTX
You know what iMEAN? Using MEAN stack for application dev on Informix
PDF
Introduction to the MEAN stack
PPTX
Building Modern Web Apps with MEAN Stack
PPTX
MEAN Stack
PDF
MongoDB and the MEAN Stack
PPTX
Introduction to mean stack
PPTX
MEAN Stack - Introduction & Advantages - Why should you switch to MEAN stack ...
PDF
The MEAN Stack
PDF
Mean Stack - An Overview
PPTX
MEAN stack
PPTX
Part One: Building Web Apps with the MERN Stack
PPTX
Starting from Scratch with the MEAN Stack
PDF
NodeSummit - MEAN Stack
PPTX
What is Mean Stack Development ?
PDF
MEAN Stack
FULL stack -> MEAN stack
Beginning MEAN Stack
The MEAN stack - SoCalCodeCamp - june 29th 2014
You know what iMEAN? Using MEAN stack for application dev on Informix
Introduction to the MEAN stack
Building Modern Web Apps with MEAN Stack
MEAN Stack
MongoDB and the MEAN Stack
Introduction to mean stack
MEAN Stack - Introduction & Advantages - Why should you switch to MEAN stack ...
The MEAN Stack
Mean Stack - An Overview
MEAN stack
Part One: Building Web Apps with the MERN Stack
Starting from Scratch with the MEAN Stack
NodeSummit - MEAN Stack
What is Mean Stack Development ?
MEAN Stack
Ad

Viewers also liked (10)

PPT
The MEAN Stack: MongoDB, ExpressJS, AngularJS and Node.js
PPTX
Mean full stack development
PPTX
Lessons Learned from Building a Multi-Tenant Saas Content Management System o...
PPTX
Securing MongoDB to Serve an AWS-Based, Multi-Tenant, Security-Fanatic SaaS A...
PPTX
Introduction to Web Technology Stacks
PDF
MEAN Stack - Google Developers Live 10/03/2013
PPTX
MongoDB: How We Did It – Reanimating Identity at AOL
PDF
MEAN Stack WeNode Barcelona Workshop
PDF
Building Multi-tenant SaaS Applications using WSO2 Private PaaS
PPTX
Playing nice with the MEAN stack
The MEAN Stack: MongoDB, ExpressJS, AngularJS and Node.js
Mean full stack development
Lessons Learned from Building a Multi-Tenant Saas Content Management System o...
Securing MongoDB to Serve an AWS-Based, Multi-Tenant, Security-Fanatic SaaS A...
Introduction to Web Technology Stacks
MEAN Stack - Google Developers Live 10/03/2013
MongoDB: How We Did It – Reanimating Identity at AOL
MEAN Stack WeNode Barcelona Workshop
Building Multi-tenant SaaS Applications using WSO2 Private PaaS
Playing nice with the MEAN stack
Ad

Similar to Starting from Scratch with the MEAN Stack (20)

PDF
Escaping the yellow bubble - rewriting Domino using MongoDb and Angular
PDF
Web_Development_with_Node_Express.pdf
PDF
Getting MEAN with Mongo Express Angular and Node 1st Edition Simon Holmes
PDF
Getting MEAN with Mongo Express Angular and Node 1st Edition Simon Holmes
PPTX
Node js crash course session 5
PDF
Web Development with AngularJS, NodeJS and ExpressJS
PPTX
MIKE Stack Introduction - MongoDB, io.js, KendoUI, and Express
PDF
Basic API Creation with Node.JS
PDF
Javascript Web Applications Otx Alex Maccaw
PDF
Download full ebook of Mean Web Development 2nd Amos Q Haviv instant download...
PPTX
Introduction to Node.js
PPTX
Zero to Hipster with the M.I.K.E. Stack
PDF
MongoDB, Angular.js, HTML5, Groovy, Java all together - WCPGW?!
PDF
Node.js and the MEAN Stack Building Full-Stack Web Applications.pdf
PPTX
The Best Web Development Services And Company in Usa
PPTX
MEAN Stack
PDF
Complete Download Web Development with Node and Express 2nd Edition Ethan Bro...
PDF
Modern webtechnologies
PPTX
MEAN.js Workshop
Escaping the yellow bubble - rewriting Domino using MongoDb and Angular
Web_Development_with_Node_Express.pdf
Getting MEAN with Mongo Express Angular and Node 1st Edition Simon Holmes
Getting MEAN with Mongo Express Angular and Node 1st Edition Simon Holmes
Node js crash course session 5
Web Development with AngularJS, NodeJS and ExpressJS
MIKE Stack Introduction - MongoDB, io.js, KendoUI, and Express
Basic API Creation with Node.JS
Javascript Web Applications Otx Alex Maccaw
Download full ebook of Mean Web Development 2nd Amos Q Haviv instant download...
Introduction to Node.js
Zero to Hipster with the M.I.K.E. Stack
MongoDB, Angular.js, HTML5, Groovy, Java all together - WCPGW?!
Node.js and the MEAN Stack Building Full-Stack Web Applications.pdf
The Best Web Development Services And Company in Usa
MEAN Stack
Complete Download Web Development with Node and Express 2nd Edition Ethan Bro...
Modern webtechnologies
MEAN.js Workshop

More from MongoDB (20)

PDF
MongoDB SoCal 2020: Migrate Anything* to MongoDB Atlas
PDF
MongoDB SoCal 2020: Go on a Data Safari with MongoDB Charts!
PDF
MongoDB SoCal 2020: Using MongoDB Services in Kubernetes: Any Platform, Devel...
PDF
MongoDB SoCal 2020: A Complete Methodology of Data Modeling for MongoDB
PDF
MongoDB SoCal 2020: From Pharmacist to Analyst: Leveraging MongoDB for Real-T...
PDF
MongoDB SoCal 2020: Best Practices for Working with IoT and Time-series Data
PDF
MongoDB SoCal 2020: MongoDB Atlas Jump Start
PDF
MongoDB .local San Francisco 2020: Powering the new age data demands [Infosys]
PDF
MongoDB .local San Francisco 2020: Using Client Side Encryption in MongoDB 4.2
PDF
MongoDB .local San Francisco 2020: Using MongoDB Services in Kubernetes: any ...
PDF
MongoDB .local San Francisco 2020: Go on a Data Safari with MongoDB Charts!
PDF
MongoDB .local San Francisco 2020: From SQL to NoSQL -- Changing Your Mindset
PDF
MongoDB .local San Francisco 2020: MongoDB Atlas Jumpstart
PDF
MongoDB .local San Francisco 2020: Tips and Tricks++ for Querying and Indexin...
PDF
MongoDB .local San Francisco 2020: Aggregation Pipeline Power++
PDF
MongoDB .local San Francisco 2020: A Complete Methodology of Data Modeling fo...
PDF
MongoDB .local San Francisco 2020: MongoDB Atlas Data Lake Technical Deep Dive
PDF
MongoDB .local San Francisco 2020: Developing Alexa Skills with MongoDB & Golang
PDF
MongoDB .local Paris 2020: Realm : l'ingrédient secret pour de meilleures app...
PDF
MongoDB .local Paris 2020: Upply @MongoDB : Upply : Quand le Machine Learning...
MongoDB SoCal 2020: Migrate Anything* to MongoDB Atlas
MongoDB SoCal 2020: Go on a Data Safari with MongoDB Charts!
MongoDB SoCal 2020: Using MongoDB Services in Kubernetes: Any Platform, Devel...
MongoDB SoCal 2020: A Complete Methodology of Data Modeling for MongoDB
MongoDB SoCal 2020: From Pharmacist to Analyst: Leveraging MongoDB for Real-T...
MongoDB SoCal 2020: Best Practices for Working with IoT and Time-series Data
MongoDB SoCal 2020: MongoDB Atlas Jump Start
MongoDB .local San Francisco 2020: Powering the new age data demands [Infosys]
MongoDB .local San Francisco 2020: Using Client Side Encryption in MongoDB 4.2
MongoDB .local San Francisco 2020: Using MongoDB Services in Kubernetes: any ...
MongoDB .local San Francisco 2020: Go on a Data Safari with MongoDB Charts!
MongoDB .local San Francisco 2020: From SQL to NoSQL -- Changing Your Mindset
MongoDB .local San Francisco 2020: MongoDB Atlas Jumpstart
MongoDB .local San Francisco 2020: Tips and Tricks++ for Querying and Indexin...
MongoDB .local San Francisco 2020: Aggregation Pipeline Power++
MongoDB .local San Francisco 2020: A Complete Methodology of Data Modeling fo...
MongoDB .local San Francisco 2020: MongoDB Atlas Data Lake Technical Deep Dive
MongoDB .local San Francisco 2020: Developing Alexa Skills with MongoDB & Golang
MongoDB .local Paris 2020: Realm : l'ingrédient secret pour de meilleures app...
MongoDB .local Paris 2020: Upply @MongoDB : Upply : Quand le Machine Learning...

Recently uploaded (20)

PPTX
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
PDF
KodekX | Application Modernization Development
PDF
solutions_manual_-_materials___processing_in_manufacturing__demargo_.pdf
PDF
NewMind AI Weekly Chronicles - August'25 Week I
PPTX
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
PPTX
Telecom Fraud Prevention Guide | Hyperlink InfoSystem
PDF
AI And Its Effect On The Evolving IT Sector In Australia - Elevate
PDF
Advanced methodologies resolving dimensionality complications for autism neur...
PDF
Electronic commerce courselecture one. Pdf
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
PPT
Teaching material agriculture food technology
PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
PDF
Advanced Soft Computing BINUS July 2025.pdf
PDF
Empathic Computing: Creating Shared Understanding
PDF
madgavkar20181017ppt McKinsey Presentation.pdf
PDF
HCSP-Presales-Campus Network Planning and Design V1.0 Training Material-Witho...
PDF
Advanced IT Governance
PDF
The Rise and Fall of 3GPP – Time for a Sabbatical?
PDF
Shreyas Phanse Resume: Experienced Backend Engineer | Java • Spring Boot • Ka...
PPTX
Big Data Technologies - Introduction.pptx
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
KodekX | Application Modernization Development
solutions_manual_-_materials___processing_in_manufacturing__demargo_.pdf
NewMind AI Weekly Chronicles - August'25 Week I
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
Telecom Fraud Prevention Guide | Hyperlink InfoSystem
AI And Its Effect On The Evolving IT Sector In Australia - Elevate
Advanced methodologies resolving dimensionality complications for autism neur...
Electronic commerce courselecture one. Pdf
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
Teaching material agriculture food technology
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
Advanced Soft Computing BINUS July 2025.pdf
Empathic Computing: Creating Shared Understanding
madgavkar20181017ppt McKinsey Presentation.pdf
HCSP-Presales-Campus Network Planning and Design V1.0 Training Material-Witho...
Advanced IT Governance
The Rise and Fall of 3GPP – Time for a Sabbatical?
Shreyas Phanse Resume: Experienced Backend Engineer | Java • Spring Boot • Ka...
Big Data Technologies - Introduction.pptx

Starting from Scratch with the MEAN Stack