Sinatra + Heroku + Datamapper Deploy Issues with Dm-Sqlite-Adapter

Sinatra Datamapper errors when deploying in Heroku

I think that dm-sqlite-adapter is referenced either from your Gemfile, either from some other place in the code, probably the place where you configure the data-mapper. Or maybe it's references in the data-mapper YAML config, if you have one.

Heroku not Loading do_postgres dependency

Heroku got back to me, very promptly:

Hello,

I noticed you're using windows for
your development environment. There is
currently a limitation on with bundler
and cross platform use, i.e. if you
develop locally on windows but deploy
to a unix server like heroku. The
current workaround is to remove your
Gemfile.lock.

Best,

[removed]

Indeed, after removing Gemfile.lock Heroku installed the do_postgres gem properly. I had originally committed Gemfile.lock because the Heroku interface recommended it, ("Gemfile.lock will soon be required"), so perhaps a little warning somewhere that this breaks compatibility with Windows would be nice. Of course, the cross-platform thing was not my decision. :)

Adding an ORM to a Sinatra app; Is there an ideal one with less issues and good performance?

Sequel is fast enough but feature less while ActiveRecord has many cool features what lead to some performance problems.

But, in most cases, performance of the ORM shouldn't become a problem with wise usage. Usually you should think about database performance and application design but not about ORM performance.

If you need something easy and straight you should use Sequel, but for big applications with many nesting forms I prefer ActiveRecord.



Related Topics



Leave a reply



Submit