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

Pass context when executing command in the agent container. #116

Closed
wants to merge 3 commits into from

Conversation

pablochacin
Copy link
Collaborator

Description

Faults are injected in pods by executing a command in the xk6-agent's ephemeral container.

As described in #82 any ongoing command to the xk6-disruptor is not canceled if the test is canceled. In #109 we introduced the logic to get the context of the VU that creates a disruptor. This context is canceled if the VU is canceled.

In this PR, we pass the VU's context when executing the command in the pod and using the feature introduced in k8s go client v1.25.0 we are using this context when establishing a connection to the pod. This changes should get the ongoing command canceled if the VU is canceled.

Checklist:

  • My code follows the coding style of this project
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works.
  • Any dependent changes have been merged and published in downstream modules

Signed-off-by: Pablo Chacin <[email protected]>
Signed-off-by: Pablo Chacin <[email protected]>
Signed-off-by: Pablo Chacin <[email protected]>
@pablochacin
Copy link
Collaborator Author

This logic is implemented as part of #279

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.

1 participant