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

Fix taskqueue not closing when the iteration is aborted #1452

Merged
merged 2 commits into from
Oct 1, 2024

Conversation

ankur22
Copy link
Collaborator

@ankur22 ankur22 commented Oct 1, 2024

What?

This ensures that the tasqueue is closed if it hasn't already been closed. We can now rely on the vu context when the iteration ends to clean up any remaining taskqueues. This means that if the user forgets to use page.close then we will be able to close the taskqueue.

Why?

We need to closed the taskqueue to avoid the k6 process from hanging indefinitely.

Checklist

  • I have performed a self-review of my code
  • I have added tests for my changes
  • I have commented on my code, particularly in hard-to-understand areas

Related PR(s)/Issue(s)

Updates: #1451
Updates: #1450

Copy link
Member

@inancgumus inancgumus left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉 Thanks for all these fixes!

This fix ensures that the taskqueue is closed when the iteration ends.
If the taskqueue isn't closed when the iteration ends the k6 process
will hang indefinitely. We used to rely on page.close, but now that the
life cycle of the iteration is controlled by the VU we can safely rely
on the VU context to ensure that the taskqueue is closed (if it isn't
already closed).
@ankur22 ankur22 merged commit c71bdb1 into main Oct 1, 2024
23 checks passed
@ankur22 ankur22 deleted the fix/page-on-deadlock branch October 1, 2024 16:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants