You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Nick Bailey (JIRA)" <ji...@apache.org> on 2011/06/21 22:47:47 UTC

[jira] [Created] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

Clean up mbeans that return Internal Cassandra types
----------------------------------------------------

                 Key: CASSANDRA-2805
                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
             Project: Cassandra
          Issue Type: Bug
    Affects Versions: 0.8.1
            Reporter: Nick Bailey
            Priority: Minor
             Fix For: 0.8.2


We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.

This is bad for two reasons

1. You have to load the cassandra jar when querying these mbeans, which sucks.
2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.1.

For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.

I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

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

        

[jira] [Assigned] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Nick Bailey reassigned CASSANDRA-2805:
--------------------------------------

    Assignee: Nick Bailey  (was: Gaurav Sharma)
    
> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Assignee: Nick Bailey
>            Priority: Minor
>              Labels: lhf
>             Fix For: 1.1
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Edward Capriolo commented on CASSANDRA-2805:
--------------------------------------------

Maybe the JMX CompositeType could be returned instead of JSON? 

> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Priority: Minor
>              Labels: lhf
>             Fix For: 0.8.2
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

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

        

[jira] [Assigned] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Nick Bailey reassigned CASSANDRA-2805:
--------------------------------------

    Assignee: Nick Bailey

> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Assignee: Nick Bailey
>            Priority: Minor
>             Fix For: 0.8.2
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

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

        

[jira] [Issue Comment Edited] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

Posted by "Nick Bailey (Issue Comment Edited) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CASSANDRA-2805?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13177757#comment-13177757 ] 

Nick Bailey edited comment on CASSANDRA-2805 at 12/30/11 9:06 PM:
------------------------------------------------------------------

Alright removed the double brace :(, and updated to use static toString.
                
      was (Author: nickmbailey):
    Alright removed the double brace :(, and updated to use stat toString.
                  
> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Assignee: Nick Bailey
>            Priority: Minor
>              Labels: lhf
>             Fix For: 1.1
>
>         Attachments: 0001-Don-t-return-internal-types-over-jmx.patch, 0001-Don-t-return-internal-types-over-jmx.patch
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Nick Bailey commented on CASSANDRA-2805:
----------------------------------------

Didn't know that existed. I guess it is specifically designed to address this kind of problem?

A quick look makes it seem overly complicated and verbose. If we want to avoid json we can still allow for more complicated types like Map<String> and whatnot. The main problem is just having to include the cassandra jar when querying jmx. From what I can tell it's basically impossible to do jmx-type stuff on a non-jvm language anyway, so maybe we don't really need json.

> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Priority: Minor
>              Labels: lhf
>             Fix For: 0.8.2
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

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

        

[jira] [Assigned] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Jonathan Ellis reassigned CASSANDRA-2805:
-----------------------------------------

    Assignee: Gaurav Sharma

> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Assignee: Gaurav Sharma
>            Priority: Minor
>              Labels: lhf
>             Fix For: 0.8.2
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

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

        

[jira] [Commented] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Gaurav Sharma commented on CASSANDRA-2805:
------------------------------------------

Unless someone else has already started, I am planning to take this one up.

> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Priority: Minor
>              Labels: lhf
>             Fix For: 0.8.2
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

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

        

[jira] [Commented] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Jonathan Ellis commented on CASSANDRA-2805:
-------------------------------------------

I don't think we should break compatibility in a minor release.
                
> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Assignee: Gaurav Sharma
>            Priority: Minor
>              Labels: lhf
>             Fix For: 1.1
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Gaurav Sharma commented on CASSANDRA-2805:
------------------------------------------

Based on my research so far scanning the MBean's and their internal users (NodeProbe, NodeCmd and CliClient), there are 4 Cassandra-type dependencies: CompactionInfo, CompactionType, Token, Range. Addressing them individually and discussing my plan:

1. CompactionInfo/CompactionType
Now, CompactionInfo/CompactionType are manageable with a Map as suggested but Range and Token are a bit tightly coupled and more involved.

2. Range
Since Range already has the partitioner (either injected or implicit from StorageService), I believe I can add 2 new constructors that look like:
    public Range(String left, String right)
    public Range(String left, String right, IPartitioner partitioner)

and use the partioner.getTokenFactory().fromString() to curate the left and right Token's.

Also, to replace the StorageServiceMBean's:
    public Map<Range, List<String>> getRangeToEndpointMap(String keyspace);
    public Map<Range, List<String>> getPendingRangeToEndpointMap(String keyspace);

based on their usages, the Range in StorageService can be safely copied to something like a Pair/Tuple.

I noticed that the getRangeToAddressMap() is not exposed on the StorageServiceMBean interface - is that by design (not that I am complaining because right now, it is 1 less dependency to decouple but if it is an omission, I need to account for it)?

3. Token
I can change all MBean interfaces that need a Token to the corresponding String representation using partitioner.getTokenFactory().toString() and then reconstruct back using the fromString()

> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Assignee: Gaurav Sharma
>            Priority: Minor
>              Labels: lhf
>             Fix For: 0.8.2
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

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

        

[jira] [Commented] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Yuki Morishita commented on CASSANDRA-2805:
-------------------------------------------

+1
                
> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Assignee: Nick Bailey
>            Priority: Minor
>              Labels: lhf
>             Fix For: 1.1
>
>         Attachments: 0001-Don-t-return-internal-types-over-jmx.patch, 0001-Don-t-return-internal-types-over-jmx.patch
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Yuki Morishita updated CASSANDRA-2805:
--------------------------------------

    Reviewer: yukim
    
> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Assignee: Nick Bailey
>            Priority: Minor
>              Labels: lhf
>             Fix For: 1.1
>
>         Attachments: 0001-Don-t-return-internal-types-over-jmx.patch
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Nick Bailey commented on CASSANDRA-2805:
----------------------------------------

Obviously I didn't get this done before the 1.0 freeze. And of course, this breaks between 0.8 and 1.0 since the serial version of CompactionInfo changes.

Can we target this for 1.0.1?
                
> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Assignee: Gaurav Sharma
>            Priority: Minor
>              Labels: lhf
>             Fix For: 1.1
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Jonathan Ellis updated CASSANDRA-2805:
--------------------------------------

    Assignee:     (was: Nick Bailey)
      Labels: lhf  (was: )

> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Priority: Minor
>              Labels: lhf
>             Fix For: 0.8.2
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

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

        

[jira] [Commented] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Edward Capriolo commented on CASSANDRA-2805:
--------------------------------------------

CompositeData is a JMX type that holds a key value map of other JMX types and can be nested. 

http://docs.jboss.org/jbossas/javadoc/4.0.1-sp1/jmx/javax/management/openmbean/CompositeDataSupport.html

This should allows us to return complex objects over JMX without having to resort to JSON serializing things.


> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Priority: Minor
>              Labels: lhf
>             Fix For: 0.8.2
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

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

        

[jira] [Commented] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Nick Bailey commented on CASSANDRA-2805:
----------------------------------------

Ed,

I'm not sure I see the advantage of a JMX Composite type as opposed to using something like a Map<String, Int> approach in any place that needs 'complex' types. 

> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Assignee: Gaurav Sharma
>            Priority: Minor
>              Labels: lhf
>             Fix For: 0.8.2
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

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

        

[jira] [Commented] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Nick Bailey commented on CASSANDRA-2805:
----------------------------------------

I'm probably going to take this and try and get it done quickly before the 1.0 freeze. I'd really like to solve this problem before 1.0 and then be strict on preventing this in future mbean methods.

> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Assignee: Gaurav Sharma
>            Priority: Minor
>              Labels: lhf
>             Fix For: 1.0
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

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

        

[jira] [Commented] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Jonathan Ellis commented on CASSANDRA-2805:
-------------------------------------------

If you can list which methods to clean up, this would be a good ticket for the surprisingly frequently asked, "What's a good place to get my feet wet in the Cassandra code?"

> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Assignee: Nick Bailey
>            Priority: Minor
>             Fix For: 0.8.2
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

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

        

[jira] [Updated] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Nick Bailey updated CASSANDRA-2805:
-----------------------------------

    Attachment: 0001-Don-t-return-internal-types-over-jmx.patch

Alright removed the double brace :(, and updated to use stat toString.
                
> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Assignee: Nick Bailey
>            Priority: Minor
>              Labels: lhf
>             Fix For: 1.1
>
>         Attachments: 0001-Don-t-return-internal-types-over-jmx.patch, 0001-Don-t-return-internal-types-over-jmx.patch
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Yuki Morishita commented on CASSANDRA-2805:
-------------------------------------------

Nick,

- I think double brace initialization should be avoided at CompactionInfo#asMap. (yeah, I know Java syntax is sucks.)
- I prefer {{Integer/Long.toString(val)}} over {{new Integer/Long(val).toString()}}.

but, otherwise +1.
                
> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Assignee: Nick Bailey
>            Priority: Minor
>              Labels: lhf
>             Fix For: 1.1
>
>         Attachments: 0001-Don-t-return-internal-types-over-jmx.patch
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Nick Bailey updated CASSANDRA-2805:
-----------------------------------

    Attachment: 0001-Don-t-return-internal-types-over-jmx.patch

Should take care of any instances where internal types are returned over jmx.
                
> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Assignee: Nick Bailey
>            Priority: Minor
>              Labels: lhf
>             Fix For: 1.1
>
>         Attachments: 0001-Don-t-return-internal-types-over-jmx.patch
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Nick Bailey commented on CASSANDRA-2805:
----------------------------------------

I agree my main argument though is that we have a history of doing it unknowingly. Especially something like this where any update the the CompactionInfo requires updating the serialization version and then breaks compatibility.

I suppose I can live with this in 1.1 and a 'let's try really really really hard not to break compatibility in the 1.0.x releases.
                
> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Assignee: Gaurav Sharma
>            Priority: Minor
>              Labels: lhf
>             Fix For: 1.1
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Jonathan Ellis commented on CASSANDRA-2805:
-------------------------------------------

Guarav, are you still working on this?

> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Assignee: Gaurav Sharma
>            Priority: Minor
>              Labels: lhf
>             Fix For: 0.8.5
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

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

        

[jira] [Commented] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Nick Bailey commented on CASSANDRA-2805:
----------------------------------------

I'm not sure you need to add any constructors to Range. How about just an asPair() method or something similar that returns the tokens that make up the range converted to strings?

Everything else looks fine. getRangeToAddressMap() isn't needed because getRangeToEndpointMap() is exposed.

Another thing that might be nice to fix here is the getNaturalEndpoints() method. It currently only takes a byte array or byteBuffer object which makes it impossible to call from something like jconsole. It would be nice to overload that with another method that takes a string as the key so you can call it from jconsole.

> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Assignee: Gaurav Sharma
>            Priority: Minor
>              Labels: lhf
>             Fix For: 0.8.2
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

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

        

[jira] [Commented] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Nick Bailey commented on CASSANDRA-2805:
----------------------------------------

Off the top of my head:

 * A CompactionInfo object is returned when getting compactions from the CompactionManager mbean.
 * Sub-types of Token objects are returned when calling getTokenToEndpointMap (StorageService mbean i think).

I'll see if i can't look around for any more.

> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Assignee: Nick Bailey
>            Priority: Minor
>             Fix For: 0.8.2
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

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

        

[jira] [Updated] (CASSANDRA-2805) Clean up mbeans that return Internal Cassandra types

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

Nick Bailey updated CASSANDRA-2805:
-----------------------------------

    Description: 
We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.

This is bad for two reasons

1. You have to load the cassandra jar when querying these mbeans, which sucks.
2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)

For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.

I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

  was:
We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.

This is bad for two reasons

1. You have to load the cassandra jar when querying these mbeans, which sucks.
2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.1.

For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.

I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.


> Clean up mbeans that return Internal Cassandra types
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2805
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2805
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 0.8.1
>            Reporter: Nick Bailey
>            Priority: Minor
>             Fix For: 0.8.2
>
>
> We need to clean up wherever we return internal cassandra objects over jmx. Namely CompactionInfo objects as well as Tokens. There may be a few other examples.
> This is bad for two reasons
> 1. You have to load the cassandra jar when querying these mbeans, which sucks.
> 2. Stuff breaks between versions when things are moved. For example, CASSANDRA-1610 moves the compaction related classes around. Any code querying those jmx mbeans in 0.8.0 is now broken in 0.8.2. (assuming those moves stay in the 0.8 branch)
> For things like CompactionInfo we should just expose more mbean methods or serialize to something standard like json.
> I'd like to target this for 0.8.2. Since we've already broken compatibility between 0.8.0 and 0.8.1, I'd say just fix this everywhere now.

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