-
Notifications
You must be signed in to change notification settings - Fork 43
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Better pool connection fail handling #9
Comments
Well, I like the periodic reconnect idea, but I'm not sure about the need to add new connections. Wouldn't you just update some config (when you add a host/server) and restart your application? |
Am I correct in assuming that the switch to TCPSocket in 0.3.0 doesn't solve this? I've been working on this issue, but I've been working off 0.2.0. I just wanted to check that any efforts to update my patch to work with 0.3.0 won't be wasted. |
Not wasted. Switch to TCP has no effect on this. Thanks for working on it look forward to your patch. On Jan 30, 2013, at 1:23 PM, Paul Cortens [email protected] wrote:
|
Great. I should be able to update my changes for 0.3.0 today or tomorrow, then I'll submit the pull request. I'm looking forward to some feedback. I am a bit concerned you might not be happy with how I did things. |
Ok well I'm definitely interested in taking a look. I do want to make sure we solve this right but I'm sure we can work together on it. Appreciate the help. On Jan 30, 2013, at 2:05 PM, Paul Cortens [email protected] wrote:
|
I haven't submitted a pull request yet because #11 is making it a bit hard to test. I'm seeing some funny stuff happen locally, but I haven't yet been able to determine if is a problem with my new code or that other issue. But I still thought I should throw some code out there: https://github.com/polleverywhere/beaneater/commit/557fc224dfd6f5045c8734b7e906029fc513cc68 I'd particularly like some feedback/suggestions on how to test it. Having the test suite start/kill other processes can be a bit messy. There are also certainly some code style issues that will need to be addressed. I'm not used to your code style, so I wasn't sure of the best way to handle certain things. I could have cleaned it up a bit more, but I probably would have done things you wouldn't have liked. |
Is there any progress on this issue? In the absence of any solution for this issue, I will probably need to resort to something on the lines of having 1-1 mappings between clients and beanstalkd servers (each client with a pool of 1 server) and then implementing the load balancing of jobs as well as the failover in case of a particular beanstalkd server failure myself. But would really be nice if I don't have to go that route and this functionality can be provided by the beaneater client itself. |
Still a work in progress, obviously something we'd like to fix as a part of beaneater. Just not something we've been able to commit the time to yet. If anyone that stumbles on this can help get things sorted into a PR, obviously we'd love to pull it in. |
As per @kr suggestion, if a connection in the pool has an error, it's probably best to close
it, then attempt to reconnect periodically.
Also perhaps be able to add new connections to the pool as well?
The text was updated successfully, but these errors were encountered: