sapling/eden/fs/fuse
Zhengchao Liu 432d674649 sample FS trace events for logging
Summary:
The current fb303 counters only report aggregated latency while we want to track Eden performance under different version, os, channel, and configs. So I am setting up a new logging mechanism for this purpose.

This diff introduces the class `FsEventLogger` for sampling and logging. There are 3 configs introduced by this diff. The configs are reloaded every 30 minutes.
1. `telemetry:request-sampling-config-allowlist`
A list of config keys that we want to attach to scuba events.

2. `telemetry:request-samples-per-minute`
Max number of events logged to scuba per minute per mount.

3. `telemetry:request-sampling-group-denominators`
* Each type of operation has a "sampling group" (defaulted to 0, which is dropping all).
* We use this sampling group as index to look up its denominator in this config.
* The denominator is then used for sampling. e.g. `1/x` of the events are send to scuba, if we haven't reached the cap specified by #2.

Example workflow:
1. receive tracing event
2. look up denominator of the sampling group of the operation type
3. sample based on the denominator
4. check that we have not exceeded the logging cap per min
5. create sample and send to scribe

Reviewed By: xavierd

Differential Revision: D30288054

fbshipit-source-id: 8f2b95c11c718550a8162f4d1259a25628f499ff
2021-08-19 14:21:52 -07:00
..
fuse_tester sample FS trace events for logging 2021-08-19 14:21:52 -07:00
privhelper fix broken privhelper tests 2021-07-14 08:54:52 -07:00
test sample FS trace events for logging 2021-08-19 14:21:52 -07:00
CMakeLists.txt nfs: implement SETATTR RPC 2021-03-11 08:31:07 -08:00
DirList.cpp fuse: namespace facebook::eden 2021-06-08 19:29:37 -07:00
DirList.h fuse: namespace facebook::eden 2021-06-08 19:29:37 -07:00
FuseChannel.cpp sample FS trace events for logging 2021-08-19 14:21:52 -07:00
FuseChannel.h sample FS trace events for logging 2021-08-19 14:21:52 -07:00
FuseDispatcher.cpp fuse: namespace facebook::eden 2021-06-08 19:29:37 -07:00
FuseDispatcher.h thread ObjectFetchContext write, setattr, fallocate 2021-06-04 14:57:47 -07:00
FuseRequestContext.cpp getCauseDetail to return correct result after Fuse request released 2021-08-02 17:50:15 -07:00
FuseRequestContext.h getCauseDetail to return correct result after Fuse request released 2021-08-02 17:50:15 -07:00
FuseTypes.h fuse: namespace facebook::eden 2021-06-08 19:29:37 -07:00
Invalidation.h fuse: namespace facebook::eden 2021-06-08 19:29:37 -07:00
PollHandle.cpp fuse: namespace facebook::eden 2021-06-08 19:29:37 -07:00
PollHandle.h fuse: namespace facebook::eden 2021-06-08 19:29:37 -07:00