heroku-postgres

Heroku + Sidekiq: ActiveRecord::StatementInvalid: PG::UnableToSend: SSL SYSCALL error: EOF detected

余生颓废 提交于 2019-11-30 11:12:31
Hi we are running on Heroku's Cedar stack with Unicorn and Sidekiq. We intermittently get the following errors BurnThis ActiveRecord::StatementInvalid: PG::UnableToSend: SSL SYSCALL error: EOF detected ActiveRecord::StatementInvalid: PG::ConnectionBad: PQconsumeInput() SSL SYSCALL error: Connection timed out Does anyone have any insight what the direct cause of these errors? Is it too many connections to our database? We have our forking set up already in the following way: unicorn.rb worker_processes Integer(ENV["WEB_CONCURRENCY"] || 3) timeout 30 preload_app true before_fork do |server,

Heroku code=H10 desc=“App crashed” - Can't figure out why it's crashing

痞子三分冷 提交于 2019-11-30 11:11:18
I've been searching around on this one for a while and can't find anything that seems to be applicable in my situation. I've been staring at these logs and I can't see what the problem is. This has happened during deployments before, but always seemed to resolve itself. Now this just happened on its own (no deployment) and I can't get out of it. Tried reverting back to a previous version of the app, but it appears I'm stuck. I've reset the dyno and have also done a rake db:migrate. There are some repetitive things in the log, but I just don't know what to read out of them. Anybody have any

Getting “Unknown primary key for table” while the ID is there

佐手、 提交于 2019-11-29 09:04:01
I've been debugging this strange problem of Rails giving me "Unknown primary key for table...", even when the table's ID is there. I've copied the database from one heroku app to another, on the original databse there is no problem and the new one gives me a db error. This is the error: ProductsController# (ActionView::Template::Error) "Unknown primary key for table collections in model Collection." /app/vendor/bundle/ruby/2.0.0/gems/activerecord-3.2.13/lib/active_record/reflection.rb:366:in `primary_key' /app/vendor/bundle/ruby/2.0.0/gems/activerecord-3.2.13/lib/active_record/reflection.rb

How to change DATABASE_URL for a heroku application

浪子不回头ぞ 提交于 2019-11-29 03:04:56
I wanted to use an external Database with my heroku application. But I'm unable to edit the configuration cariables. I tried using GUI, Which says, Cannot overwrite attachment values DATABASE_URL. While I tried using CLI as well. I used the command: heroku config:addDATABASE_URL="postgresql://username:password@IP:PORT" . However, this throws an error ... is not a heroku command. 0bserver07 After trying out most these answers, I came across an update in 2016, here : the database needs to be detached first, then update the variable of the DATABASE_URL. heroku addons:attach heroku-postgresql -a

Push database to heroku: how to use heroku pg:push

淺唱寂寞╮ 提交于 2019-11-28 23:30:45
I want to push my local postgresql database to heroku, using heroku pg:push command. The command looks like this: heroku pg:push mylocaldb DATABASE --app sushi according to the heroku document: https://devcenter.heroku.com/articles/heroku-postgresql . Here is my local database info: Name: mysitedb User: bill Password: bill The DATABASE_URL environment variable in my machine is set to: postgres://bill:bill@localhost/mysitedb . My app's name is secure-gorge-4090 . I tried heroku pg:push mysitedb DATABASE --app secure-gorge-4090 . The output was: ! Remote database is not empty. ! Please create a

Heroku Database Connection Properties

眉间皱痕 提交于 2019-11-28 04:52:04
I'm trying to perform a relatively trivial task: I want to connect to a Heroku database. I have created the database and have been issued credentials from the Heroku site. However, when I try to connect to this database using anything besides the terminal 'heroku' command line client, I get fatal errors or cannot connect errors. The two tools that I tried to connect with outside of the Heroku terminal application are: Navicat and IntelliJ. The error that I receive in Navicat when trying to connect to the database is: could not connect to server: Host is down Is the server running on host "ec2

Getting “Unknown primary key for table” while the ID is there

喜欢而已 提交于 2019-11-28 02:24:55
问题 I've been debugging this strange problem of Rails giving me "Unknown primary key for table...", even when the table's ID is there. I've copied the database from one heroku app to another, on the original databse there is no problem and the new one gives me a db error. This is the error: ProductsController# (ActionView::Template::Error) "Unknown primary key for table collections in model Collection." /app/vendor/bundle/ruby/2.0.0/gems/activerecord-3.2.13/lib/active_record/reflection.rb:366:in

Heroku database restore issue

二次信任 提交于 2019-11-27 09:39:19
Have gone through different solutions available on stackoverflow and also on different forums. But none addresses the precise problem. As per the documentation: https://devcenter.heroku.com/articles/heroku-postgres-import-export I have the dump file created from my local database, with this command: pg_dump -Fc --no-acl --no-owner -h localhost -U postgres dss_iaya>dss_iaya_db_dump1.dump Then as per documentation, uploaded to a server with public access URL: https://firebasestorage.googleapis.com/v0/b/iaya-664f3.appspot.com/o/dss_iaya_db_dump1.dump?alt=media&token=06167d04-1e98-4e4b-b0e0

Heroku Database Connection Properties

懵懂的女人 提交于 2019-11-27 00:34:34
问题 I'm trying to perform a relatively trivial task: I want to connect to a Heroku database. I have created the database and have been issued credentials from the Heroku site. However, when I try to connect to this database using anything besides the terminal 'heroku' command line client, I get fatal errors or cannot connect errors. The two tools that I tried to connect with outside of the Heroku terminal application are: Navicat and IntelliJ. The error that I receive in Navicat when trying to

Heroku database restore issue

半腔热情 提交于 2019-11-26 14:48:22
问题 Have gone through different solutions available on stackoverflow and also on different forums. But none addresses the precise problem. As per the documentation: https://devcenter.heroku.com/articles/heroku-postgres-import-export I have the dump file created from my local database, with this command: pg_dump -Fc --no-acl --no-owner -h localhost -U postgres dss_iaya>dss_iaya_db_dump1.dump Then as per documentation, uploaded to a server with public access URL: https://firebasestorage.googleapis