getCounter is declared in different classes in hadoop1 & 2.