-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
New metricbeat module: pgbouncer #41174
base: main
Are you sure you want to change the base?
Conversation
💚 CLA has been signed |
This pull request is now in conflicts. Could you fix it? 🙏
|
This pull request does not have a backport label.
To fixup this pull request, you need to add the backport labels for the needed
|
|
3f19266
to
22fe659
Compare
Pinging @elastic/elastic-agent-data-plane (Team:Elastic-Agent-Data-Plane) |
Thanks @manuelsaks for your contribution. |
@lalit-satapathy as this is related to PostgreSQL, would you mind assigning someone from your team for the reviewing part? |
@manuelsaks it looks like your tests are failing, could you please fix them?
|
I don't have an access to the buildkite logs.
|
@manuelsaks Thanks for willing to look into the CI issue. I spotted this error in the logs:
|
I successfully recreated the issue in my own temporary buildkite pipeline and confirmed that it should be resolved with the commit 5e8158d. |
This reverts commit 9e63bbf.
/test |
run docs-build |
Can you provide me details/logs about those new errors? |
Every tests are failing on the windows runner for the same reason:
|
I missed adding build tags, which caused the unit test pipelines to also run integration tests. This failed on Windows Server agents without docker-compose. I've added the necessary build tags and successfully tested with commit fdd7d0f on Windows Server 2022. |
/test |
I'm not sure if the error from the I merged from main to have the latest changes. |
/test |
1 similar comment
/test |
We are moving in the right direction, one last error:
|
/test |
The problem is:
This occurs when running the def test_index_management(self):
"""
Test that the template can be loaded with `setup --index-management`
"""
es = Elasticsearch([self.get_elasticsearch_url()])
self.render_config_template(
modules=[{
"name": "apache",
"metricsets": ["status"],
"hosts": ["localhost"],
}],
elasticsearch={"host": self.get_elasticsearch_url()},
)
exit_code = self.run_beat(extra_args=["setup", "--index-management", "-E", "setup.template.overwrite=true"])
assert exit_code == 0
assert self.log_contains('Loaded index template')
assert len(es.cat.templates(name='metricbeat-*', h='name')) > 0 If I increase the field limit from the
to
the test passes. Please advise what should I do now. |
/test |
/test |
/test |
The module follows the standard design patterns of Metricbeat modules, ensuring consistency with other database modules like PostgreSQL. It implements the MetricSet interface to collect metrics from PgBouncer.
The module interacts with PgBouncer using SQL queries to gather pool statistics and server performance data. The data is parsed and processed through Metricbeat's internal processing pipeline. It communicates with PgBouncer using the native Postgres protocol over TCP. It sends queries to fetch relevant metrics and processes the responses, converting them into Metricbeat-compatible events.
PGBouncer is widely used as a connection pooler for PostgreSQL, and monitoring its performance is crucial for maintaining the health of database-backed systems. By adding this module, Metricbeat provides users with out-of-the-box monitoring capabilities for PGBouncer, enabling them to track metrics such as connection pool utilization, server performance, and query rates. This integration helps users maintain optimal database performance, reduce latency, and prevent resource exhaustion in their systems.
-->
Checklist
CHANGELOG.next.asciidoc
orCHANGELOG-developer.next.asciidoc
.Disruptive User Impact
It shouldn't impact users.
Author's Checklist
How to test this PR locally
localhost:5601
test
pattern and check logs in discover.