[ 
https://issues.apache.org/jira/browse/METRON-1005?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16086417#comment-16086417
 ] 

ASF GitHub Bot commented on METRON-1005:
----------------------------------------

Github user nickwallen commented on a diff in the pull request:

    https://github.com/apache/metron/pull/622#discussion_r127328660
  
    --- Diff: 
metron-analytics/metron-profiler-client/src/main/java/org/apache/metron/profiler/client/stellar/GetProfile.java
 ---
    @@ -216,21 +211,7 @@ private ColumnBuilder getColumnBuilder(Map<String, 
Object> global) {
        * @param global The global configuration.
        */
       private RowKeyBuilder getRowKeyBuilder(Map<String, Object> global) {
    -
    -    // how long is the profile period?
    -    long duration = PROFILER_PERIOD.get(global, Long.class);
    -    LOG.debug("profiler client: {}={}", PROFILER_PERIOD, duration);
    -
    -    // which units are used to define the profile period?
    -    String configuredUnits = PROFILER_PERIOD_UNITS.get(global, 
String.class);
    -    TimeUnit units = TimeUnit.valueOf(configuredUnits);
    -    LOG.debug("profiler client: {}={}", PROFILER_PERIOD_UNITS, units);
    -
    -    // what is the salt divisor?
    -    Integer saltDivisor = PROFILER_SALT_DIVISOR.get(global, Integer.class);
    -    LOG.debug("profiler client: {}={}", PROFILER_SALT_DIVISOR, 
saltDivisor);
    -
    -    return new SaltyRowKeyBuilder(saltDivisor, duration, units);
    +    return RowKeyBuilderFactory.create(global);
    --- End diff --
    
    This is where we need to instantiate the `RowKeyBuilder` for the Profiler 
Client API.  Like I will discuss in another thread, the logic got complex and 
kind of nasty so I encapsulated it in its own `RowKeyBuilderFactory`.  See that 
class for a further discussion as to why it is kind of nasty.


> Create Decodable Row Key for Profiler
> -------------------------------------
>
>                 Key: METRON-1005
>                 URL: https://issues.apache.org/jira/browse/METRON-1005
>             Project: Metron
>          Issue Type: Improvement
>    Affects Versions: 0.3.0
>            Reporter: Nick Allen
>            Assignee: Nick Allen
>             Fix For: Next + 1
>
>
> To be able to answer the types of questions that I outlined in METRON-450, we 
> need a row key that is decodable.  Right now there is no logic to decode a 
> row key, nor is the existing row key easily decodable.  
> Once the row keys can be decoded, you could scan all of the row keys in the 
> Profiler's HBase table, decode each of them and extract things like, the 
> names of all your profiles, the names of entities within a profile, the 
> period duration of a given profile.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to