Skip to content
This repository has been archived by the owner on Jan 15, 2024. It is now read-only.

ConnectionPool::PoolShuttingDownError #378

Open
sahin opened this issue Jun 7, 2015 · 14 comments
Open

ConnectionPool::PoolShuttingDownError #378

sahin opened this issue Jun 7, 2015 · 14 comments

Comments

@sahin
Copy link

sahin commented Jun 7, 2015

If there is a network error or connection error, and if there is a change replication set primary, we started to have this error. It happens like every 10-12 hours and create thousands of errors. We have to app restart to fix it.

I am using latest moped 2.0.5.

@nofxx
Copy link

nofxx commented Jun 7, 2015

They are all related, this one, #346, #348 ...
Default pool size (5) start the failures in a few minutes, experimenting with 70 gives some days.

@nofxx
Copy link

nofxx commented Jun 7, 2015

@sahin do you have many #find_and_update on your code? It's the only change, you might try mongoid 5, and get rid of moped.
Thinking about doing it now, we're in a fork in mongoid's life, suffering in the transition heh.
Also, which mongodb version?

@sahin
Copy link
Author

sahin commented Jun 8, 2015

@nofxx , we are in mongo 4.0.2

our pool is 500. We have instant 100 connections from web, api, player. and workers.

We never user find and update. We have lots of find, user related data writes , and many writes in workers, there are find, update or create.

I would loce to get rid of moped. Is mongoid 5 ready to use in production?

I would Is mongoid 5

@sahin
Copy link
Author

sahin commented Jun 8, 2015

We use mongo 2.6.10 . We will move to 3.0.3 soon.

I would love to use mongoid 5

@nofxx
Copy link

nofxx commented Jun 8, 2015

Hello sahin. It's not production ready, check the repo, but can't be worst than this pool nightmare.
Or it can. If you code doens't have any find_and_update, just change mongoid on Gemfile to use git:

Here we are with mongo 3.0.3, moped 2.0.5 patched with pool_size increase.
But I still got some pool issues some hours ago, hoping for a day w/o errors...
If it happens at work hours today going to try mongoid 5 tomorrow.. =/

@sahin
Copy link
Author

sahin commented Jun 8, 2015

"hoping for a day w/o errors..." this connection pool error makes me wake up 2-3 times at night....

@arthurnn @durran do u guys suggest to move mongoid 5 master

@nofxx
Copy link

nofxx commented Jun 10, 2015

Without any rep machine failing it's more than a day w/o errors now. Not sure if one goes down, will try sometime in the early morning today.

Only issue now is a sidekiq worker that won't stop eating RAM. Not sure it's related to the moped pool, experimenting now.

@agrass
Copy link

agrass commented Jul 10, 2015

Anyone here who already tried mongoid5? @sahin? We are with mongoid 4.0.2 and moped 2.0.6 and still failing

@marlonoso
Copy link

+1 same here

  • mongoid (4.0.2)
  • moped (2.0.6)
  • pool_size: 100

@jlhonora
Copy link

jlhonora commented Aug 5, 2015

We just migrated to rails 4.1.12 and the issue seems to be gone (+2 weeks, never saw the bug since). No idea how it could be related.

@nofxx
Copy link

nofxx commented Aug 5, 2015

Now that you mentioned rails @jlhonora , might be what fixed here too, but we're in 4.2.3.
What we still get is sidekiq not releasing RAM, it happened together with the pool bug, but now the pool bug is gonne and the ram eating persists.

@brand-it
Copy link

brand-it commented Aug 7, 2015

I am going to try going from 4.1.10 to 4.1.12 and see if that changes anything. I will post if I see the same results as @jlhonora.

@brauliobo
Copy link

same here, no fix?!?

@brand-it
Copy link

brand-it commented Mar 8, 2017

I have not seen the bug after going to gem 'mongoid', '5.1.1'

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants