You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Vijay (JIRA)" <ji...@apache.org> on 2012/09/25 08:07:07 UTC

[jira] [Created] (CASSANDRA-4713) -ve Token with M3P

Vijay created CASSANDRA-4713:
--------------------------------

             Summary: -ve Token with M3P
                 Key: CASSANDRA-4713
                 URL: https://issues.apache.org/jira/browse/CASSANDRA-4713
             Project: Cassandra
          Issue Type: Bug
          Components: Core
    Affects Versions: 1.2.0 beta 1
            Reporter: Vijay
            Assignee: Vijay
             Fix For: 1.2.0


Looks like CASSANDRA-4621 has the following code

{code}
-        return new LongToken((hash < 0) ? -hash : hash);
+        return new LongToken(normalize(hash));
     }

+    private long normalize(long v)
+    {
+        // We exclude the MINIMUM value; see getToken()
+        return v == Long.MIN_VALUE ? Long.MAX_VALUE : v;
     }
{code}

Causing the following error during bulk loading...

SSTable first key DecoratedKey(38876769351598, 30393932373730) > last key DecoratedKey(-9223087809888494735, 30393936393438)


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (CASSANDRA-4713) -ve Token with M3P

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

Vijay updated CASSANDRA-4713:
-----------------------------

    Reviewer: slebresne
    
> -ve Token with M3P
> ------------------
>
>                 Key: CASSANDRA-4713
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-4713
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 1.2.0 beta 1
>            Reporter: Vijay
>            Assignee: Vijay
>             Fix For: 1.2.0
>
>         Attachments: 0001-CASSANDRA-4713.patch
>
>
> Looks like CASSANDRA-4621 has the following code
> {code}
> -        return new LongToken((hash < 0) ? -hash : hash);
> +        return new LongToken(normalize(hash));
>      }
> +    private long normalize(long v)
> +    {
> +        // We exclude the MINIMUM value; see getToken()
> +        return v == Long.MIN_VALUE ? Long.MAX_VALUE : v;
>      }
> {code}
> Causing the following error during bulk loading...
> SSTable first key DecoratedKey(38876769351598, 30393932373730) > last key DecoratedKey(-9223087809888494735, 30393936393438)

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (CASSANDRA-4713) -ve Token with M3P

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

Sylvain Lebresne commented on CASSANDRA-4713:
---------------------------------------------

bq. You will see the issue.

Actually, I haven't been able to reproduce the issue on current trunk so far. For 1) I've tried running stress with 1M keys, 10M keys and with both size tiered and leveled compaction, but then each time I was able to bulk-load the created sstables without any error.

Is that something you trigger every time? And if so, are you sure that when running the sstableloader script it doesn't end up picking some older than 1.2.0-beta1 version installed on your system?
                
> -ve Token with M3P
> ------------------
>
>                 Key: CASSANDRA-4713
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-4713
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 1.2.0 beta 1
>            Reporter: Vijay
>            Assignee: Vijay
>             Fix For: 1.2.0
>
>         Attachments: 0001-CASSANDRA-4713.patch
>
>
> Looks like CASSANDRA-4621 has the following code
> {code}
> -        return new LongToken((hash < 0) ? -hash : hash);
> +        return new LongToken(normalize(hash));
>      }
> +    private long normalize(long v)
> +    {
> +        // We exclude the MINIMUM value; see getToken()
> +        return v == Long.MIN_VALUE ? Long.MAX_VALUE : v;
>      }
> {code}
> Causing the following error during bulk loading...
> SSTable first key DecoratedKey(38876769351598, 30393932373730) > last key DecoratedKey(-9223087809888494735, 30393936393438)

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (CASSANDRA-4713) negative Token with M3P

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

Brandon Williams updated CASSANDRA-4713:
----------------------------------------

    Summary: negative Token with M3P  (was: -ve Token with M3P)
    
> negative Token with M3P
> -----------------------
>
>                 Key: CASSANDRA-4713
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-4713
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 1.2.0 beta 1
>            Reporter: Vijay
>            Assignee: Vijay
>             Fix For: 1.2.0
>
>         Attachments: 0001-CASSANDRA-4713.patch
>
>
> Looks like CASSANDRA-4621 has the following code
> {code}
> -        return new LongToken((hash < 0) ? -hash : hash);
> +        return new LongToken(normalize(hash));
>      }
> +    private long normalize(long v)
> +    {
> +        // We exclude the MINIMUM value; see getToken()
> +        return v == Long.MIN_VALUE ? Long.MAX_VALUE : v;
>      }
> {code}
> Causing the following error during bulk loading...
> SSTable first key DecoratedKey(38876769351598, 30393932373730) > last key DecoratedKey(-9223087809888494735, 30393936393438)

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (CASSANDRA-4713) -ve Token with M3P

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

Vijay commented on CASSANDRA-4713:
----------------------------------

Yes the error starts popping up after 0ea28c858e3f693dc44d38cd4306e02049d01ce8

It is simple to reproduce:
1) Use stress to add data to a single node cluster
2) run ./apache-cassandra-1.2.0-beta1-SNAPSHOT/bin/sstableloader -d 127.0.0.1 /var/lib/cassandra/data/Keyspace1/Standard1/

You will see the issue. after this patch or before 0ea28c858e3f693dc44d38cd4306e02049d01ce8 the issue didn't appear.
                
> -ve Token with M3P
> ------------------
>
>                 Key: CASSANDRA-4713
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-4713
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 1.2.0 beta 1
>            Reporter: Vijay
>            Assignee: Vijay
>             Fix For: 1.2.0
>
>         Attachments: 0001-CASSANDRA-4713.patch
>
>
> Looks like CASSANDRA-4621 has the following code
> {code}
> -        return new LongToken((hash < 0) ? -hash : hash);
> +        return new LongToken(normalize(hash));
>      }
> +    private long normalize(long v)
> +    {
> +        // We exclude the MINIMUM value; see getToken()
> +        return v == Long.MIN_VALUE ? Long.MAX_VALUE : v;
>      }
> {code}
> Causing the following error during bulk loading...
> SSTable first key DecoratedKey(38876769351598, 30393932373730) > last key DecoratedKey(-9223087809888494735, 30393936393438)

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (CASSANDRA-4713) -ve Token with M3P

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

Sylvain Lebresne commented on CASSANDRA-4713:
---------------------------------------------

Having negative tokens was made on purpose. Are you sure you got that error on a version having the commit 0ea28c858e3f693dc44d38cd4306e02049d01ce8?
                
> -ve Token with M3P
> ------------------
>
>                 Key: CASSANDRA-4713
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-4713
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 1.2.0 beta 1
>            Reporter: Vijay
>            Assignee: Vijay
>             Fix For: 1.2.0
>
>         Attachments: 0001-CASSANDRA-4713.patch
>
>
> Looks like CASSANDRA-4621 has the following code
> {code}
> -        return new LongToken((hash < 0) ? -hash : hash);
> +        return new LongToken(normalize(hash));
>      }
> +    private long normalize(long v)
> +    {
> +        // We exclude the MINIMUM value; see getToken()
> +        return v == Long.MIN_VALUE ? Long.MAX_VALUE : v;
>      }
> {code}
> Causing the following error during bulk loading...
> SSTable first key DecoratedKey(38876769351598, 30393932373730) > last key DecoratedKey(-9223087809888494735, 30393936393438)

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (CASSANDRA-4713) -ve Token with M3P

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

Vijay updated CASSANDRA-4713:
-----------------------------

    Attachment: 0001-CASSANDRA-4713.patch

Adding back the removed check, (hash < 0) ? -hash : hash)
                
> -ve Token with M3P
> ------------------
>
>                 Key: CASSANDRA-4713
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-4713
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 1.2.0 beta 1
>            Reporter: Vijay
>            Assignee: Vijay
>             Fix For: 1.2.0
>
>         Attachments: 0001-CASSANDRA-4713.patch
>
>
> Looks like CASSANDRA-4621 has the following code
> {code}
> -        return new LongToken((hash < 0) ? -hash : hash);
> +        return new LongToken(normalize(hash));
>      }
> +    private long normalize(long v)
> +    {
> +        // We exclude the MINIMUM value; see getToken()
> +        return v == Long.MIN_VALUE ? Long.MAX_VALUE : v;
>      }
> {code}
> Causing the following error during bulk loading...
> SSTable first key DecoratedKey(38876769351598, 30393932373730) > last key DecoratedKey(-9223087809888494735, 30393936393438)

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (CASSANDRA-4713) -ve Token with M3P

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

Vijay updated CASSANDRA-4713:
-----------------------------

    Attachment:     (was: 0001-CASSANDRA-4713.patch)
    
> -ve Token with M3P
> ------------------
>
>                 Key: CASSANDRA-4713
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-4713
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 1.2.0 beta 1
>            Reporter: Vijay
>            Assignee: Vijay
>             Fix For: 1.2.0
>
>         Attachments: 0001-CASSANDRA-4713.patch
>
>
> Looks like CASSANDRA-4621 has the following code
> {code}
> -        return new LongToken((hash < 0) ? -hash : hash);
> +        return new LongToken(normalize(hash));
>      }
> +    private long normalize(long v)
> +    {
> +        // We exclude the MINIMUM value; see getToken()
> +        return v == Long.MIN_VALUE ? Long.MAX_VALUE : v;
>      }
> {code}
> Causing the following error during bulk loading...
> SSTable first key DecoratedKey(38876769351598, 30393932373730) > last key DecoratedKey(-9223087809888494735, 30393936393438)

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (CASSANDRA-4713) -ve Token with M3P

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

Vijay updated CASSANDRA-4713:
-----------------------------

    Attachment: 0001-CASSANDRA-4713.patch

Actually fixing the normalizing based of +ve values.
                
> -ve Token with M3P
> ------------------
>
>                 Key: CASSANDRA-4713
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-4713
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 1.2.0 beta 1
>            Reporter: Vijay
>            Assignee: Vijay
>             Fix For: 1.2.0
>
>         Attachments: 0001-CASSANDRA-4713.patch
>
>
> Looks like CASSANDRA-4621 has the following code
> {code}
> -        return new LongToken((hash < 0) ? -hash : hash);
> +        return new LongToken(normalize(hash));
>      }
> +    private long normalize(long v)
> +    {
> +        // We exclude the MINIMUM value; see getToken()
> +        return v == Long.MIN_VALUE ? Long.MAX_VALUE : v;
>      }
> {code}
> Causing the following error during bulk loading...
> SSTable first key DecoratedKey(38876769351598, 30393932373730) > last key DecoratedKey(-9223087809888494735, 30393936393438)

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira