Programming for PaaS

Book description

Platform-as-a-Service (PaaS) is gaining serious traction among web and mobile developers, but as new PaaS providers emerge and existing vendors upgrade their features, it’s hard to keep track of what PaaS has to offer. This thorough introduction takes you through the PaaS model from a developer’s point of view, and breaks down the types of services that Google App Engine, Windows Azure, Heroku, Cloud Foundry, and others deliver.

Whether you’re an entrepreneur or part of a large enterprise development team, this book shows you how PaaS can help you focus on innovative applications, rather than spend your time worrying about technical operations.

  • Track the cloud’s evolution from IaaS and DevOps to PaaS
  • Learn how PaaS combines the simplicity of shared web hosting with the control of dedicated hosting
  • Explore the benefits of both portable and non-portable PaaS options
  • Apply best practices for moving legacy apps to PaaS—and understand the challenges involved
  • Write new applications for PaaS from scratch with RESTful meta-services
  • Use PaaS to build mobile apps with backend services that scale
  • Examine the core services that each major provider currently offers
  • Learn the situations in which PaaS might not be advantageous


Publisher resources

View/Submit Errata

Table of contents

  1. Dedication
  2. Preface
    1. Programming Is Hard
    2. Writing Code That Works on PaaS
    3. Audience
    4. The Structure of This Book
    5. Conventions Used in This Book
    6. Safari® Books Online
    7. How to Contact Us
    8. Acknowledgments
  3. 1. The Cloud for Developers
    1. The Developer’s Plight
    2. What the Cloud Has Done for Innovation
    3. The Cloud: A Brief History for Programmers
      1. Introducing APIs
      2. Along Comes DevOps
      3. The Arrival of Application Lifecycle Management
      4. The Next-Generation Cloud with Platform-as-a-Service
    4. The Core of the Cloud
    5. Managed Platforms versus Productized Platforms
    6. The Cloud’s Promise (or Hype)
    7. The Cloud in Five Years
    8. The Promise Fulfilled
  4. 2. What Is PaaS?
    1. Conjuring a Website
    2. Early Options for Developers
      1. Shared Web Hosting
      2. Dedicated Hosting
        1. Colocated servers
        2. Managed servers
        3. Virtual private servers
        4. Infrastructure-as-a-Service
        5. Comparing costs
    3. PaaS: The Best of Both Worlds
      1. The Developer’s Holy Grail
      2. Sharing the Load
      3. Language Considerations
      4. PaaS Pricing
      5. Is PaaS Really New or Just IaaS++?
        1. Looking at atomic units
        2. IaaS versus PaaS
    4. PaaS: A Vital Tool for Modern Apps
      1. Moving Toward Higher-Level Languages
      2. Managing the Backend
    5. Conjuring Confidence
  5. 3. Types of PaaS
    1. Non-Portable: Following a Template
      1. Force.com
      2. Google App Engine
      3. Windows Azure
      4. Non-Portable Conclusion
    2. Portable: No Heavy Lifting Required
      1. Heroku
      2. Cloud Foundry
      3. AppFog
      4. dotCloud
      5. CloudBees
    3. Summary: Where Do You Want to Live?
    4. Dealing with Legacy and Greenfield Apps
    5. Tapping Into Services
    6. Moving Toward Open Standards
      1. The Allure of Open Source
      2. Evaluating Your Legacy
  6. 4. Moving Legacy Apps to PaaS
    1. Initial Considerations
      1. Sidestepping Potential Problems
      2. Common Questions to Ask Yourself
      3. Even More Legacy Code Issues
    2. Overview
    3. Asset Hosting
      1. All About Blob
      2. PHP with Amazon S3
      3. Node.js with Azure Blob Service
      4. Generalized Asset Hosting Functions in Ruby for Rackspace Cloud Files
      5. Uploading with Plug-ins
    4. Session Management
      1. PHP
      2. Node.js
      3. Ruby
      4. Java
    5. Caching
      1. Filling In the Pieces
      2. Caching with memcached in PHP
      3. Caching with MongoDB in Node.js
      4. Generalized Caching Functions in Ruby for Redis
    6. Asynchronous Processing
      1. Serving Up Stored Data
      2. How to Create Asynchronous Processes
      3. More Advanced Scheduling of Background Tasks
    7. SQL
      1. The Dilemma of Stored Procedures
    8. NoSQL
    9. Miscellaneous Gotchas
      1. The Optimization Trap
      2. Starting from Scratch
      3. A Final Note on Legacy Apps
  7. 5. Writing New Apps for PaaS
    1. Breaking Down the Monolith
      1. Independent Thinking
    2. Leveraging APIs for Mobile Development
    3. The Emergence of JSON and REST
      1. A Look at JSON
      2. A Look at REST
      3. A Look at Metaservices
    4. Consuming RESTful Metaservices
      1. Application Clients
      2. Mobile Clients
      3. Thin Web Clients
      4. Thick Web Clients
    5. The Unique Contribution of PaaS
      1. Four Important Benefits
        1. Agility
        2. Time to market
        3. Scalability
        4. Interoperability
      2. A Solution for Enterprises and Governments
    6. The Effect of Moore’s Law
  8. 6. Mobile Apps on PaaS
    1. A Brief History of Mobile App Development
    2. The Apps of the Future
    3. Data Structures
      1. JSON and XML
    4. Consuming Metaservices in Mobile Clients
      1. iOS
        1. iOS framework for REST: RestKit
      2. Android
        1. Android framework for REST: Restlet
    5. How PaaS Makes Mobile Backend Development Easier
      1. It’s Fast to Build Mobile Backend Metaservices
      2. It’s Easy to Scale Metaservices with PaaS
      3. It’s Easy to Pick the Right Underlying Core Services
      4. Portable Interfaces Can Be Used on Many Devices
    6. Serving a Large Audience
  9. 7. A Look at Core Services
    1. Non-PaaS Core Services
    2. Evaluating PaaS for Services
    3. Saving Time with Managed Databases and PaaS
      1. SQL
      2. NoSQL
    4. Caches and PaaS: Look for Redundancy
    5. Solving the Challenges of Email
    6. The Importance of Monitoring
      1. Considering Your Options
      2. Taking the Long View
    7. Load Testing
    8. Planning an Upgrade Path
      1. Storage Options
  10. 8. Why Not PaaS?
    1. Public Cloud versus Private Cloud
      1. What Is Private Cloud?
    2. How to Choose: Small- and Medium-Sized Businesses
      1. Open and Closed
    3. How to Choose: Enterprise Businesses
    4. The Limitations of PaaS
      1. Fitting Your App into the Mold
      2. More Considerations
      3. Avoiding Limitations
    5. Encountering Resistance
    6. Putting the Limitations in Perspective
  11. 9. The Future of PaaS
    1. The Influence of OpenStack
    2. Keeping Your Development Options Open
    3. Outages: Your Biggest Problem
    4. Regaining Control Through Open Source
      1. Micro Magic
      2. Limitations of Open Source PaaS Libraries
      3. The Virtues of Versatility
    5. Final Thoughts
  12. 10. Resources
    1. PaaS Providers
    2. IaaS Providers
    3. Managed Services
      1. Data storage: MySQL
      2. Data storage: PostgreSQL
      3. Data storage: CouchDB
      4. Data storage: MongoDB
      5. Data storage: NoSQL
      6. Data storage: Redis
      7. Data storage: Caching
      8. Mobile
      9. Search
      10. Logging
      11. Email
      12. Background Tasks
      13. Analytics
      14. Error Monitoring
      15. Utilities
      16. Payments
    4. Migrating Legacy Apps to PaaS
      1. WordPress Plug-ins
      2. Drupal Modules
      3. Joomla! Plug-ins
    5. Greenfield PaaS App Development
      1. Ruby
      2. Python
      3. Node.js
      4. PHP
      5. Java
      6. .NET
      7. Perl
  13. Index
  14. Colophon
  15. Copyright

Product information

  • Title: Programming for PaaS
  • Author(s): Lucas Carlson
  • Release date: July 2013
  • Publisher(s): O'Reilly Media, Inc.
  • ISBN: 9781449335120