Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Apache status: adjust field collection in fleet mode #22821

Merged
merged 7 commits into from
Dec 3, 2020

Conversation

mtojek
Copy link
Contributor

@mtojek mtojek commented Dec 1, 2020

What does this PR do?

This PR modified field collection log in the Apache module, "status" metricset, so they're collected according to expectations of the Apache Integration.

apache.status.hostname -> host.hostname (already present)
apache.status.uptime.uptime - >host.uptime (decided not to proceed with this change. host.uptime has a different meaning)

Why is it important?

Migration to Beats (elastic/integrations#370)

Checklist

  • My code follows the style guidelines of this project
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have made corresponding change to the default configuration files
  • I have added tests that prove my fix is effective or that my feature works
  • I have added an entry in CHANGELOG.next.asciidoc or CHANGELOG-developer.next.asciidoc.

Author's Checklist

  • [ ]

How to test this PR locally

(there is an integration test)

Related issues

Use cases

Screenshots

Logs

@mtojek mtojek added enhancement Team:Integrations Label for the Integrations team labels Dec 1, 2020
@mtojek mtojek self-assigned this Dec 1, 2020
@botelastic botelastic bot added needs_team Indicates that the issue/PR needs a Team:* label and removed needs_team Indicates that the issue/PR needs a Team:* label labels Dec 1, 2020
@elasticmachine
Copy link
Collaborator

elasticmachine commented Dec 1, 2020

💚 Build Succeeded

the below badges are clickable and redirect to their specific view in the CI or DOCS
Pipeline View Test View Changes Artifacts preview

Expand to view the summary

Build stats

  • Build Cause: Pull request #22821 updated

  • Start Time: 2020-12-02T23:33:58.375+0000

  • Duration: 73 min 50 sec

Test stats 🧪

Test Results
Failed 0
Passed 16761
Skipped 1373
Total 18134

💚 Flaky test report

Tests succeeded.

Expand to view the summary

Test stats 🧪

Test Results
Failed 0
Passed 16761
Skipped 1373
Total 18134

@mtojek
Copy link
Contributor Author

mtojek commented Dec 1, 2020

Test passed:

=== RUN   TestFetchFleetMode
    status_integration_test.go:64: apache/status event: {RootFields:{"host":{"uptime":2}} ModuleFields:null MetricSetFields:{"bytes_per_request":341.333,"bytes_per_sec":512,"connections":{"async":{"closing":0,"keep_alive":1,"writing":0},"total":1},"cpu":{"children_system":0,"children_user":0,"system":0,"user":0},"load":{"1":1.97,"15":0.7,"5":1.52},"requests_per_sec":1.5,"scoreboard":{"closing_connection":0,"dns_lookup":0,"gracefully_finishing":0,"idle_cleanup":0,"keepalive":0,"logging":0,"open_slot":325,"reading_request":0,"sending_reply":1,"starting_up":0,"total":400,"waiting_for_connection":74},"total_accesses":3,"total_kbytes":1,"workers":{"busy":1,"idle":74}} Index: ID: Namespace: Timestamp:0001-01-01 00:00:00 +0000 UTC Error:<nil> Host: Service: Took:0s Period:0s DisableTimeSeries:false}
--- PASS: TestFetchFleetMode (0.55s)

@mtojek mtojek marked this pull request as ready for review December 1, 2020 16:23
@elasticmachine
Copy link
Collaborator

Pinging @elastic/integrations (Team:Integrations)

@mtojek mtojek requested a review from a team December 2, 2020 10:56
libbeat/common/fleetmode/fleet_mode.go Outdated Show resolved Hide resolved
libbeat/common/fleetmode/fleet_mode.go Show resolved Hide resolved
metricbeat/module/apache/status/status.go Outdated Show resolved Hide resolved
metricbeat/module/apache/status/status.go Show resolved Hide resolved
metricbeat/module/apache/status/status.go Outdated Show resolved Hide resolved
@mtojek mtojek requested a review from jsoriano December 2, 2020 12:57
@mtojek
Copy link
Contributor Author

mtojek commented Dec 2, 2020

@jsoriano Thank you for the approval! What are the current rules of merging the PR considering there are two failed checks (not related to this PR)?

@mtojek
Copy link
Contributor Author

mtojek commented Dec 3, 2020

Ok, I see that the relevant test passed. I'm merging this one.

@mtojek mtojek merged commit 0c1e54c into elastic:master Dec 3, 2020
@mtojek mtojek added the v7.11.0 label Dec 3, 2020
mtojek added a commit to mtojek/beats that referenced this pull request Dec 3, 2020
* apache status: adjust collected fields in fleet mode

* Fix: mage check

* Update CHANGELOG

* nit-pick

* Address PR comments

(cherry picked from commit 0c1e54c)
mtojek added a commit that referenced this pull request Dec 3, 2020
…fleet mode (#22882)

* Apache status: adjust field collection in fleet mode (#22821)

* apache status: adjust collected fields in fleet mode

* Fix: mage check

* Update CHANGELOG

* nit-pick

* Address PR comments

(cherry picked from commit 0c1e54c)

* Fix: remove extra lines

* Fix: remove extra lines
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Team:Integrations Label for the Integrations team v7.11.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants