Currently the "dcp" and "dcpagg" stats are collated by the front-end thread. This can be an expensive operation, and hence the STAT command can take a significant time to return. This means the STAT operation is tying-up a front-and thread which means that operations that happen to be allocated to the same thread get delayed for an unacceptable length of time.
- Move the expensive part(s) of these stat groups to a background task, allowing the client operation to EWOULDBLOCK and yield execution back to the front-end thread.
- Investigate what part(s) of these stat groups ns_server needs. If the stat(s) needed are cheap then consider new stat groups which only contain the specific elements ns_server needs.
Note we might want both of these; given that dcp and dcpagg are recorded by cbcollect_info and we wouldn't want to remove them there.
|For Gerrit Dashboard: MB-38978|
|156626,2||MB-38978: Gather "dcp" stats group in a background task||master||kv_engine||Status: ABANDONED||0||0|
|156699,4||MB-38978: Gather "dcp" stats group in a background task||cheshire-cat||kv_engine||Status: MERGED||+2||+1|
|156700,6||MB-38978: Gather "dcpagg" stats group in a background task||cheshire-cat||kv_engine||Status: MERGED||+2||+1|
|156868,2||MB-38978: Gather "dcpagg" stats group in a background task||master||kv_engine||Status: ABANDONED||0||0|
|157108,1||Merge branch 'couchbase/cheshire-cat' into couchbase/master||master||kv_engine||Status: MERGED||+2||+1|