http://pragprog.com/book/jkdepj/deploying-with-jruby
Deploying with JRuby: Deliver Scalable Web Apps using the JVM
by Joe Kutner
Cover Image For Deploying with JRuby...
Code • Errata • Discussions
200 pages (est), 2012-08-15
ISBN: 978-1-93435-697-5
Progress • Releases
Deploy using the JVM’s high performance while building your apps in the language you love. JRuby is a fast, scalable, and powerful JVM language with all the benefits of a traditional Ruby environment. See how to consolidate the many moving parts of an MRI-based Ruby deployment onto a single JVM process. You’ll learn how to port a Rails application to JRuby, get it into production, and keep it running. Watch the video
Buy Now
Select a Format:
Beta eBook + Paper Book ($41.00)
Beta eBook ($21.00)
Buy the eBook and get these DRM-free formats:
epub (for iPhone/iPad, Android, eReaders)
mobi (for Kindle)
PDF
We can automatically deliver them to your Kindle or Dropbox, if you want (but you'll need to log in).
This title is currently available in Beta. Buy the eBook now, and you'll be able to download successive releases of the eBook as the authors add material and correct mistakes. You'll get the final eBook when the book is finished.
If you buy the combo pack (Beta eBook + finished Paper Book) now, you'll get the Beta eBook immediately. You'll get the finished paper book when it's released (we're currently estimating 2012-08-15, but these dates can change).
About this Book
JRuby deployments have fewer moving parts and consume less memory than traditional Ruby deployments, but to deploy your apps on the JVM, you need to learn some new approaches. This book introduces you to three JRuby deployment strategies that will give you the performance and scalability you need while letting you use the language you love.
You’ll start by porting an existing application to JRuby, preparing the app to take advantage of the JVM platform. Then you’ll use Vagrant and Puppet to build a virtual production environment so you have a stable, reproducible place to explore JRuby deployment.
With your environment in place, you’ll experiment with simple JRuby deployment with Warbler as you package your Ruby web application into a single file you can deploy to a Java application server. Next you’ll set up the lightweight Trinidad web server to create a more flexible, modular deployment that fits more complex situations but still feels friendly and familiar to Ruby developers. You’ll switch to powering your app with TorqueBox, an all-in-one JRuby environment that includes built-in support for messaging, scheduling, and daemons—perfect for handling the “big jobs.” Then, you’ll set up a continuous integration environment with Jenkins so you can deploy like the pros.
Deploying with JRuby is the missing link between enjoying JRuby and using it in the real world to build high-performance, scalable applications.
Want to see how easy it is to do? Watch the video
What You Need:
To run the examples in this book, you’ll need a computer that can run the Java Virtual Machine.
Contents and Extracts
This book is currently in beta, so the contents and extracts will change as the book is developed.
Preface
Getting Started with JRuby
What Makes JRuby So Great? excerpt
Introducing Warbler excerpt
Preparing Twitalytics for JRuby
Configuring Warbler for Twitalytics
Wrapping Up
Creating a Deployment Environment
Creating a Virtual Server excerpt
Provisioning with Puppet
Packaging the Deployment Environment
Using Alternative Platforms
Wrapping Up
Deploying an Archive File
Provisioning a Server
Installing Apache Tomcat
Creating the Deployment Script
Deploying to the Cloud
Wrapping Up
Creating a Trinidad Application
What is Traditional Deployment
Getting Started with Trinidad
Adding Trinidad Extensions
Alternatives to Trinidad
Wrapping Up
Deploying A Trinidad Application
Provisioning a Server
Installing Trinidad as a Service
Hot Deploying with Capistrano
Configuring Apache
Alternative Deployment Strategies
Wrapping Up
Creating a TorqueBox Application
What is an Application Server
Getting Started with TorqueBox
Creating a Deployment Descriptor
Using the Management Console
Scheduling a Recurring Job
Creating a Long-Running Daemon
Running Background Jobs
Pushing to the Browser with Stomplets
Testing a TorqueBox Application
Wrapping Up
Deploying a TorqueBox Application
Clustering a TorqueBox Application
Managing a JRuby Deployment
Using a Continuous Integration Server