You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Jonathan Ellis (JIRA)" <ji...@apache.org> on 2011/04/25 20:05:03 UTC

[jira] [Created] (CASSANDRA-2555) Explicit timestamp support for CQL

Explicit timestamp support for CQL
----------------------------------

                 Key: CASSANDRA-2555
                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2555
             Project: Cassandra
          Issue Type: Improvement
          Components: API
            Reporter: Jonathan Ellis
            Assignee: Pavel Yaskevich
             Fix For: 0.8.1


To make CQL BATCHes useful for the normal purpose of idempotent retries, we need to add  support for client-supplied timestamps.  At a minimum this needs to be available for a batch (BEGIN BATCH USING TIMESTAMP 1303743619771318) but might also be nice at the statement level (UPDATE ... USING TIMESTAMP ...).

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (CASSANDRA-2555) Explicit timestamp support for CQL

Posted by "Jonathan Ellis (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CASSANDRA-2555?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13026352#comment-13026352 ] 

Jonathan Ellis commented on CASSANDRA-2555:
-------------------------------------------

committed to trunk in r1097511

> Explicit timestamp support for CQL
> ----------------------------------
>
>                 Key: CASSANDRA-2555
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2555
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: API
>            Reporter: Jonathan Ellis
>            Assignee: Pavel Yaskevich
>             Fix For: 0.8.1
>
>         Attachments: CASSANDRA-2555-v2.patch, CASSANDRA-2555.patch
>
>
> To make CQL BATCHes useful for the normal purpose of idempotent retries, we need to add  support for client-supplied timestamps.  At a minimum this needs to be available for a batch (BEGIN BATCH USING TIMESTAMP 1303743619771318) but might also be nice at the statement level (UPDATE ... USING TIMESTAMP ...).

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (CASSANDRA-2555) Explicit timestamp support for CQL

Posted by "Jonathan Ellis (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CASSANDRA-2555?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13026322#comment-13026322 ] 

Jonathan Ellis commented on CASSANDRA-2555:
-------------------------------------------

{code}
                    if (up.isSetTimestamp())
                        throw new InvalidRequestException(
                                "Timestamp must be set on the BATCH, not individual statements");

{code}

Unlike ConsistencyLevel, it can make sense to have different timestamps on the individual updates. So we should only reject this if there is a ts on the batch as well.  (I.e., ts on batch = ok, ts on individual updates = ok, ts on both = confusing and not ok.)

bq. 3 tests added

if it doesn't cause conflicts, can you move these into existing batch/update/insert tests?  There is a very high per-method overhead in test_cql since it tears down, wipes, and restarts the server for each.

> Explicit timestamp support for CQL
> ----------------------------------
>
>                 Key: CASSANDRA-2555
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2555
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: API
>            Reporter: Jonathan Ellis
>            Assignee: Pavel Yaskevich
>             Fix For: 0.8.1
>
>         Attachments: CASSANDRA-2555.patch
>
>
> To make CQL BATCHes useful for the normal purpose of idempotent retries, we need to add  support for client-supplied timestamps.  At a minimum this needs to be available for a batch (BEGIN BATCH USING TIMESTAMP 1303743619771318) but might also be nice at the statement level (UPDATE ... USING TIMESTAMP ...).

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Issue Comment Edited] (CASSANDRA-2555) Explicit timestamp support for CQL

Posted by "Pavel Yaskevich (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CASSANDRA-2555?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13025880#comment-13025880 ] 

Pavel Yaskevich edited comment on CASSANDRA-2555 at 4/27/11 4:39 PM:
---------------------------------------------------------------------

USING statement changed to support TIMESTAMP in the following manner for statements INSERT, UPDATE and BATCH:

{noformat}
USING CONSISTENCY <LEVEL> AND TIMESTAMP <NUMBER>

USING TIMESTAMP <NUMBER> AND CONSISTENCY <LEVEL>

USING TIMESTAMP <NUMBER>

USING CONSISTENCY <LEVEL>
{noformat}

CQL.textile is updated + 3 tests added

      was (Author: xedin):
    USING statement changed to support TIMESTAMP in the following manner for statements INSERT, UPDATE and BATCH:

{noformat>
USING CONSISTENCY <LEVEL> AND TIMESTAMP <NUMBER>

USING TIMESTAMP <NUMBER> AND CONSISTENCY <LEVEL>

USING TIMESTAMP <NUMBER>

USING CONSISTENCY <LEVEL>
{noformat}

CQL.textile is updated + 3 tests added
  
> Explicit timestamp support for CQL
> ----------------------------------
>
>                 Key: CASSANDRA-2555
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2555
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: API
>            Reporter: Jonathan Ellis
>            Assignee: Pavel Yaskevich
>             Fix For: 0.8.1
>
>         Attachments: CASSANDRA-2555.patch
>
>
> To make CQL BATCHes useful for the normal purpose of idempotent retries, we need to add  support for client-supplied timestamps.  At a minimum this needs to be available for a batch (BEGIN BATCH USING TIMESTAMP 1303743619771318) but might also be nice at the statement level (UPDATE ... USING TIMESTAMP ...).

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (CASSANDRA-2555) Explicit timestamp support for CQL

Posted by "Pavel Yaskevich (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CASSANDRA-2555?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Pavel Yaskevich updated CASSANDRA-2555:
---------------------------------------

    Attachment: CASSANDRA-2555-v2.patch

QP throws exception only if global and local timestamp were set in BATCH at the same time. 

test for BATCH with TIMESTAMP is moved to the previous test for the BATCH statement but tests for INSERT, UPDATE are left in dedicated tests.

> Explicit timestamp support for CQL
> ----------------------------------
>
>                 Key: CASSANDRA-2555
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2555
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: API
>            Reporter: Jonathan Ellis
>            Assignee: Pavel Yaskevich
>             Fix For: 0.8.1
>
>         Attachments: CASSANDRA-2555-v2.patch, CASSANDRA-2555.patch
>
>
> To make CQL BATCHes useful for the normal purpose of idempotent retries, we need to add  support for client-supplied timestamps.  At a minimum this needs to be available for a batch (BEGIN BATCH USING TIMESTAMP 1303743619771318) but might also be nice at the statement level (UPDATE ... USING TIMESTAMP ...).

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (CASSANDRA-2555) Explicit timestamp support for CQL

Posted by "Pavel Yaskevich (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CASSANDRA-2555?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Pavel Yaskevich updated CASSANDRA-2555:
---------------------------------------

    Attachment: CASSANDRA-2555.patch

USING statement changed to support TIMESTAMP in the following manner for statements INSERT, UPDATE and BATCH:

{noformat>
USING CONSISTENCY <LEVEL> AND TIMESTAMP <NUMBER>

USING TIMESTAMP <NUMBER> AND CONSISTENCY <LEVEL>

USING TIMESTAMP <NUMBER>

USING CONSISTENCY <LEVEL>
{noformat}

CQL.textile is updated + 3 tests added

> Explicit timestamp support for CQL
> ----------------------------------
>
>                 Key: CASSANDRA-2555
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2555
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: API
>            Reporter: Jonathan Ellis
>            Assignee: Pavel Yaskevich
>             Fix For: 0.8.1
>
>         Attachments: CASSANDRA-2555.patch
>
>
> To make CQL BATCHes useful for the normal purpose of idempotent retries, we need to add  support for client-supplied timestamps.  At a minimum this needs to be available for a batch (BEGIN BATCH USING TIMESTAMP 1303743619771318) but might also be nice at the statement level (UPDATE ... USING TIMESTAMP ...).

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (CASSANDRA-2555) Explicit timestamp support for CQL

Posted by "Pavel Yaskevich (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CASSANDRA-2555?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13026323#comment-13026323 ] 

Pavel Yaskevich commented on CASSANDRA-2555:
--------------------------------------------

Gotcha!

> Explicit timestamp support for CQL
> ----------------------------------
>
>                 Key: CASSANDRA-2555
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2555
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: API
>            Reporter: Jonathan Ellis
>            Assignee: Pavel Yaskevich
>             Fix For: 0.8.1
>
>         Attachments: CASSANDRA-2555.patch
>
>
> To make CQL BATCHes useful for the normal purpose of idempotent retries, we need to add  support for client-supplied timestamps.  At a minimum this needs to be available for a batch (BEGIN BATCH USING TIMESTAMP 1303743619771318) but might also be nice at the statement level (UPDATE ... USING TIMESTAMP ...).

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (CASSANDRA-2555) Explicit timestamp support for CQL

Posted by "Hudson (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CASSANDRA-2555?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13027091#comment-13027091 ] 

Hudson commented on CASSANDRA-2555:
-----------------------------------

Integrated in Cassandra #872 (See [https://builds.apache.org/hudson/job/Cassandra/872/])
    

> Explicit timestamp support for CQL
> ----------------------------------
>
>                 Key: CASSANDRA-2555
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2555
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: API
>            Reporter: Jonathan Ellis
>            Assignee: Pavel Yaskevich
>             Fix For: 0.8.1
>
>         Attachments: CASSANDRA-2555-v2.patch, CASSANDRA-2555.patch
>
>
> To make CQL BATCHes useful for the normal purpose of idempotent retries, we need to add  support for client-supplied timestamps.  At a minimum this needs to be available for a batch (BEGIN BATCH USING TIMESTAMP 1303743619771318) but might also be nice at the statement level (UPDATE ... USING TIMESTAMP ...).

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Issue Comment Edited] (CASSANDRA-2555) Explicit timestamp support for CQL

Posted by "Jonathan Ellis (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CASSANDRA-2555?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13026322#comment-13026322 ] 

Jonathan Ellis edited comment on CASSANDRA-2555 at 4/28/11 2:33 PM:
--------------------------------------------------------------------

{code}
                    if (up.isSetTimestamp())
                        throw new InvalidRequestException(
                                "Timestamp must be set on the BATCH, not individual statements");

{code}

Unlike ConsistencyLevel, it can make sense to have different timestamps on the individual updates. So we should only reject this if there is a ts on the batch as well.  (I.e., ts on batch = ok, ts on individual updates within a batch = ok, ts on both = confusing and not ok.)

bq. 3 tests added

if it doesn't cause conflicts, can you move these into existing batch/update/insert tests?  There is a very high per-method overhead in test_cql since it tears down, wipes, and restarts the server for each.

      was (Author: jbellis):
    {code}
                    if (up.isSetTimestamp())
                        throw new InvalidRequestException(
                                "Timestamp must be set on the BATCH, not individual statements");

{code}

Unlike ConsistencyLevel, it can make sense to have different timestamps on the individual updates. So we should only reject this if there is a ts on the batch as well.  (I.e., ts on batch = ok, ts on individual updates = ok, ts on both = confusing and not ok.)

bq. 3 tests added

if it doesn't cause conflicts, can you move these into existing batch/update/insert tests?  There is a very high per-method overhead in test_cql since it tears down, wipes, and restarts the server for each.
  
> Explicit timestamp support for CQL
> ----------------------------------
>
>                 Key: CASSANDRA-2555
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2555
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: API
>            Reporter: Jonathan Ellis
>            Assignee: Pavel Yaskevich
>             Fix For: 0.8.1
>
>         Attachments: CASSANDRA-2555.patch
>
>
> To make CQL BATCHes useful for the normal purpose of idempotent retries, we need to add  support for client-supplied timestamps.  At a minimum this needs to be available for a batch (BEGIN BATCH USING TIMESTAMP 1303743619771318) but might also be nice at the statement level (UPDATE ... USING TIMESTAMP ...).

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira