[
https://issues.apache.org/jira/browse/HBASE-4117?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13085855#comment-13085855
]
stack commented on HBASE-4117:
------------------------------
How is jettison related to jackson, the json lib we use elsewhere in hbase? It
throws events as it trips over the json. Can jackson do this?
The clause under 'if (processingTime > warnResponseTime) {' could be broken
out into a method?
Should the above test include if logging is DEBUG or more or is thought that
this slow logging will be always on?
You don't want to log something here:
{code}
+ } catch (JSONException e) {
+ // ignore
+ }
{code}
Could be confusing if I'm expecting logging and its not coming out -- would
appreciate the failure being logged. There is another instance later in this
code block.
Would 'Operation' be better than 'DatabaseCommand'? Currently this superclass
factors into a superclass various kinds of representations of hbase operations
-- tostring, fingerprint as map, json -- etc. Thats fine for now. It could do
more with time.
I like this getFingerprint.
getDetails seems too generic a name for the method. If you are going to go
generic, toMap to go with toString might be better? (Oh, nvm, I see you went
one better and made the toString member of the superclass -- good).
Are you removing toString from Delete? Thats probably not good. The toString
could use your fingerprinting.
Shouldn't the methods in Row be added to your new base class? Row Interface
should only have 'row' things in it, not getDetails and getFamilyMap.
A couple of tests would be good where you do some toStringing and toJSON'ing
and verify its doing right thing.
Nice patch Riley. Nice functionality.
> Slow Query Log
> --------------
>
> Key: HBASE-4117
> URL: https://issues.apache.org/jira/browse/HBASE-4117
> Project: HBase
> Issue Type: New Feature
> Components: ipc
> Reporter: Riley Patterson
> Assignee: Riley Patterson
> Priority: Minor
> Labels: client, ipc
> Attachments: HBASE-4117.patch
>
>
> Produce log messages for slow queries. The RPC server will decide what is
> slow based on a configurable "warn response time" parameter. Queries
> designated as slow will then output a "response too slow" message followed by
> a fingerprint of the query, and a summary limited in size by another
> configurable parameter (to limit log spamming).
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira