Building Applications on Mesos

Book description

How can Apache Mesos make a difference in your organization? With this practical guide, you’ll learn how this cluster manager directs your datacenter’s resources, and provides real time APIs for interacting with (and developing for) the entire cluster. You’ll learn how to use Mesos as a deployment system, like Ansible or Chef, and as an execution platform for building and hosting higher-level applications, like Hadoop. Author David Greenberg shows you how Mesos manages your entire datacenter as a single logical entity, eliminating the need to assign fixed sets of machines to applications. You’ll quickly discover why Mesos is the ultimate DevOps tool.

Publisher resources

View/Submit Errata

Table of contents

  1. Preface
    1. Conventions Used in This Book
    2. Safari® Books Online
    3. How to Contact Us
    4. Acknowledgments
  2. 1. Introduction to Mesos
    1. How to Use Mesos
    2. Mesos as a Deployment System
    3. Mesos as an Execution Platform
    4. How This Book Is Structured
    5. Summary
  3. 2. Getting Started with Mesos
    1. Frameworks
    2. Masters and Slaves
      1. The Masters
      2. The Slaves
    3. Resources
      1. Configuring Custom Resources
      2. Configuring Slave Attributes
    4. Roles
      1. Static and Dynamic Slave Reservations
    5. Tasks and Executors
      1. CommandExecutor
    6. Understanding mesos.proto
    7. Not Managed by Mesos
    8. Summary
  4. 3. Porting an Existing Application to Mesos
    1. Moving a Web Application to Mesos
    2. Setting Up Marathon
    3. Using Marathon
      1. Scaling Your Application
      2. Using Placement Constraints
      3. Running Dockerized Applications
      4. Health Checks
      5. Application Versioning and Rolling Upgrades
      6. The Event Bus
      7. Setting Up HAProxy with Marathon
    4. Running Mesos Frameworks on Marathon
      1. What Is Chronos?
      2. Running Chronos on Marathon
      3. Chronos Operational Concerns
      4. Chronos on Marathon: Summary
    5. Alternatives to Marathon + Chronos
      1. Singularity
      2. Aurora
    6. Summary
  5. 4. Creating a New Framework for Mesos
    1. The Scheduler
      1. Pool of Servers Scheduler
      2. Work Queue Scheduler
      3. Job Processor Scheduler
    2. Useless Remote BASH
    3. Implementing a Basic Job Processor
    4. Matching Tasks to Offers
      1. Bridging the Semantic Gap Between Offers and Jobs
    5. Adding High Availability
    6. Adding Reconciliation
    7. Advanced Scheduler Techniques
      1. Distributed Communication
      2. Forced Failover
      3. Consolidating Offers
      4. Hardening Your Scheduler
      5. Framework UI
      6. Allocating Ports
      7. Checkpointing
      8. CommandInfo
    8. Summary
  6. 5. Building a Mesos Executor
    1. The Executor
      1. Building a Work Queue’s Worker
      2. Running Pickled Tasks
      3. Sharing Resources
      4. Better Babysitting
      5. Augmented Logging
    2. Rewriting the CommandExecutor
    3. Bootstrapping Executor Installation
    4. Adding Heartbeats
    5. Advanced Executor Features
      1. Progress Reporting
      2. Adding Remote Logging
      3. Multiple Tasks
    6. Summary
  7. 6. Advanced Topics in Mesos
    1. Libprocess and the Actor Model
    2. The Consistency Model
      1. How Is Slave Failure Handled?
      2. How Is Master Failure Handled? (Or, the Registry)
      3. Reconciliation During Failover
    3. Containerizers
      1. Using Docker
    4. The New Offer API
      1. Framework Dynamic Reservations API
      2. Persistent Volumes for Databases
    5. Summary
  8. 7. The Future of Mesos
    1. Multitenant Workloads
    2. Oversubscription
    3. Databases and Turnkey Infrastructure
    4. IP per Container
    5. Summary
  9. Index

Product information

  • Title: Building Applications on Mesos
  • Author(s): David Greenberg
  • Release date: December 2015
  • Publisher(s): O'Reilly Media, Inc.
  • ISBN: 9781491926529