load balancing, failover behaivor, connection pooling support as hector #1

Closed
ghost opened this Issue May 30, 2010 · 9 comments

Projects

None yet

2 participants

@ghost
ghost commented May 30, 2010

Hi,

Great project, thanks for sharing ! Can you please add the features of hector http://github.com/rantav/hector
I know It's not a simple job and hectorsharp also tried this, but this project seems have more potential.

And I didn't look at the code but EmitMapper http://emitmapper.codeplex.com/ may help for ultra fast mapping and http://fasterflect.codeplex.com/ may help for fast reflection calls to increase performance...

Best Regards, SI

@managedfusion

That has actually been on my hit list, but I really haven't had a chance to figure out the best method for failing over. Is there an algorithm that you would like to see, or a simple round robin failover, sort of the way that load balancing works, where it just goes through a simple list.

@ghost
ghost commented May 30, 2010

Thank you very much for your answer.

I don't know java well but it seems that hector use a simple client list to retry with next on fail (and a sleep before retry) as you can see below...

http://github.com/rantav/hector/blob/master/src/main/java/me/prettyprint/cassandra/service/FailoverOperator.java

@managedfusion

Before I merge in to master, please look at what I have done: I hope it meets you needs. It accomplishes the following:

  • Failovers
  • Connection Pooling
  • Load Balancing (random selection from server list)

http://github.com/managedfusion/fluentcassandra/blob/issue-1/FluentCassandra/Connection/NormalConnectionProvider.cs
http://github.com/managedfusion/fluentcassandra/blob/issue-1/FluentCassandra/Connection/PooledConnectionProvider.cs

There are so many types of load balancing, that I just choose the easiest one (random) in hopes it would spark somebody else to give a better or more robust solution. As far as I could tell, Hector uses a random algorithm for choosing it's load balancing.

@ghost
ghost commented May 31, 2010

You're very responsive and super fast and also very kind, thank you very much for your work and sharing it...

Best Regards,
SI

@managedfusion

That didn't really answer my question that I had for you, but I think I am close enough to what you wanted.

@ghost
ghost commented May 31, 2010

The code seems very good to me, it's all I have dreamed, thank you very much.

@ghost
ghost commented May 31, 2010

This is out of subject, but, is cassandra work on windows as fast as linux, do you have any experience ?

@managedfusion

Cassandra is fully Java based. So any research you do on Java comparisons will likely apply.

@ghost
ghost commented May 31, 2010

thanks again

@nberardi nberardi was assigned Oct 18, 2012
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment