Skip to content
This repository

CassandraClientBase nodes collection is not getting cleared #185

Closed
rickcole3 opened this Issue · 6 comments

2 participants

rickcole3 Vivek Mishra
rickcole3

I am getting some inconsistent behavior when using batch mode in Kundera. After committing the transaction, I notice that the Batcher.clear() method (which is implemented on the ThriftClient/PelopsClient) is never called to clear out the nodes collection. As a result, every transaction adds to this list, and the list of nodes gets executed over and over again as well as growing infinitely. The only place I see clear called in in the close() method and onBatchRollBack(). Any ideas on how to get this fixed?

Vivek Mishra
Collaborator

i will look into this.

-Vivek

Vivek Mishra
Collaborator

Hi,
I had a look. It is an issue and a trivial fix for this issue is to modify finally block as :

In CassandraClientBase.java=> executeBatch method,

        finally
        {
            clear();
            releaseConnection(pooledConnection);
        }

        return mutationMap.size();

Just before returining map size.

Let me know, if it works for you. I will get this fixed in 2.4

-Vivek

rickcole3

That's awesome. Thanks for the quick response. When do you expect 2.4 will be released? I am having a couple of other issues that I want to see if 2.4 has addressed.

Vivek Mishra
Collaborator

Did it work for you?
It will be releasing within a week or so. Feel free to share more on issues.

-Vivek

rickcole3

This looks like it will work. I will create another thread for the other issues I am seeing.

Vivek Mishra mevivs referenced this issue from a commit
Vivek Mishra mevivs Fixed issue #185 2e48752
Vivek Mishra
Collaborator

Closing. Releasing with 2.4

Vivek Mishra mevivs closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.