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 2010/10/30 03:54:20 UTC

[jira] Created: (CASSANDRA-1687) Add UUID functions to cli

Add UUID functions to cli
-------------------------

                 Key: CASSANDRA-1687
                 URL: https://issues.apache.org/jira/browse/CASSANDRA-1687
             Project: Cassandra
          Issue Type: New Feature
          Components: Tools
            Reporter: Jonathan Ellis
            Assignee: Pavel Yaskevich
            Priority: Minor
             Fix For: 0.7.1


Add timeuuid and lexicaluuid functions to the cli:

set timeline[jbellis][timeuuid()] = ...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CASSANDRA-1687) Add UUID functions to cli

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

Pavel Yaskevich updated CASSANDRA-1687:
---------------------------------------

    Attachment: CASSANDRA-1687-functions-support-for-row-keys.patch

Example:

{code}
connect localhost/9160
create keyspace Tests
use Tests

create column family DynamicColumns
set DynamicColumns[timeuuid()][timeuuid()] = hello
set DynamicColumns[timeuuid()][lexicaluuid()] = world
set DynamicColumns[timeuuid()][lexicaluuid(550e8400-e29b-41d4-a716-446655440000)] = utf8(test)
set DynamicColumns[timeuuid()][timeuuid()] = 125
set DynamicColumns[timeuuid(a193ffdf-eda2-11df-a193-ffdfeda211df)][long(31337)] = utf8(gg)

assume DynamicColumns keys as timeuuid 
list DynamicColumns
get DynamicColumns[timeuuid(a193ffdf-eda2-11df-a193-ffdfeda211df)]
get DynamicColumns[timeuuid(a193ffdf-eda2-11df-a193-ffdfeda211df)][long(31337)]

drop keyspace Tests
{code}

> Add UUID functions to cli
> -------------------------
>
>                 Key: CASSANDRA-1687
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-1687
>             Project: Cassandra
>          Issue Type: New Feature
>          Components: Tools
>            Reporter: Jonathan Ellis
>            Assignee: Pavel Yaskevich
>            Priority: Minor
>             Fix For: 0.7.0
>
>         Attachments: CASSANDRA-1687-functions-support-for-row-keys.patch, CASSANDRA-1687.patch
>
>
> Add timeuuid and lexicaluuid functions to the cli:
> set timeline[jbellis][timeuuid()] = ...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CASSANDRA-1687) Add UUID functions to cli

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

Jonathan Ellis commented on CASSANDRA-1687:
-------------------------------------------

I'm getting an error on the set, so that's the first problem.

We need to make uuid encoding work correctly; storing as utf8 is not adequate.

> Add UUID functions to cli
> -------------------------
>
>                 Key: CASSANDRA-1687
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-1687
>             Project: Cassandra
>          Issue Type: New Feature
>          Components: Tools
>            Reporter: Jonathan Ellis
>            Assignee: Pavel Yaskevich
>            Priority: Minor
>             Fix For: 0.7.0
>
>         Attachments: CASSANDRA-1687.patch
>
>
> Add timeuuid and lexicaluuid functions to the cli:
> set timeline[jbellis][timeuuid()] = ...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CASSANDRA-1687) Add UUID functions to cli

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

Jonathan Ellis commented on CASSANDRA-1687:
-------------------------------------------

committed, but this does not work:

{code}
set cf2[timeuuid()][asdf] = 1
Syntax error at position 16: mismatched input '(' expecting ']'
{code}

> Add UUID functions to cli
> -------------------------
>
>                 Key: CASSANDRA-1687
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-1687
>             Project: Cassandra
>          Issue Type: New Feature
>          Components: Tools
>            Reporter: Jonathan Ellis
>            Assignee: Pavel Yaskevich
>            Priority: Minor
>             Fix For: 0.7.0
>
>         Attachments: CASSANDRA-1687.patch
>
>
> Add timeuuid and lexicaluuid functions to the cli:
> set timeline[jbellis][timeuuid()] = ...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CASSANDRA-1687) Add UUID functions to cli

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

Pavel Yaskevich commented on CASSANDRA-1687:
--------------------------------------------

Ok, I will submit a patch which adds functions support for row keys in 20 mins.

> Add UUID functions to cli
> -------------------------
>
>                 Key: CASSANDRA-1687
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-1687
>             Project: Cassandra
>          Issue Type: New Feature
>          Components: Tools
>            Reporter: Jonathan Ellis
>            Assignee: Pavel Yaskevich
>            Priority: Minor
>             Fix For: 0.7.0
>
>         Attachments: CASSANDRA-1687.patch
>
>
> Add timeuuid and lexicaluuid functions to the cli:
> set timeline[jbellis][timeuuid()] = ...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CASSANDRA-1687) Add UUID functions to cli

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

Jonathan Ellis commented on CASSANDRA-1687:
-------------------------------------------

committed patch 2.

does this fix the encoding?

> Add UUID functions to cli
> -------------------------
>
>                 Key: CASSANDRA-1687
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-1687
>             Project: Cassandra
>          Issue Type: New Feature
>          Components: Tools
>            Reporter: Jonathan Ellis
>            Assignee: Pavel Yaskevich
>            Priority: Minor
>             Fix For: 0.7.0
>
>         Attachments: CASSANDRA-1687-functions-support-for-row-keys.patch, CASSANDRA-1687.patch
>
>
> Add timeuuid and lexicaluuid functions to the cli:
> set timeline[jbellis][timeuuid()] = ...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CASSANDRA-1687) Add UUID functions to cli

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

Pavel Yaskevich updated CASSANDRA-1687:
---------------------------------------

    Attachment: CASSANDRA-1687.patch

This also fixes a bug from CASSANDRA-1728

Example:
{code}
connect localhost/9160
create keyspace Tests
use Tests

create column family DynamicColumns
set DynamicColumns[1][timeuuid()] = utf8('hello')
set DynamicColumns[2][lexicaluuid()] = utf8('hello world!')
set DynamicColumns[3][lexicaluuid(550e8400-e29b-41d4-a716-446655440000)] = utf8(test)
set DynamicColumns[key2][timeuuid()] = utf8('cassandra')
set DynamicColumns['key 12'][550e8400-e29b-41d4-a716-446655440000] = utf8('hello friendly world')

assume DynamicColumns comparator as lexicaluuid
assume DynamicColumns keys as utf8
list DynamicColumns
get DynamicColumns[3]
get DynamicColumns[3][lexicaluuid(550e8400-e29b-41d4-a716-446655440000)]

drop keyspace Tests
{code}

> Add UUID functions to cli
> -------------------------
>
>                 Key: CASSANDRA-1687
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-1687
>             Project: Cassandra
>          Issue Type: New Feature
>          Components: Tools
>            Reporter: Jonathan Ellis
>            Assignee: Pavel Yaskevich
>            Priority: Minor
>             Fix For: 0.7.0
>
>         Attachments: CASSANDRA-1687.patch
>
>
> Add timeuuid and lexicaluuid functions to the cli:
> set timeline[jbellis][timeuuid()] = ...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CASSANDRA-1687) Add UUID functions to cli

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

Pavel Yaskevich commented on CASSANDRA-1687:
--------------------------------------------

I tried to do a "GET"s and they all succeeded, "LIST" are working also, so the problem could be only local to me...

> Add UUID functions to cli
> -------------------------
>
>                 Key: CASSANDRA-1687
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-1687
>             Project: Cassandra
>          Issue Type: New Feature
>          Components: Tools
>            Reporter: Jonathan Ellis
>            Assignee: Pavel Yaskevich
>            Priority: Minor
>             Fix For: 0.7.0
>
>         Attachments: CASSANDRA-1687-functions-support-for-row-keys.patch, CASSANDRA-1687.patch
>
>
> Add timeuuid and lexicaluuid functions to the cli:
> set timeline[jbellis][timeuuid()] = ...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CASSANDRA-1687) Add UUID functions to cli

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

Pavel Yaskevich commented on CASSANDRA-1687:
--------------------------------------------

Yes, I know that... I discovered an issue with thrift for row keys - if you save a row key as different then utf8 type get does not work some how, but "limit" shows that there is a key and it is properly encoded. I did following:

{code}
set Users[lexicaluuid()][name] = 'pavel'
get Users[lexicaluuid(<generated-uuid-here>)] 
{code}

and got 0 results.

I think we can still support timeuuid() and lexicaluuid() functions as row keys but they should be stored as utf8?...

> Add UUID functions to cli
> -------------------------
>
>                 Key: CASSANDRA-1687
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-1687
>             Project: Cassandra
>          Issue Type: New Feature
>          Components: Tools
>            Reporter: Jonathan Ellis
>            Assignee: Pavel Yaskevich
>            Priority: Minor
>             Fix For: 0.7.0
>
>         Attachments: CASSANDRA-1687.patch
>
>
> Add timeuuid and lexicaluuid functions to the cli:
> set timeline[jbellis][timeuuid()] = ...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CASSANDRA-1687) Add UUID functions to cli

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

Jonathan Ellis updated CASSANDRA-1687:
--------------------------------------

    Fix Version/s:     (was: 0.7.1)
                   0.7.0

> Add UUID functions to cli
> -------------------------
>
>                 Key: CASSANDRA-1687
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-1687
>             Project: Cassandra
>          Issue Type: New Feature
>          Components: Tools
>            Reporter: Jonathan Ellis
>            Assignee: Pavel Yaskevich
>            Priority: Minor
>             Fix For: 0.7.0
>
>
> Add timeuuid and lexicaluuid functions to the cli:
> set timeline[jbellis][timeuuid()] = ...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.