{"action":"opened","issue":{"url":"https://api.github.com/repos/zdennis/activerecord-import/issues/272","repository_url":"https://api.github.com/repos/zdennis/activerecord-import","labels_url":"https://api.github.com/repos/zdennis/activerecord-import/issues/272/labels{/name}","comments_url":"https://api.github.com/repos/zdennis/activerecord-import/issues/272/comments","events_url":"https://api.github.com/repos/zdennis/activerecord-import/issues/272/events","html_url":"https://github.com/zdennis/activerecord-import/issues/272","id":149968371,"number":272,"title":"\"No connection pool for ActiveRecord::Base\" exception when using version 0.11.0 and higher","user":{"login":"ilkon","id":1042277,"avatar_url":"https://avatars.githubusercontent.com/u/1042277?v=3","gravatar_id":"","url":"https://api.github.com/users/ilkon","html_url":"https://github.com/ilkon","followers_url":"https://api.github.com/users/ilkon/followers","following_url":"https://api.github.com/users/ilkon/following{/other_user}","gists_url":"https://api.github.com/users/ilkon/gists{/gist_id}","starred_url":"https://api.github.com/users/ilkon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ilkon/subscriptions","organizations_url":"https://api.github.com/users/ilkon/orgs","repos_url":"https://api.github.com/users/ilkon/repos","events_url":"https://api.github.com/users/ilkon/events{/privacy}","received_events_url":"https://api.github.com/users/ilkon/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-04-21T05:07:07Z","updated_at":"2016-04-21T05:07:07Z","closed_at":null,"body":"Starting from version 0.11.0 the import method fails with exception ActiveRecord::ConnectionNotEstablished:\r\n```\r\nActiveRecord::ConnectionNotEstablished: No connection pool for ActiveRecord::Base\r\n/srv/project/shared/bundle/ruby/2.2.0/gems/activerecord-4.2.6/lib/active_record/connection_adapters/abstract/connection_pool.rb:570:in `retrieve_connection'\r\n/srv/project/shared/bundle/ruby/2.2.0/gems/activerecord-4.2.6/lib/active_record/connection_handling.rb:113:in `retrieve_connection'\r\n/srv/project/shared/bundle/ruby/2.2.0/gems/activerecord-4.2.6/lib/active_record/connection_handling.rb:87:in `connection'\r\n/srv/project/shared/bundle/ruby/2.2.0/gems/activerecord-import-0.11.0/lib/activerecord-import/adapters/postgresql_adapter.rb:16:in `insert_many'\r\n/srv/project/shared/bundle/ruby/2.2.0/gems/activerecord-import-0.11.0/lib/activerecord-import/import.rb:420:in `import_without_validations_or_callbacks'\r\n/srv/project/shared/bundle/ruby/2.2.0/gems/activerecord-import-0.11.0/lib/activerecord-import/import.rb:369:in `import_with_validations'\r\n/srv/project/shared/bundle/ruby/2.2.0/gems/activerecord-import-0.11.0/lib/activerecord-import/import.rb:310:in `import_helper'\r\n/srv/project/shared/bundle/ruby/2.2.0/gems/activerecord-import-0.11.0/lib/activerecord-import/import.rb:246:in `import'\r\n```\r\n\r\nDatabase is PostgreSQL 9.3 behind PG Pool, Ruby is 2.2.3, Rails is 4.2.6. I did some tests with the same gems environment but activerecord-import version. Results are stable: version 0.10.0 works perfectly, but 0.11.0, 0.12.0, 0.13.0 fails with exception above."}}