cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sylvain Lebresne (JIRA)" <>
Subject [jira] [Commented] (CASSANDRA-11293) NPE when using CQLSSTableWriter
Date Mon, 07 Mar 2016 08:27:40 GMT


Sylvain Lebresne commented on CASSANDRA-11293:

Are you using a single instance of {{CQLSSTableWriter}} from multiple threads? If so, that's
wrong, {{CQLSSTableWriter}} is not thread-safe (I'll add something to the javadoc in that
regard though, since that's arguably not clearly stated). In particular CASSANDRA-7463 wasn't
saying that {{CQLSSTableWriter}} should be thread-safe, it was saying that you should be able
to use multiple instance of {{CQLSSTableWriter}} (but each one should still be used from a
single thread) within a single JVM.

> NPE when using CQLSSTableWriter
> -------------------------------
>                 Key: CASSANDRA-11293
>                 URL:
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Tools
>         Environment: C* 3.3, C* trunk
>            Reporter: Will Hayworth
> Hi all!
> I'm trying to using CQLSSTableWriter to load a bunch of historical data into my cluster
and I'm getting NullPointerExceptions consistently after having written a few million rows
(anywhere from 0.5 to 1.5 GB of data).
> {code}
> java.lang.NullPointerException
> at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(
at java.lang.reflect.Constructor.newInstance( at java.util.concurrent.ForkJoinTask.getThrowableException(
at java.util.concurrent.ForkJoinTask.reportException( at java.util.concurrent.ForkJoinTask.invoke(
at$ForEachOp.evaluateParallel( at$ForEachOp$OfRef.evaluateParallel(
at at
>  at com.atlassian.engagementengine.segmentation.helenus.Daemon.main(
> Caused by: java.lang.NullPointerException at
at at
> java.util.TimSort.binarySort( at
> java.util.TimSort.sort( at
> java.util.Arrays.sort( at
> org.apache.cassandra.utils.btree.BTree$Builder.sort( at org.apache.cassandra.utils.btree.BTree$Builder.autoEnforce(
at org.apache.cassandra.utils.btree.BTree$ at
at org.apache.cassandra.db.partitions.PartitionUpdate.maybeBuild(
at org.apache.cassandra.db.partitions.PartitionUpdate.holder( at
at org.apache.cassandra.db.partitions.AbstractBTreePartition.unfilteredIterator(
> {code}
> This may be a red herring, but I started encountering this when I parallelized writes.
(I wasn't aware that doing so was safe until I saw CASSANDRA-7463; I Googled in vain for a
while before that.) I'm also definitely not passing any nulls in my {{addRow}} calls.

This message was sent by Atlassian JIRA

View raw message