Production and development mode

Hi
I would like to know the basic difference in running an application
in development mode and production mode like
./script/server and
./script/server RAILS_ENV=production

Thanks in advance
Sijo

On 31 Oct 2008, at 10:38, Sijo Kg wrote:

Hi
I would like to know the basic difference in running an
application
in development mode and production mode like
./script/server and
./script/server RAILS_ENV=production

Well at the very least it means the app uses the production database
instead of the development one (as dictated by database.yml).
It also means that config/environments/production.rb is loaded instead
of config/environments/development.rb
Some settings also have a different default (eg the logger level)

Fred

On 31 Oct 2008, at 11:49, Sijo Kg wrote:

Hi
thanks for the reply…So is there large speed differnce in
development and production mode?
Well it depends on the settings you have made. By default there is a
big difference because with the default settings your app’s code is
reloaded on each request.

Fred

Hi
thanks for the reply…So is there large speed differnce in
development and production mode? Also to run my server in production
mode I have to do any of the below
./script/server RAILS_ENV=production or ./script/server -e production

Is that all done?Nothing other setup is needed?

Sijo

Also, some plugins behave differently depending on the environment.
For example, the exception_notification plugin won’t send you an email
you when an exception occurs if you’re running in development mode,
but does in production mode.