skywalking-java/oap-server/analyzer
kezhenxu94 84a7fe30c8
Perf: cache regex pattern and result, optimize string concatenation (#7199)
The possible metrics names are relatively fixed in an OAP run, we previously always escape the metrics names, building a new regex Pattern from scratch, which is cpu-consuming.

In this patch, I cache the escaped metrics names, and if it missed, use a pre-compiled regex Pattern to escape the metrics name.

This patch also replace string concatenation `+` with `StringBuilder` in generated classes, which won't get optimized by Java compiler

This may reduce 1~1.5 vCPU under 20K RPS environment.
2021-06-29 17:46:42 +08:00
..
agent-analyzer fix slow db dynamic config bug (#7192) 2021-06-29 16:41:01 +08:00
event-analyzer OAL supports generating metrics from events (#7134) 2021-06-19 20:20:37 +08:00
log-analyzer Initialize 8.7.0 iteration (#7078) 2021-06-08 07:41:09 +08:00
meter-analyzer Perf: cache regex pattern and result, optimize string concatenation (#7199) 2021-06-29 17:46:42 +08:00
pom.xml Initialize 8.7.0 iteration (#7078) 2021-06-08 07:41:09 +08:00