2009-12-29 53 views
0

我想從我的JRuby Rails應用程序部署到Heroku的JRuby的公共數據庫適配器

的DB是給我的問題:

$ heroku db:push 
Auto-detected local database: jdbcmysql://root:[email protected]/product_develo 
pment?encoding=utf8 
Failed to connect to database: 
    Sequel::AdapterNotFound -> Could not load jdbcmysql adapter: 
    no such file to load -- /usr/lib/ruby/gems/1.8/gems/sequel-3.0.0/lib/sequel/adapters/jdbcmysql 

任何幫助,請?

回答

1

這與Heroku支持的內容無關(在雲中),因爲db:push的參數是本地數據庫,而不是雲中的數據庫。

試試這個,而不是運行:

heroku db:push jdbc:mysql://root:[email protected]/product_development?encoding=utf8 

此外,考慮更新續集到最新版本。

我還不確定這是否可行,這取決於heroku命令行客戶端是否使用JRuby。另一個可能的問題是ActiveRecord可能需要jdbcmysql,並且Sequel需要jdbc:mysql,並且水龍頭同時使用(當前,希望它將在未來只是續集)。

1

不幸的是Heroku不支持JRuby。您可能想要查看Engine Yard Cloud,它很快就會生產JRuby支持。

+0

鑑於Engine Yard贊助JRuby並聘用了主要的JRuby貢獻者,所以人們確實期望Engine Yard支持JRuby! – yfeldblum 2009-12-30 03:02:31

+0

考慮到Charles是JRuby的主要開發人員之一,並受Engine Yard聘用,我想他知道發生了什麼。 :-) – 2009-12-30 03:17:03

+0

非常感謝!我認爲它支持JRuby。傻我。 – Lilz 2009-12-30 16:37:19