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

Failing test: Jest Integration Tests.x-pack/plugins/task_manager/server/integration_tests - capacity based claiming should claim tasks to full capacity #191117

Open
kibanamachine opened this issue Aug 22, 2024 · 25 comments · Fixed by #191125 or #192519
Assignees
Labels
blocker failed-test A test failure on a tracked branch, potentially flaky-test skipped-test Team:ResponseOps Label for the ResponseOps team (formerly the Cases and Alerting teams) v9.0.0

Comments

@kibanamachine
Copy link
Contributor

kibanamachine commented Aug 22, 2024

A test failed on a tracked branch

Error: expect(received).toBeLessThanOrEqual(expected)

Expected: <= 1000
Received:    4900
    at Object.toBeLessThanOrEqual (/opt/buildkite-agent/builds/bk-agent-prod-gcp-1724342931470529047/elastic/kibana-on-merge/kibana/x-pack/plugins/task_manager/server/integration_tests/task_manager_capacity_based_claiming.test.ts:201:36)

First failure: kibana-on-merge - main

@kibanamachine kibanamachine added the failed-test A test failure on a tracked branch, potentially flaky-test label Aug 22, 2024
@botelastic botelastic bot added the needs-team Issues missing a team label label Aug 22, 2024
@kibanamachine kibanamachine added the Team:ResponseOps Label for the ResponseOps team (formerly the Cases and Alerting teams) label Aug 22, 2024
@elasticmachine
Copy link
Contributor

Pinging @elastic/response-ops (Team:ResponseOps)

@botelastic botelastic bot removed the needs-team Issues missing a team label label Aug 22, 2024
@kibanamachine
Copy link
Contributor Author

New failure: kibana-on-merge - main

@kibanamachine
Copy link
Contributor Author

New failure: kibana-on-merge - main

@kibanamachine
Copy link
Contributor Author

New failure: kibana-on-merge - main

jbudz added a commit that referenced this issue Aug 22, 2024
@jbudz
Copy link
Member

jbudz commented Aug 22, 2024

Skipped

main: 53b5d7c

@kibanamachine
Copy link
Contributor Author

New failure: kibana-on-merge - main

ymao1 added a commit that referenced this issue Sep 5, 2024
…r/server/integration_tests - capacity based claiming should claim tasks to full capacity (#191125)

Resolves #191117

## Summary

Made the following changes to reduce flakiness:
* Set the `runAt` date slightly in the past
* Ensured the partitions are properly set when scheduling the task

After making these changes, was able to run the capacity claiming tests
[50](https://buildkite.com/elastic/kibana-pull-request/builds/232049#0191be3e-9834-4a8f-b0bf-f84a15cab89a)
& [65](https://buildkite.com/elastic/kibana-pull-request/builds/232106)
times without failing.
@kibanamachine
Copy link
Contributor Author

New failure: kibana-on-merge - main

@kibanamachine kibanamachine reopened this Sep 6, 2024
@kibanamachine
Copy link
Contributor Author

New failure: kibana-on-merge - main

@kibanamachine
Copy link
Contributor Author

New failure: kibana-on-merge - main

@kibanamachine
Copy link
Contributor Author

New failure: kibana-on-merge - main

@kibanamachine
Copy link
Contributor Author

New failure: kibana-on-merge - main

@kibanamachine
Copy link
Contributor Author

New failure: kibana-on-merge - main

jbudz added a commit that referenced this issue Sep 6, 2024
@jbudz
Copy link
Member

jbudz commented Sep 6, 2024

Skipped

main: ef6f3c7

@kibanamachine
Copy link
Contributor Author

New failure: kibana-on-merge - main

@kibanamachine
Copy link
Contributor Author

New failure: kibana-on-merge - main

@kibanamachine
Copy link
Contributor Author

New failure: kibana-on-merge - main

@kibanamachine
Copy link
Contributor Author

New failure: kibana-on-merge - main

@kibanamachine
Copy link
Contributor Author

New failure: kibana-on-merge - main

ymao1 added a commit that referenced this issue Sep 11, 2024
…r/server/integration_tests - capacity based claiming should claim tasks to full capacity (#192519)

Resolves #191117

This test became flaky again after merging this PR
#192261 which changes Kibana to
claim tasks against all partitions when the partitions have not yet been
assigned. This was due to setting the `runAt` value to `now-1000` which
means that all injected tasks were immediately overdue and claimable as
soon as possible, which means they might get claimed in different claim
cycles. This PR changes the `runAt` value to `now + 5000` so injected
tasks won't be claimed until they're all injected so they should be
claimed in one cycle.

Copied this test 60 times and was able to run the integration tests
twice (so 120 times total) with no failures.
*
https://buildkite.com/elastic/kibana-pull-request/builds/233196#0191dd0b-fe03-40cf-9fab-b211dd662993
*
https://buildkite.com/elastic/kibana-pull-request/builds/233236#0191dd94-8010-4b3c-988d-6e7d5655f989
@kibanamachine kibanamachine reopened this Oct 23, 2024
@kibanamachine
Copy link
Contributor Author

New failure: kibana-on-merge - main

@kibanamachine
Copy link
Contributor Author

New failure: kibana-on-merge - main

@mistic
Copy link
Member

mistic commented Nov 8, 2024

Skipped.

main: b196452

CAWilson94 pushed a commit to CAWilson94/kibana that referenced this issue Nov 11, 2024
@kibanamachine
Copy link
Contributor Author

New failure: kibana-on-merge - 8.x

@ymao1 ymao1 self-assigned this Nov 25, 2024
@kibanamachine
Copy link
Contributor Author

New failure: kibana-on-merge - 8.x

@kibanamachine
Copy link
Contributor Author

New failure: kibana-on-merge - 8.x

@kibanamachine
Copy link
Contributor Author

New failure: kibana-on-merge - 8.x

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment