[prev in list] [next in list] [prev in thread] [next in thread] 

List:       cassandra-user
Subject:    =?UTF-8?B?UmU6IOKAnlVzaW5nIFRpbWVzdGFtcOKAnCBGZWF0dXJl?=
From:       Ben Bromhead <ben () instaclustr ! com>
Date:       2016-02-23 17:47:21
Message-ID: CAA=6J08gsge9kGgQz+K6AvZ+2Hbc=589cQcpBNDHRyMNNHsNtw () mail ! gmail ! com
[Download RAW message or body]

When using client supplied timestamps you need to ensure the clock on the
client is in sync with the nodes in the cluster otherwise behaviour will be
unpredictable.

On Thu, 18 Feb 2016 at 08:50 Tyler Hobbs <tyler@datastax.com> wrote:

> 2016-02-18 2:00 GMT-06:00 Matthias Niehoff <
> matthias.niehoff@codecentric.de>:
>
>>
>> * is the 'using timestamp' feature (and providing statement timestamps)
>> sufficiently robust and mature to build an application on?
>>
>
> Yes.  It's been there since the start of CQL3.
>
>
>> * In a BatchedStatement, can different statements have different
>> (explicitly provided) timestamps, or is the BatchedStatement's timestamp
>> used for them all? Is this specified / stable behaviour?
>>
>
> Yes, you can separate timestamps per statement.  And, in fact, if you
> potentially mix inserts and deletes on the same rows, you *should *use
> explicit timestamps with different values.  See the timestamp notes here:
> http://cassandra.apache.org/doc/cql3/CQL.html#batchStmt
>
>
>> * cqhsh reports a syntax error when I use 'using timestamp' with an
>> update statement (works with 'insert'). Is there a good reason for this, or
>> is it a bug?
>>
>
> The "USING TIMESTAMP" goes in a different place in update statements.  It
> should be something like:
>
> UPDATE mytable USING TIMESTAMP ? SET col = ? WHERE key = ?
>
>
> --
> Tyler Hobbs
> DataStax <http://datastax.com/>
>
-- 
Ben Bromhead
CTO | Instaclustr <https://www.instaclustr.com/>
+1 650 284 9692
Managed Cassandra / Spark on AWS, Azure and Softlayer

[Attachment #3 (text/html)]

<div dir="ltr">When using client supplied timestamps you need to ensure the clock on \
the client is in sync with the nodes in the cluster otherwise behaviour will be \
unpredictable.  </div><br><div class="gmail_quote"><div dir="ltr">On Thu, 18 Feb 2016 \
at 08:50 Tyler Hobbs &lt;<a \
href="mailto:tyler@datastax.com">tyler@datastax.com</a>&gt; \
wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 \
.8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div \
class="gmail_extra"><div class="gmail_quote">2016-02-18 2:00 GMT-06:00 Matthias \
Niehoff <span dir="ltr">&lt;<a href="mailto:matthias.niehoff@codecentric.de" \
target="_blank">matthias.niehoff@codecentric.de</a>&gt;</span>:<br><blockquote \
class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid \
rgb(204,204,204);padding-left:1ex"><div><br></div><div><div>* is the &#39;using \
timestamp&#39; feature (and providing statement timestamps) sufficiently robust and \
mature to build an application \
on?</div></div></blockquote><div><br></div></div></div></div><div dir="ltr"><div \
class="gmail_extra"><div class="gmail_quote"><div>Yes.   It&#39;s been there since \
the start of CQL3.<br></div></div></div></div><div dir="ltr"><div \
class="gmail_extra"><div class="gmail_quote"><div>  </div><blockquote \
class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid \
rgb(204,204,204);padding-left:1ex"><div><div>* In a BatchedStatement, can different \
statements have different (explicitly provided) timestamps, or is the \
BatchedStatement&#39;s timestamp used for them all? Is this specified / stable \
behaviour?</div></div></blockquote><div><br></div></div></div></div><div \
dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div>Yes, you can \
separate timestamps per statement.   And, in fact, if you potentially mix inserts and \
deletes on the same rows, you <i>should </i>use explicit timestamps with different \
values.   See the timestamp notes here: <a \
href="http://cassandra.apache.org/doc/cql3/CQL.html#batchStmt" \
target="_blank">http://cassandra.apache.org/doc/cql3/CQL.html#batchStmt</a><br></div></div></div></div><div \
dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div>  </div><blockquote \
class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid \
rgb(204,204,204);padding-left:1ex"><div><div>* cqhsh reports a syntax error when I \
use &#39;using timestamp&#39; with an update statement (works with &#39;insert&#39;). \
Is there a good reason for this, or is it a \
bug?</div></div></blockquote></div></div></div><div dir="ltr"><div \
class="gmail_extra"><div class="gmail_quote"></div><br></div><div \
class="gmail_extra">The &quot;USING TIMESTAMP&quot; goes in a different place in \
update statements.   It should be something like:<br><br></div><div \
class="gmail_extra">UPDATE mytable USING TIMESTAMP ? SET col = ? WHERE key = \
?<br></div></div><div dir="ltr"><div class="gmail_extra"><br clear="all"><br>-- \
<br><div><font color="#888888">Tyler Hobbs<span></span><br> <a \
href="http://datastax.com/" target="_blank">DataStax</a><br></font></div> \
</div></div></blockquote></div><div dir="ltr">-- <br></div><div dir="ltr"><div>Ben \
Bromhead</div>CTO |  <a href="https://www.instaclustr.com/">Instaclustr</a><div>+1 \
650 284 9692</div><div>Managed Cassandra / Spark on AWS, Azure and \
Softlayer</div></div>



[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic