OK, so Cassandra 2.1 now rejects writes it considers too big. It is
possible to increase the value by changing commitlog_segment_size_in_mb
in cassandra.yaml. It defaults to 32MB, and the maximum segment size for
a write is half that value:

from CommitLog.java:
// we only permit records HALF the size of a commit log, to ensure we
don't spin allocating many mostly
 // empty segments when writing large records
   private static final long MAX_MUTATION_SIZE =
DatabaseDescriptor.getCommitLogSegmentSize() >> 1;


which explains (with the request overhead) why my ~30,5MB blob was
rejected.

Simon

Le 20/06/2014 11:24, Simon Chemouil a écrit :
> For the record, I could reproduce the problem with blobs of size below 64MB.
> 
> Caused by: java.lang.IllegalArgumentException: Mutation of 32000122
> bytes is too large for the maxiumum size of 16777216
> 
> 32000122 is just ~30MB and fails on 2.1-rc1 while it works on 2.0.X for
> even larger values (up to 64MB works fine)
> 
> Simon
> 
> Le 20/06/2014 11:00, Simon Chemouil a écrit :
>> Le 20/06/2014 10:41, Duncan Sands a écrit :
>>> Hi Simon,
>>> 122880122 bytes is a lot more than 0.6MB...  How are you sending your blob?
>>
>> Turns out there was a mistake in my code. The blob in this case was
>> actually 122MB!
>> Still the same code works fine on Cassandra 2.0.x so there might be a
>> bug lurking. Even if it's definitely above the recommended limit.
>>
>> Simon
>>

Reply via email to