title: Differences between railties and engines in Ruby On Rails 3
body: <p>I read a few documents on these arguments, but I did not understand clearly what they are, what are the differences between them and if one of them fits my needs.</p>
  <p>I need to write a piece of application which can be plugged in other application and I want to include it in other applications as a gem. Essentially I need a couple of models, one controller and no views, plus some initialization, support for configuration parameters coming from the hosting app and a generator.</p>
  <p>Am I on the right way?</p>
  <p>What should I read to understand how to do that?</p>
  <p><strong>Update:</strong></p>
  <p>A very nice article with a lot af details can be found <a href="https://gist.github.com/af7e572c2dc973add221" rel="noreferrer" title="here">here</a>.</p>
  <p>Essentially:</p>
  <blockquote>
  <p>Railtie is the core of the Rails Framework and provides several hooks to extend Rails and/or modify the initialization process.</p>
  <p>A Rails::Engine is nothing more than a Railtie with some initializers already set. And since Rails::Application and Rails::Plugin are engines, the same configuration described here can be used in all three.</p>
  </blockquote>