Yes, that was the problem—I actually knew better, but had briefly overlooked
this that when I was doing some refactoring. I am not the OP (although he
himself realized his mistake).
if you follow the thread, I was explaining that the Datastax Java driver
allowed me to basically open a signific
It really doesn't need to be this complicated. You only need 1
session per application. It's thread safe and manages the connection
pool for you.
http://www.datastax.com/drivers/java/2.0/com/datastax/driver/core/Session.html
On Sat, Aug 9, 2014 at 1:29 PM, Kevin Burton wrote:
> Another idea
Another idea to detect this is when the number of open sessions exceeds the
number of threads.
On Aug 9, 2014 10:59 AM, "Andrew" wrote:
> I just had a generator that (in the incorrect way) had a cluster as a
> member variable, and would call .connect() repeatedly. I _thought_,
> incorrectly, tha
IMHO, I think the drivers are fine. It was a dumb mistake of mine to use
sessions as connections and not as connection pools.
What was harder to figure, in my opinion, was that too many connections
from the client would increase the amount of file descriptors used by the
server. I didn't know Linux
I just had a generator that (in the incorrect way) had a cluster as a member
variable, and would call .connect() repeatedly. I _thought_, incorrectly, that
the Session was thread unsafe, and so I should request a separate Session each
time—obviously wrong in hind sight.
There was no special lo
Tyler,
I’ll see if I can reproduce this on a local instance, but just in case, the
error was basically—instead of storing the session in my connection factory, I
stored a cluster and called “connect” each time I requested a Session. I had
defined a max/min number of connections for the connect
Maybe the drivers should have two modes: few sessions, and lots of sessions.
The former would give you a developer-friendly driver error if you leave more
than say a dozen or two dozen sessions open (or whatever is considered a best
practice for parallel threads in a client), on the theory that
Hi everyone,
I am a bit stuck with my data model on Cassandra; What I am trying to do is
to be able to retrieve rows in groups, something similar to sql's GROUP BY
but that works only on one attribute.
I am keeping data grouped together in a different CF (eg. GROUP BY x had
his own CF groupby_x),
Thanks graham for the hints.
I've digged into the source code and found out those 2 classes:
https://github.com/apache/cassandra/blob/trunk/src/java/org/apache/cassandra/db/DeletionInfo.java
https://github.com/apache/cassandra/blob/trunk/src/java/org/apache/cassandra/db/RangeTombstoneList.java