beats icon indicating copy to clipboard operation
beats copied to clipboard

[filebeat] Benchmark adding file owner and group to the events' meta fields

Open AndersonQ opened this issue 3 weeks ago • 3 comments

With https://github.com/elastic/beats/pull/47331 we allow users to opt-in to add the user and group to the events' meta fields. It requires 2 extra syscalls, which might add a non-negligible overhead.

We need to perform a e2e benchmark to evaluate the real impact of enabling them. Then consider if an optimisation to reduce the overhead is needed or not.

AndersonQ avatar Dec 03 '25 07:12 AndersonQ

Pinging @elastic/elastic-agent-data-plane (Team:Elastic-Agent-Data-Plane)

elasticmachine avatar Dec 03 '25 07:12 elasticmachine

I think this makes sense but I would prefer we put time into doing the optimization first and use this to confirm it worked as suggested in https://github.com/elastic/beats/pull/47331#issuecomment-3603727420.

There are at least 3 follow up issues from that PR we can create and group together in a single parent issue:

  • Adding support for Windows
  • Removing the two extra system calls from the hot path which is the file line reader
  • Doing this macro-benchmark, we already have a micro-benchmark in https://github.com/elastic/beats/pull/47331#issuecomment-3597256712 showing there is a significant performance hit.

cmacknz avatar Dec 03 '25 15:12 cmacknz

we can create and group together in a single parent issue

done:

  • https://github.com/elastic/beats/issues/47997

AndersonQ avatar Dec 09 '25 15:12 AndersonQ