Download Deploying with JRuby: Deliver Scalable Web Apps using the by Joe Kutner PDF

By Joe Kutner

Deploy utilizing the JVM's excessive functionality whereas construction your apps within the language you like. JRuby is a quick, scalable, and strong JVM language with the entire merits of a conventional Ruby atmosphere. See the best way to consolidate the numerous relocating components of an MRI-based Ruby deployment onto a unmarried JVM technique. You'll how one can port a Rails program to JRuby, get it into construction, and continue it running.

JRuby deployments have fewer relocating components and devour much less reminiscence than conventional Ruby deployments, yet to install your apps at the JVM, you want to research a few new methods. This publication introduces you to 3 JRuby deployment options that would provide the functionality and scalability you would like whereas letting you employ the language you love.

You'll commence through porting an current software to JRuby, getting ready the app to exploit the JVM platform. Then you'll use Vagrant and Puppet to construct a digital construction setting so that you have a strong, reproducible position to discover JRuby deployment.

along with your surroundings in position, you'll test with uncomplicated JRuby deployment with Warbler as you package deal your Ruby internet software right into a unmarried dossier you could set up to a Java program server. subsequent you'll manage the light-weight Trinidad internet server to create a extra versatile, modular deployment that matches extra complicated occasions yet nonetheless feels pleasant and frequent to Ruby builders. You'll change to powering your app with TorqueBox, an all-in-one JRuby atmosphere that comes with integrated aid for messaging, scheduling, and daemons--perfect for dealing with the "big jobs." Then, you'll organize a continual integration setting with Jenkins so that you can set up just like the pros.

Deploying with JRuby is the lacking hyperlink among having fun with JRuby and utilizing it within the actual global to construct high-performance, scalable applications.

What You Need:

To run the examples during this ebook, you'll want a computing device that could run the Java digital Machine.

Show description

Read or Download Deploying with JRuby: Deliver Scalable Web Apps using the JVM (Pragmatic Programmers) PDF

Similar programming books

Beginning Perl (3rd Edition)

It is a ebook for these people who believed that we didn’t have to research Perl, and now we all know it really is extra ubiquitous than ever. Perl is intensely versatile and robust, and it isn’t petrified of internet 2. zero or the cloud. initially touted because the duct tape of the web, Perl has because advanced right into a multipurpose, multiplatform language current totally far and wide: heavy-duty internet purposes, the cloud, structures management, usual language processing, and monetary engineering.

Additional resources for Deploying with JRuby: Deliver Scalable Web Apps using the JVM (Pragmatic Programmers)

Example text

Pp file to the new directory and edit it to contain the following class: 6. 7. pp class postgres { package { 'postgresql': ensure => present, } user { 'postgres': ensure => 'present', require => Package['postgresql'] } group { 'postgres': ensure => 'present', require => User['postgres'] } } This will install the postgresql package and create the matching system user and group. Now we need to add a vagrant user to PostgreSQL and give it permissions to create databases and tables. pp exec { "createuser" : command => "createuser -U postgres -SdRw vagrant", user => 'postgres', path => $path, unless => "psql -c \ \"select * from pg_user where usename='vagrant'\" | grep -c vagrant", require => Group['postgres'] } exec { "psql -c \"ALTER USER vagrant WITH PASSWORD 'Passw0rd'\"": user => 'postgres', path => $path, require => Exec["createuser"] } 32 • Chapter 2.

We’re going to drive VirtualBox with Vagrant. To install Vagrant, download the binary installer for your operating system from the official website4 and run it. 1 We could have installed the Vagrant gem, but that is not the preferred method of installation, since certain Vagrant commands do not work on JRuby. These include vagrant ssh and vagrant reload. It is possible to work around these deficiencies by running the vagrant-ssh script provided with the source code and by running vagrant halt && vagrant up, respectively, but using the binary distribution saves us a lot of time.

Webapp 2011/10/22 17:37:13] - Info: using runtime pool timeout of 30 seconds [webapp 2011/10/22 17:37:13] - Warning: no min runtimes specified. [webapp 2011/10/22 17:37:13] - Warning: no max runtimes specified. Ajp13Listener not ... HttpsListener not fo... 10 running: c... [Winstone 2011/10/22 17:37:13] - HTTP Listener started: port=8080 Now point a browser to http://localhost:8080, and you should see the Twitalytics dashboard again. The first time will take a while to load because Rails has some precompilation to do, but it will warm up after that.

Download PDF sample

Rated 4.20 of 5 – based on 49 votes