I have very basic sinatra app:
---------------------------------------
# my_test_app.rb
require 'sinatra/base'
class MyTestApp < Sinatra::Base
def initialize
puts "Initialize method called ..."
super
end
get '/' do
puts "Hello from my test application!"
"Hello from my test application!"
end
end
---------------------------------------
# config.ru
require './my_test_app'
puts `bundle list`
puts
puts "Starting MyTestApp app ..."
run MyTestApp
---------------------------------------
# Gemfile
source :rubygems
gem 'rack', '~> 1.4.1'
#gem 'rack', '~> 1.3.6'
gem 'sinatra', '~> 1.3.2'
If it is bundled with rake 1.4.1 and deployed on Heroku, then on every
request 'config.ru' is reloaded again and again and output messages
(bundle list and messages) go to heroku logs on every query.
But if app bundled with rack 1.3.6 on Heroku, then 'config.ru'
loaded only once as expected. Also If I run app locally, then
'config.ru' loaded only once for any rake version.
Why such kind of different behavior if sinatra app uses rack 1.4.1?
--
You received this message because you are subscribed to the Google Groups
"Heroku" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/heroku?hl=en.