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

[Flaky Test]: TestLongRunningAgentForLeaks/TestHandleLeak – Condition never satisfied #4447

Closed
rdner opened this issue Mar 20, 2024 · 8 comments · Fixed by #4454
Closed
Assignees
Labels
flaky-test Unstable or unreliable test cases. Team:Elastic-Agent Label for the Agent team

Comments

@rdner
Copy link
Member

rdner commented Mar 20, 2024

Failing test case

TestLongRunningAgentForLeaks/TestHandleLeak

Error message

Condition never satisfied

Build

https://buildkite.com/elastic/elastic-agent/builds/7876#018e5c3a-00ae-4972-b890-37cad38f2a96

OS

Windows

Stacktrace and notes

agent_long_running_leak_test.go:232: component state: Healthy: communicating with pid '3216'
    agent_long_running_leak_test.go:223: unit ID: winlog-fleet-default-output
    agent_long_running_leak_test.go:223: unit ID: winlog-fleet-default-output-winlog-system-e3f438c4-571c-44b0-a8d5-25e4ea556eef
    agent_long_running_leak_test.go:232: component state: Healthy: communicating with pid '2344'
    agent_long_running_leak_test.go:210: 
        	Error Trace:	C:/Users/windows/agent/testing/integration/agent_long_running_leak_test.go:210
        	            				C:/Users/windows/agent/testing/integration/agent_long_running_leak_test.go:142
        	Error:      	Condition never satisfied
        	Test:       	TestLongRunningAgentForLeaks/TestHandleLeak
        	Messages:   	install never became healthy
--- FAIL: TestLongRunningAgentForLeaks/TestHandleLeak (180.00s)
@rdner rdner added Team:Elastic-Agent Label for the Agent team flaky-test Unstable or unreliable test cases. labels Mar 20, 2024
@elasticmachine
Copy link
Collaborator

Pinging @elastic/elastic-agent (Team:Elastic-Agent)

@cmacknz
Copy link
Member

cmacknz commented Mar 20, 2024

@fearful-symmetry the log message for this needs to be more specific, identifying what is missing or what specifically is unhealthy.

@rdner
Copy link
Member Author

rdner commented Mar 21, 2024

It failed in the daily build too, perhaps it's a real leak then https://buildkite.com/elastic/elastic-agent/builds/7884#018e5e50-9390-41d6-855d-2979484718c7

@rdner
Copy link
Member Author

rdner commented Mar 21, 2024

I skipped the tests for now to avoid more failures, needs to be investigated ASAP
#4452

@cmacknz
Copy link
Member

cmacknz commented Mar 21, 2024

Are we sure this is a bug in this test, and it is not that this test is finding a real bug in the underlying inputs it is testing?

@rdner
Copy link
Member Author

rdner commented Mar 21, 2024

@cmacknz it can be a real failure, we need to properly investigate of course. The most concerning fact is that it started failing without any connection to a new change in the code.

It first started failing after #4447 was merged. Initially, I thought this change introduced something that fails the test, despite the PR being green.

However, then I opened a new PR to revert this change #4451 and in that PR the leak tests also failed which proves that the failure is not related to the change but just came out of nowhere.

@cmacknz
Copy link
Member

cmacknz commented Mar 21, 2024

It is making sure the underlying Beat inputs are healthy, it is entirely possibly an integration or a change in Beats triggered this failure.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
flaky-test Unstable or unreliable test cases. Team:Elastic-Agent Label for the Agent team
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants