You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Peter Schuller (Created) (JIRA)" <ji...@apache.org> on 2012/01/12 01:56:40 UTC

[jira] [Created] (CASSANDRA-3729) support counter debug mode on thrift interface

support counter debug mode on thrift interface
----------------------------------------------

                 Key: CASSANDRA-3729
                 URL: https://issues.apache.org/jira/browse/CASSANDRA-3729
             Project: Cassandra
          Issue Type: Improvement
            Reporter: Peter Schuller
            Assignee: Peter Schuller
            Priority: Minor
         Attachments: trunk-3729.txt

Attaching a patch against trunk to add a counter debug mode on the thrift interface, allowing clients to decode and inspect counter contexts. This is all Stu's code, except that I generated the thrift stuff so any mistakes there are mine.

This was extremely useful internally on an 0.8. The patch is not yet tested on trunk, but if you think this can go in I will spend effort to test it soonish.

It's not very invasive (other than the generated thrift code), so it feels okay to have it if we maybe document that it is not a supported interface (clearly in the thrift spec).

--
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-3729) support counter debug mode on thrift interface

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

Sylvain Lebresne commented on CASSANDRA-3729:
---------------------------------------------

bq. Just to be clear, it's a per-client setting

I missed that, sorry. It does is better than a JMX setting then.

bq. Suppose we create a developer-only service that extends the public service?

I suppose some form of debug console (which could take the form of a separate thrift service + some debug shell to connect to it) wouldn't be a crazy idea if it's clearly separated from the public API. Feels like a bit of work for just getting counter contexts, but maybe we can find other uses for it (for instance, we could disable access to the system keyspace from the public API, but enable it from the debug "console").
                
> support counter debug mode on thrift interface
> ----------------------------------------------
>
>                 Key: CASSANDRA-3729
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-3729
>             Project: Cassandra
>          Issue Type: Improvement
>            Reporter: Peter Schuller
>            Assignee: Peter Schuller
>            Priority: Minor
>         Attachments: trunk-3729.txt
>
>
> Attaching a patch against trunk to add a counter debug mode on the thrift interface, allowing clients to decode and inspect counter contexts. This is all Stu's code, except that I generated the thrift stuff so any mistakes there are mine.
> This was extremely useful internally on an 0.8. The patch is not yet tested on trunk, but if you think this can go in I will spend effort to test it soonish.
> It's not very invasive (other than the generated thrift code), so it feels okay to have it if we maybe document that it is not a supported interface (clearly in the thrift spec).

--
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-3729) support counter debug mode on thrift interface

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

Sylvain Lebresne commented on CASSANDRA-3729:
---------------------------------------------

I think the thrift interface is too user visible for something like this. Maybe a JMX method (in some debug MBean) would be less of a problem.

That being said, it's not really something we can ask people to turn on to help troubleshooting a problem they would have with counters as it would break counter reads. Logging contexts at debug in the log (which we more or less do, though maybe we can improve it a bit) seems more useful for that.

And if it's really just for the 4 of us developers working on counters, we can recompile the code with 1 line commented to get the same behavior if we so wish. So not sure I feel it's worth taking the chance that someone hit that trigger in production by accident.
                
> support counter debug mode on thrift interface
> ----------------------------------------------
>
>                 Key: CASSANDRA-3729
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-3729
>             Project: Cassandra
>          Issue Type: Improvement
>            Reporter: Peter Schuller
>            Assignee: Peter Schuller
>            Priority: Minor
>         Attachments: trunk-3729.txt
>
>
> Attaching a patch against trunk to add a counter debug mode on the thrift interface, allowing clients to decode and inspect counter contexts. This is all Stu's code, except that I generated the thrift stuff so any mistakes there are mine.
> This was extremely useful internally on an 0.8. The patch is not yet tested on trunk, but if you think this can go in I will spend effort to test it soonish.
> It's not very invasive (other than the generated thrift code), so it feels okay to have it if we maybe document that it is not a supported interface (clearly in the thrift spec).

--
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-3729) support counter debug mode on thrift interface

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

Peter Schuller updated CASSANDRA-3729:
--------------------------------------

    Attachment: trunk-3729.txt
    
> support counter debug mode on thrift interface
> ----------------------------------------------
>
>                 Key: CASSANDRA-3729
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-3729
>             Project: Cassandra
>          Issue Type: Improvement
>            Reporter: Peter Schuller
>            Assignee: Peter Schuller
>            Priority: Minor
>         Attachments: trunk-3729.txt
>
>
> Attaching a patch against trunk to add a counter debug mode on the thrift interface, allowing clients to decode and inspect counter contexts. This is all Stu's code, except that I generated the thrift stuff so any mistakes there are mine.
> This was extremely useful internally on an 0.8. The patch is not yet tested on trunk, but if you think this can go in I will spend effort to test it soonish.
> It's not very invasive (other than the generated thrift code), so it feels okay to have it if we maybe document that it is not a supported interface (clearly in the thrift spec).

--
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-3729) support counter debug mode on thrift interface

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

Peter Schuller commented on CASSANDRA-3729:
-------------------------------------------

Just to be clear, it's a per-client setting whether or not the counters are returned un-encoded or not. So one of the nice features is that you can take a running Cassandra instance (e.g. in production) and connect your client to it, enable debug mode *for your connection*, and inspect.

Before this I was doing sstable2json to filter out the key I wanted so I could iterate quickly, and then continuously rebuilding Cassandra with increasing amounts of debug loggings enabled. Doable, but it was very nice to have this ;)

A JMX setting sounds like it would be global. The reason to put it at the thrift level to begin with is that it's per-connection.

How about this: Suppose we create a developer-only service that extends the public service? Everything built using the public interface would not even be aware additional calls exist. Hmm. Or just have a separate thrift service with debug/dev-only calls, with e.g., a get_counter_context() or something like that.

I dunno. I understand the reluctance to dirty the public interface, yet this was so very useful.

                
> support counter debug mode on thrift interface
> ----------------------------------------------
>
>                 Key: CASSANDRA-3729
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-3729
>             Project: Cassandra
>          Issue Type: Improvement
>            Reporter: Peter Schuller
>            Assignee: Peter Schuller
>            Priority: Minor
>         Attachments: trunk-3729.txt
>
>
> Attaching a patch against trunk to add a counter debug mode on the thrift interface, allowing clients to decode and inspect counter contexts. This is all Stu's code, except that I generated the thrift stuff so any mistakes there are mine.
> This was extremely useful internally on an 0.8. The patch is not yet tested on trunk, but if you think this can go in I will spend effort to test it soonish.
> It's not very invasive (other than the generated thrift code), so it feels okay to have it if we maybe document that it is not a supported interface (clearly in the thrift spec).

--
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