martin-helmich / prometheus-nginxlog-exporter

Export metrics from Nginx access log files to Prometheus

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Improve Performance For "MaxLineSize" and Concurrency of ParseString(line)

lhanjian opened this issue · comments

add MaxLineSize: 65534 to improve Throughput of reading file?

for line := range t.Lines() {

to Concurrent Execute ParseString(line) in this loop?

over 25000 QPS access.log, exporter unable to update metrics accurately.

Tks.

25k qps is a respectable workload 😳 -- admittedly, this is the heaviest workload that I've seen this exporter been subjected to. I'd be happy to include optimizations for such heavy workloads, however I can't make any promises as to when I'll actually find the time to get to that. In the meantime, I'm happy to accept any PRs in this matter. 🙂

Do you have a rule of thumb for the max qps that you know the exporter can handle without pegging the one core that it uses and falling behind on log processing?