You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Sylvain Lebresne (JIRA)" <ji...@apache.org> on 2011/07/27 11:00:11 UTC

[jira] [Created] (CASSANDRA-2953) Use lazy initialization instead of class initialization in NodeId

Use lazy initialization instead of class initialization in NodeId
-----------------------------------------------------------------

                 Key: CASSANDRA-2953
                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2953
             Project: Cassandra
          Issue Type: Improvement
          Components: Core
    Affects Versions: 0.8.0
            Reporter: Sylvain Lebresne
            Assignee: Sylvain Lebresne
            Priority: Trivial
             Fix For: 0.8.3
         Attachments: 0001-Use-lazy-initialization-for-NodeId.patch

The class initialization of NodeId triggers a read to a system table. When using the class introduced in CASSANDRA-2911, this happens to be triggered even though this is not necessary. This a a pain because when you use those classes, you don't have to have to set reasonable values for the data_dir and commitlog_dir in cassandra.yaml (it is a pain to have to have a cassandra.yaml in the classpath in the first place, but that's for another ticket).

This ticket proposes using lazy initialization in NodeId to avoid that.

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

        

[jira] [Commented] (CASSANDRA-2953) Use lazy initialization instead of class initialization in NodeId

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

Jonathan Ellis commented on CASSANDRA-2953:
-------------------------------------------

+1

> Use lazy initialization instead of class initialization in NodeId
> -----------------------------------------------------------------
>
>                 Key: CASSANDRA-2953
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2953
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: Core
>    Affects Versions: 0.8.0
>            Reporter: Sylvain Lebresne
>            Assignee: Sylvain Lebresne
>            Priority: Trivial
>             Fix For: 0.8.3
>
>         Attachments: 0001-Use-lazy-initialization-for-NodeId.patch
>
>
> The class initialization of NodeId triggers a read to a system table. When using the class introduced in CASSANDRA-2911, this happens to be triggered even though this is not necessary. This a a pain because when you use those classes, you don't have to have to set reasonable values for the data_dir and commitlog_dir in cassandra.yaml (it is a pain to have to have a cassandra.yaml in the classpath in the first place, but that's for another ticket).
> This ticket proposes using lazy initialization in NodeId to avoid that.

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

        

[jira] [Updated] (CASSANDRA-2953) Use lazy initialization instead of class initialization in NodeId

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

Sylvain Lebresne updated CASSANDRA-2953:
----------------------------------------

    Attachment: 0001-Use-lazy-initialization-for-NodeId.patch

> Use lazy initialization instead of class initialization in NodeId
> -----------------------------------------------------------------
>
>                 Key: CASSANDRA-2953
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2953
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: Core
>    Affects Versions: 0.8.0
>            Reporter: Sylvain Lebresne
>            Assignee: Sylvain Lebresne
>            Priority: Trivial
>             Fix For: 0.8.3
>
>         Attachments: 0001-Use-lazy-initialization-for-NodeId.patch
>
>
> The class initialization of NodeId triggers a read to a system table. When using the class introduced in CASSANDRA-2911, this happens to be triggered even though this is not necessary. This a a pain because when you use those classes, you don't have to have to set reasonable values for the data_dir and commitlog_dir in cassandra.yaml (it is a pain to have to have a cassandra.yaml in the classpath in the first place, but that's for another ticket).
> This ticket proposes using lazy initialization in NodeId to avoid that.

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

        

[jira] [Commented] (CASSANDRA-2953) Use lazy initialization instead of class initialization in NodeId

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

Hudson commented on CASSANDRA-2953:
-----------------------------------

Integrated in Cassandra-0.8 #240 (See [https://builds.apache.org/job/Cassandra-0.8/240/])
    Use lazy initialization instead of class initialization in NodeId
patch by slebresne; reviewed by jbellis for CASSANDRA-2953

slebresne : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1151495
Files : 
* /cassandra/branches/cassandra-0.8/CHANGES.txt
* /cassandra/branches/cassandra-0.8/src/java/org/apache/cassandra/utils/NodeId.java


> Use lazy initialization instead of class initialization in NodeId
> -----------------------------------------------------------------
>
>                 Key: CASSANDRA-2953
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2953
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: Core
>    Affects Versions: 0.8.0
>            Reporter: Sylvain Lebresne
>            Assignee: Sylvain Lebresne
>            Priority: Trivial
>             Fix For: 0.8.3
>
>         Attachments: 0001-Use-lazy-initialization-for-NodeId.patch
>
>
> The class initialization of NodeId triggers a read to a system table. When using the class introduced in CASSANDRA-2911, this happens to be triggered even though this is not necessary. This a a pain because when you use those classes, you don't have to have to set reasonable values for the data_dir and commitlog_dir in cassandra.yaml (it is a pain to have to have a cassandra.yaml in the classpath in the first place, but that's for another ticket).
> This ticket proposes using lazy initialization in NodeId to avoid that.

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