8 Commits

Author SHA1 Message Date
Yangster-mac
b142cc8add Statsd config TTL
Roughly check the config every hour to see whether the ttl expired.
If so, read the config from disk and recreate the metric manager.

Test: statsd test

BUG: b/77274363

Change-Id: I16838afe5bbe966c3a0f638869751f9b59a5a259
2018-04-04 15:59:43 +00:00
Yangster-mac
c04feba805 Move forward the alarm timestamp when config is added to statsd.
Test: statsd test
BUG: b/77344187

Change-Id: Ieacffaa29422829b8956f2b3fcb2c647c8c3eed9
2018-04-02 18:12:36 -07:00
Chenjie Yu
5caaa9d854 Clean up atoms.proto
changes are:
1) for pushed atoms, use attribution node in place of uid when
appropriate
2) name changes to be more consistent

Bug: 73823969
Test: manual test
Change-Id: Iacf7186dbd7a2282f7fe481f43dbbf92e1165b47
2018-03-30 10:11:03 -07:00
Yangster-mac
e06cfd777a Support slicing by chain.
BUG: b/73975181

Test: statsd test
Change-Id: I913ae0f68ff21ed0703bb5da9c60d3eaa3bf5981
2018-03-14 15:36:24 -07:00
Yangster
13fb7e4eea Statsd cpu optimizaton
- cache the changed dimensions in condition tracker.
- avoid query condition wizard when unnecessary.
- avoid copy dimension keys in condition key generation.

Test: statsd tests.

BUG: b/73959649
Change-Id: I17d68e2a82643de3f421309841e75f84c6fd8f43
2018-03-07 17:36:07 -08:00
Yangster-mac
f520492279 Avoid creating temporary objects in FiterValue().
It reduces the cpu time from 1000ns to 750ns

Test: statsd test.
Change-Id: Ifa7e98e3368f8d55f85c7b09d05a6c416482981d
2018-02-23 20:53:23 -08:00
Tej Singh
3410634f2c Benchmark: stats_write
benchmarks how long stats_write takes for boot sequence atom
results: I ran it a few times, and the times ranged from ~18-20us on
marlin

Test: ran the benchmark test
Change-Id: I900ef26ce219301a6d43999fe7be5e4875ae5b8a
2018-02-05 11:27:23 -08:00
Yao Chen
48d75189cc Add statsd microbenchmark and fix a crash in LogEvent
+ We should benchmark the core functions in the critical path.
     1. LogEvent parsing
     2. Log matching
     3. Event processing in various metrics
     ....

+ Using microbenchmark, we can quantify the optimization we do in the future.

    ---------------------------------------------------------
    Benchmark                  Time           CPU Iterations
    ---------------------------------------------------------
    BM_LogEventCreation       4772 ns       4705 ns     145738

Test: make -j64 statsd_benchmark

Bug: 72242322

Change-Id: I43aa704ffdc7cd21e02ef9038eff66ca7022dbfb
2018-01-24 10:02:36 -08:00