Announcing pulse-0.2.0

I just released a new version of pulse.
Pulse adds an action to your rails project
that can be used for external health checking. The most common use is by
a http proxy such as haproxy.

The main new feature of version 0.2.0 is that the pulse URL is now specified in routes.rb. For example, you
might like /heartbeat better than /pulse. The URL is set up in config/routes.rb like:

map.pulse 'pulse_url'

For example, config/routes.rb might look like:

ActionController::Routing::Routes.draw do |map|
  map.connect ':controller/:action/:id'
  map.pulse 'pulse'
end

Pulse is now a rails plugin instead of a
gem, so check out the new installation instructions.

Pulse no longer monkey patches rails in
the manner described in Add routes with a rails plugin or
gem
.
Now, it mixes a Pulse::Routes module into
ActionController::Routing::RouteSet::Mapper. This allows the “map.pulse”
syntax that is shown above.

The code (lib/routes.rb) looks like:

module Pulse
  module Routes
    def pulse(path)
      connect path, :controller => 'pulse', :action => 'pulse'
    end
  end
end

ActionController::Routing::RouteSet::Mapper.send :include, Pulse::Routes
Paul Gross

Paul Gross

I'm a lead software developer in Seattle working for Braintree Payments.

Read More