----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/35933/#review89913 -----------------------------------------------------------
samza-kv-rocksdb/src/main/scala/org/apache/samza/storage/kv/RocksDbKeyValueStore.scala (line 237) <https://reviews.apache.org/r/35933/#comment142793> Besides we let users decide when to call the getStatistic() to update the metrics, we also can call updateRocksDbStatistic in the flush(). This means, everytime we flush the rocksdb, we will update the rocksDbstatistic. samza-kv-rocksdb/src/main/scala/org/apache/samza/storage/kv/RocksDbStatistic.scala (line 25) <https://reviews.apache.org/r/35933/#comment142791> After second thought, I think current approach has a drawback that, everytime users call getStatistic, we will generate a new Counter/Gauge. That is not ideal. A better approach is, in this metrics class, to create Counter/Gauge, and wrap them together in a method, probabaly called updateRocksDbStatistic(). We will just call this updateRocksDbStatistic in RocksDbKeyValueStore.scala to "update" the metrics, instead of creating new metrics. - Yan Fang On June 26, 2015, 5:56 p.m., Gustavo Anatoly F. V. Solís wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/35933/ > ----------------------------------------------------------- > > (Updated June 26, 2015, 5:56 p.m.) > > > Review request for samza. > > > Repository: samza > > > Description > ------- > > RocksDB statistic > > > Diffs > ----- > > > samza-kv-rocksdb/src/main/scala/org/apache/samza/storage/kv/RocksDbKeyValueStore.scala > a423f7bd6c43461e051b5fd1f880dd01db785991 > > samza-kv-rocksdb/src/main/scala/org/apache/samza/storage/kv/RocksDbStatistic.scala > PRE-CREATION > > samza-kv-rocksdb/src/test/scala/org/apache/samza/storage/kv/TestRocksDbKeyValueStore.scala > a428a16bc1e9ab4980a6f17db4fd810057d31136 > > Diff: https://reviews.apache.org/r/35933/diff/ > > > Testing > ------- > > > Thanks, > > Gustavo Anatoly F. V. Solís > >