Confirm Download

Simultaneous file downloading works best in FireFox, Chrome, and Safari browsers. Please keep this window open until all downloads are complete. Some customers prefer using file download managers for Chrome or Firefox to better manage large and multiple file downloads.

Cancel Download

Architecture of the MEAN Stack

      • Welcome  (Free)

        Scott Davis introduces himself, and discusses why he won't try to convince you that the MEAN stack (or, for that matter, any other web framework) is the "One Ring to Rule Them All." Instead, you should evaluate the problem that you are trying to solve and pick the right tools for the job. The MEAN stack is a pretty compelling solution for the right set of problems.
      • 00:04:03

      • Meet the LAMP Stack  (Free)

        In order to understand the MEAN stack, you must first be familiar with the older LAMP stack. The rest of this course will use the individual pieces of the LAMP stack as a frame of reference to discuss the unique capabilities of the individual pieces of the MEAN stack.
      • 00:09:51

      • Introducing the MEAN Stack  (Free)

        The MEAN stack is far more than a "hipster upgrade" to the older, established LAMP stack. Each piece of the MEAN stack changes the semantics (and the architectural ramifications) of building a web application. Examples include moving from a traditional RDBMS to a NoSQL / Document persistence store, and moving from a traditional server-side, page-centric MVC architecture to a client-side SPA (single-page app).
      • 00:08:27

      • Platform/Deconstructing the Browser  (Free)

        NodeJS is the platform of the MEAN stack. In this section, you'll deconstruct the browser into a rendering engine (for HTML and CSS) and a scripting engine (for JavaScript). You'll learn what it means to run a "headless" JavaScript engine, and explore the testing benefits of running a "headless" rendering engine like PhantomJS for continuous integration.
      • 00:13:28

      • Meet V8: Your Friendly Neighborhood Headless JavaScript Engine  (Free)

        NodeJS is Chrome's V8 JavaScript engine running "headless" outside of the browser. In this section, you'll learn a little about the history of JavaScript, V8, and the players behind the scenes. But most importantly, you'll learn about the real architectural underpinnings and influences of this much-maligned and misunderstood "toy" language.
      • 00:07:16

      • Headless JavaScript: JS Outside of the Browser

        JavaScript is about so much more than simple DOM manipulation and AJAX. As a matter of fact, these capabilities aren't even built into the core language -- they are APIs provided to the language by the browser. In this section, you'll see which APIs are available to you based on which tier of the application (client, server, or database) you are currently in.
      • 00:10:38

      • Web Server/NodeJS Isn’t the Web Server: Here’s Why

        ExpressJS is the MEAN stack's web server. In this section, you'll explore the modular and asynchronous / event-driven nature of server-side JavaScript development. You'll also see the power of incorporating a web server INTO your application (as opposed to deploying your web application TO an external web server).
      • 00:10:58

      • Introducing CommonJS: Modules, Packages, and NPM (Oh My!)

        Before you can incorporate ExpressJS into your MEAN application, you should have a good working knowledge of CommonJS modules, packages, and NPM. You'll also learn the value of declaring your runtime and build-time dependencies declaratively, and the deceptively simple (yet powerful) value of semantic versioning.
      • 00:20:25

      • Installing ExpressJS

        In this section, you'll install ExpressJS and stand up a simple, barebones web server.
      • 00:05:58

      • ExpressJS Middleware and Routes

        The two key pieces of the MEAN architecture that ExpressJS supplies are middleware and routing. In this section, you'll get a solid, working understanding of both. You'll also get a great example of highly cohesive, loosely coupled architecture in action.
      • 00:10:41

      • Persistence/Relational Databases and NoSQL Solutions

        MongoDB provides persistence for the MEAN stack. In this section, Scott discusses the strengths (and weaknesses) of relational databases and explores "Not Only SQL" (NoSQL) alternatives. Once again, choosing the right tool for the job (rather than looking for problems that can be solved with your existing toolset) should be foremost in the architect's mind.
      • 00:14:04

      • Strong vs. Weak Typing

        How does a JavaScript-based persistence solution like MongoDB change the rules of the game? In this section, you'll consider the characteristics of your programming language and evaluate how well your persistence solution matches the language's paradigm / "world-view".
      • 00:10:32

      • MongooseJS: Object Modeling for MongoDB

        MongooseJS brings structure to a schema-less persistence solution like MongoDB by providing a common, consistent set of fields for your domain objects. It also provides sensible defaults, validation, joins across multiple documents, and much more.
      • 00:08:33

      • Single-Page Applications with Angular JS

        AngularJS provides the User Interface for the MEAN stack. In this section, you'll learn about the 4 characteristics of a SPA (Single-Page Application) -- client-side, single-page, component-oriented, and asynchronous / event-driven.
      • 00:21:04

      • The 4 Characteristics of Angular JS: Declarative

        AngularJS is declarative, rather than imperative. In this section, you'll see a couple of Angular examples side-by-side with jQuery examples to illustrate the difference between the two approaches.
      • 00:08:47

      • Conclusion

        In conclusion, you'll revisit the strengths of the MEAN stack and evaluate whether or not it is the right solution for the problem you're trying to solve.
      • 00:03:57

Architecture of the MEAN Stack

  • Publisher: O'Reilly Media
  • Released: April 2015
  • Run time: 3 hours 25 minutes

Discover how the MEAN development stack—MongoDB, ExpressJS, AngularJS, NodeJS—changes the architecture and semantics of building a web application. In this incisive video course, you’ll learn how NodeJS serves as the MEAN stack platform, ExpressJS acts as the web server, AngularJS delivers the user interface, and MongoDB provides persistence.

Presenter Scott Davis focuses on concepts rather than code to help dispel misconceptions about MEAN and about modern web development in general. You’ll learn how you can mix and match MEAN components, using jQuery Mobile instead of AngularJS, for instance. More importantly, you’ll understand that MEAN is not “one framework to rule them all,” but one of many sets of tools to help you solve web development problems.

  • Deconstruct the browser into a rendering engine (for HTML and CSS) and a scripting engine (for JavaScript)
  • Learn what it means to run a "headless" JavaScript engine
  • Gain a working knowledge of CommonJS modules, packages, and NPM
  • Explore the modular, asynchronous, and event-driven nature of server-side JavaScript development
  • Incorporate a web server into your application—rather than deploy applications to an external web server
  • Understand the strengths and weaknesses of relational databases and NoSQL
  • Learn the four characteristics of building a single-page application with AngularJS

Scott Davis is the founder of ThirstyHead.com, a training and consulting company that that specializes in leading-edge technology solutions such as HTML5, mobile development, SmartTV development, NoSQL, Groovy, and Grails. Scott’s previous books include Getting Started with Grails (InfoQ), Groovy Recipes (Pragmatic), GIS for Web Developers (O’Reilly), and JBoss at Work (O’Reilly).

About the O’Reilly Software Architecture Series

Clearing a path from developer to architect and enriching that path once you arrive. Software architecture is a fast-moving, multidisciplinary subject where entire suites of "best practices" become obsolete practically overnight. No single path or curriculum exists, and different types of architecture—application, integration, enterprise—require different subject emphasis. Whether you’re at the outset of a career as an architect or in the midst of such a career, series editor Neal Ford has curated this collection of tools and guides for aspiring and seasoned architects alike.