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

Response Body modification in HTTP Status code experiment #556

Merged
merged 4 commits into from
Sep 15, 2022

Conversation

avaakash
Copy link
Contributor

@avaakash avaakash commented Sep 6, 2022

Signed-off-by: Akash Shrivastava akash.shrivastava@harness.io

What this PR does / why we need it:
This PR adds the ability to modify the response body in the HTTP status code experiment.
It also adds support to provide the content type and encoding for the body in modify body and status code experiments.

Checklist:

  • Fixes #
  • PR messages has document related information
  • Labelled this PR & related issue with breaking-changes tag
  • PR messages has breaking changes related information
  • Labelled this PR & related issue with requires-upgrade tag
  • PR messages has upgrade related information
  • Commit has unit tests
  • Commit has integration tests
  • E2E run Required for the changes

…n body and status; Removed unneccesary logging

Signed-off-by: Akash Shrivastava <akash.shrivastava@harness.io>
Signed-off-by: Akash Shrivastava <akash.shrivastava@harness.io>
Copy link
Contributor

@Jonsy13 Jonsy13 left a comment

Choose a reason for hiding this comment

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

Looks Good! Thanks for command execution changes @avaakash 🚀

// sleep 10 is added for proxy-server to be ready for creating proxy and adding toxics
chaosCommand := fmt.Sprintf("%s && sleep 10 && %s && %s", startProxyServerCommand, createProxyCommand, createToxicCommand)
// sleep 2 is added for proxy-server to be ready for creating proxy and adding toxics
chaosCommand := fmt.Sprintf("%s && sleep 2 && %s && %s", startProxyServerCommand, createProxyCommand, createToxicCommand)
Copy link
Member

Choose a reason for hiding this comment

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

We should remove the sleep and provide some cmd that would check the proxy server is ready in the future.

@uditgaurav uditgaurav merged commit e3c0492 into litmuschaos:master Sep 15, 2022
SaptarshiSarkar12 pushed a commit to SaptarshiSarkar12/litmus-go that referenced this pull request Sep 21, 2022
…s#556)

* added response body in status code; Added content encoding and type in body and status; Removed unnecessary logging

Signed-off-by: Akash Shrivastava <akash.shrivastava@harness.io>
Signed-off-by: Saptarshi Sarkar <saptarshi.programmer@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants