hadoop-common-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Arun C Murthy (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HADOOP-1480) pipes should be able to set user counters
Date Mon, 21 Jul 2008 18:03:33 GMT

    [ https://issues.apache.org/jira/browse/HADOOP-1480?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12615339#action_12615339

Arun C Murthy commented on HADOOP-1480:

Here is a proposal after discussions with Owen:

Implement a {{Counter}} class to the C++ layer in Pipes:

class Counter {
    int id;
    void increment(long increment);
    static Counter getCounter(std::string group, std::string name);

The 'getCounter' contacts the Java Pipes' Mapper/Reducer and registers the given counter (group/name).
The registration goes ahead and issues an 'id' which is stored inside the C++ Counter and
is then used for incrementing the value of the counter. 

Of course we'd need the getCounter/increment api in UpwardProtocol too... 
interface UpwardProtocol {

  // ...
  // ...
  // ...

   * Register a counter with the given group and name.
   * @param group counter group
   * @param name counter name
   * @return the id for the registered counter.
   * @throws IOException
  int getCounter(String group, String name) throws IOException;
   * Increment the value of a registered counter.
   * @param id counter id of the registered counter
   * @param amount increment for the counter value
   * @throws IOException
  void incrCounter(int id, long amount) throws IOException;


We'd need to add a {{Counters.Counter getCounter(String group, String name)}} api to Reporter
to facilitate the above registration protocol:
   * Get the {@link Counter} of the given group with the given name.
   * @param group counter group
   * @param name counter name
   * @return the <code>Counter</code> of the given group/name.
  public abstract Counter getCounter(String group, String name);

> pipes should be able to set user counters
> -----------------------------------------
>                 Key: HADOOP-1480
>                 URL: https://issues.apache.org/jira/browse/HADOOP-1480
>             Project: Hadoop Core
>          Issue Type: New Feature
>          Components: pipes
>    Affects Versions: 0.14.0
>            Reporter: Owen O'Malley
>            Assignee: Arun C Murthy
> Pipes should expose the user defined counters.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message