rack-active_record_status 0.4 → 0.4.1

Sign up to get free protection for your applications and to get access to all the features.
data/README.rdoc CHANGED
@@ -20,6 +20,9 @@ config file (<tt>config/application.rb</tt> for Rails 3, <tt>config/environment.
20
20
 
21
21
  config.middleware.use Rack::ActiveRecordStatus
22
22
 
23
+ # In older Rails, like 2.3.4, defer loading using a string:
24
+ config.middleware.use "Rack::ActiveRecordStatus"
25
+
23
26
  Test your ActiveRecord connection by hitting
24
27
 
25
28
  GET /app_status
@@ -15,8 +15,8 @@ module Rack
15
15
  def get_status
16
16
  begin
17
17
  ActiveRecord::Base.connection.select_all('select 1')
18
- body = "OK #{Time.now}"
19
- [200, {'Content-Type' => 'text/plain'}, body]
18
+ # Success
19
+ [200, {'Content-Type' => 'text/plain'}, "OK #{Time.now}\n"]
20
20
  rescue
21
21
  body = ['ERROR', "#{$!.class}: #{$!.message}", "Backtrace:"] + $!.backtrace
22
22
  body *= "\n"
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'rack-active_record_status'
3
- s.version = '0.4'
3
+ s.version = '0.4.1'
4
4
 
5
5
  s.summary = "Rack middelware to check ActiveRecord's connection"
6
6
  s.description = "A server health check for active_record."
metadata CHANGED
@@ -1,12 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rack-active_record_status
3
3
  version: !ruby/object:Gem::Version
4
- hash: 3
4
+ hash: 13
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 4
9
- version: "0.4"
9
+ - 1
10
+ version: 0.4.1
10
11
  platform: ruby
11
12
  authors:
12
13
  - Aaron Suggs
@@ -14,7 +15,7 @@ autorequire:
14
15
  bindir: bin
15
16
  cert_chain: []
16
17
 
17
- date: 2011-05-03 00:00:00 -04:00
18
+ date: 2011-06-29 00:00:00 -04:00
18
19
  default_executable:
19
20
  dependencies:
20
21
  - !ruby/object:Gem::Dependency