Skip to content

Conversation

@VihasMakwana
Copy link
Contributor

@VihasMakwana VihasMakwana commented Nov 11, 2024

For diskio metricset,

if counters.SerialNumber != "" {
event["serial_number"] = counters.SerialNumber
}

serial_number field is set, conditionally.

This error has likely originated by bumping PR on https://github.com/elastic/elastic-agent-system-metrics.

I think, for such conditional fields, our best case is to remove them from event or else they trigger a failure.

We cannot add such fields at

SYSTEM_DISKIO = {
metricbeat.P_DEF: ["name", "read.count", "write.count", "read.bytes",
"write.bytes", "read.time", "write.time"]
}
SYSTEM_DISKIO[metricbeat.P_LINUX] = SYSTEM_DISKIO[metricbeat.P_DEF] + \
["io.time", "io.ops"]

as that would also result in a failure, because the serial_number can be absent for some devices.

This is needed to unblock #41524

@VihasMakwana VihasMakwana requested review from a team as code owners November 11, 2024 08:37
@botelastic botelastic bot added the needs_team Indicates that the issue/PR needs a Team:* label label Nov 11, 2024
@VihasMakwana VihasMakwana self-assigned this Nov 11, 2024
@VihasMakwana VihasMakwana added the Team:Elastic-Agent-Data-Plane Label for the Agent Data Plane team label Nov 11, 2024
@elasticmachine
Copy link
Contributor

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

@botelastic botelastic bot removed the needs_team Indicates that the issue/PR needs a Team:* label label Nov 11, 2024
@mergify
Copy link
Contributor

mergify bot commented Nov 11, 2024

This pull request does not have a backport label.
If this is a bug or security fix, could you label this PR @VihasMakwana? 🙏.
For such, you'll need to label your PR with:

  • The upcoming major version of the Elastic Stack
  • The upcoming minor version of the Elastic Stack (if you're not pushing a breaking change)

To fixup this pull request, you need to add the backport labels for the needed
branches, such as:

  • backport-8./d is the label to automatically backport to the 8./d branch. /d is the digit

@mergify
Copy link
Contributor

mergify bot commented Nov 11, 2024

backport-8.x has been added to help with the transition to the new branch 8.x.
If you don't need it please use backport-skip label and remove the backport-8.x label.

@mergify mergify bot added the backport-8.x Automated backport to the 8.x branch with mergify label Nov 11, 2024
@VihasMakwana VihasMakwana requested review from AndersonQ and rdner and removed request for belimawr and leehinman November 11, 2024 08:40
@VihasMakwana VihasMakwana merged commit 56dca4b into elastic:main Nov 11, 2024
6 checks passed
mergify bot pushed a commit that referenced this pull request Nov 11, 2024
* chore: fix CI failure

* lint

* bug

(cherry picked from commit 56dca4b)
VihasMakwana added a commit that referenced this pull request Nov 11, 2024
* chore: fix CI failure

* lint

* bug

(cherry picked from commit 56dca4b)

Co-authored-by: Vihas Makwana <[email protected]>
@VihasMakwana VihasMakwana added the backport-8.16 Automated backport with mergify label Nov 13, 2024
mergify bot pushed a commit that referenced this pull request Nov 13, 2024
* chore: fix CI failure

* lint

* bug

(cherry picked from commit 56dca4b)
VihasMakwana added a commit that referenced this pull request Nov 13, 2024
* chore: fix CI failure

* lint

* bug

(cherry picked from commit 56dca4b)

Co-authored-by: Vihas Makwana <[email protected]>
@khushijain21 khushijain21 mentioned this pull request Jun 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport-8.x Automated backport to the 8.x branch with mergify backport-8.16 Automated backport with mergify Team:Elastic-Agent-Data-Plane Label for the Agent Data Plane team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants