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

Change form:false for AD request #295

Merged
merged 1 commit into from
Sep 28, 2022

Conversation

ohltyler
Copy link
Member

Signed-off-by: Tyler Ohlsen ohltyler@amazon.com

Description

Changes the AD request to form:false in the request parameters, when loading in some sample data. From the cypress documentation, setting to form:true means the body should be url-encoded, and overwrites the Content-Type header to application/x-www-form-urlencoded. What we actually want is application/json which we have already specified in the request itself. By setting to false it removes any confusion and cleans up the code to make it run as expected.

Note that the previous code still worked, but was changing the request header to Content-Type: application/x-www-form-urlencoded under the hood which was causing confusion and could lead to certain bugs, especially if the request body was changed such that it couldn't be url-encoded.

Check List

  • Commits are signed per the DCO using --signoff

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>
@tianleh
Copy link
Member

tianleh commented Sep 28, 2022

Looks like that there are more places with such https://github.com/opensearch-project/opensearch-dashboards-functional-test/blob/main/cypress/integration/plugins/gantt-chart-dashboards/gantt_ui.spec.js#L22

I am ok if we just focus on one plugin in this PR. @CCongWang

@tianleh
Copy link
Member

tianleh commented Sep 28, 2022

side note: the bundle workflow failed because there is no real OS plugin yet.

https://github.com/opensearch-project/opensearch-build/blob/main/manifests/3.0.0/opensearch-3.0.0.yml

@CCongWang CCongWang merged commit e9f6ae2 into opensearch-project:main Sep 28, 2022
opensearch-trigger-bot bot pushed a commit that referenced this pull request Sep 28, 2022
Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>

Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>
(cherry picked from commit e9f6ae2)
opensearch-trigger-bot bot pushed a commit that referenced this pull request Sep 28, 2022
Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>

Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>
(cherry picked from commit e9f6ae2)
opensearch-trigger-bot bot pushed a commit that referenced this pull request Sep 28, 2022
Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>

Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>
(cherry picked from commit e9f6ae2)
opensearch-trigger-bot bot pushed a commit that referenced this pull request Sep 28, 2022
Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>

Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>
(cherry picked from commit e9f6ae2)
@opensearch-trigger-bot
Copy link
Contributor

The backport to 1.2 failed:

The process '/usr/bin/git' failed with exit code 1

To backport manually, run these commands in your terminal:

# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-1.2 1.2
# Navigate to the new working tree
cd .worktrees/backport-1.2
# Create a new branch
git switch --create backport/backport-295-to-1.2
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 e9f6ae2675a220511c0c2ddf2f734b2c79ad734a
# Push it to GitHub
git push --set-upstream origin backport/backport-295-to-1.2
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-1.2

Then, create a pull request where the base branch is 1.2 and the compare/head branch is backport/backport-295-to-1.2.

@opensearch-trigger-bot
Copy link
Contributor

The backport to 1.1 failed:

The process '/usr/bin/git' failed with exit code 1

To backport manually, run these commands in your terminal:

# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-1.1 1.1
# Navigate to the new working tree
cd .worktrees/backport-1.1
# Create a new branch
git switch --create backport/backport-295-to-1.1
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 e9f6ae2675a220511c0c2ddf2f734b2c79ad734a
# Push it to GitHub
git push --set-upstream origin backport/backport-295-to-1.1
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-1.1

Then, create a pull request where the base branch is 1.1 and the compare/head branch is backport/backport-295-to-1.1.

@opensearch-trigger-bot
Copy link
Contributor

The backport to 1.0 failed:

The process '/usr/bin/git' failed with exit code 1

To backport manually, run these commands in your terminal:

# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-1.0 1.0
# Navigate to the new working tree
cd .worktrees/backport-1.0
# Create a new branch
git switch --create backport/backport-295-to-1.0
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 e9f6ae2675a220511c0c2ddf2f734b2c79ad734a
# Push it to GitHub
git push --set-upstream origin backport/backport-295-to-1.0
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-1.0

Then, create a pull request where the base branch is 1.0 and the compare/head branch is backport/backport-295-to-1.0.

opensearch-trigger-bot bot pushed a commit that referenced this pull request Sep 28, 2022
Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>

Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>
(cherry picked from commit e9f6ae2)
opensearch-trigger-bot bot pushed a commit that referenced this pull request Sep 28, 2022
Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>

Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>
(cherry picked from commit e9f6ae2)
opensearch-trigger-bot bot pushed a commit that referenced this pull request Sep 28, 2022
Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>

Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>
(cherry picked from commit e9f6ae2)
CCongWang pushed a commit that referenced this pull request Sep 28, 2022
Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>

Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>
(cherry picked from commit e9f6ae2)

Co-authored-by: Tyler Ohlsen <ohltyler@amazon.com>
CCongWang pushed a commit that referenced this pull request Sep 28, 2022
Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>

Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>
(cherry picked from commit e9f6ae2)

Co-authored-by: Tyler Ohlsen <ohltyler@amazon.com>
CCongWang pushed a commit that referenced this pull request Sep 28, 2022
Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>

Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>
(cherry picked from commit e9f6ae2)

Co-authored-by: Tyler Ohlsen <ohltyler@amazon.com>
CCongWang pushed a commit that referenced this pull request Sep 28, 2022
Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>

Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>
(cherry picked from commit e9f6ae2)

Co-authored-by: Tyler Ohlsen <ohltyler@amazon.com>
CCongWang pushed a commit that referenced this pull request Sep 28, 2022
Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>

Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>
(cherry picked from commit e9f6ae2)

Co-authored-by: Tyler Ohlsen <ohltyler@amazon.com>
CCongWang pushed a commit that referenced this pull request Sep 28, 2022
Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>

Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>
(cherry picked from commit e9f6ae2)

Co-authored-by: Tyler Ohlsen <ohltyler@amazon.com>
CCongWang pushed a commit that referenced this pull request Sep 28, 2022
Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>

Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>
(cherry picked from commit e9f6ae2)

Co-authored-by: Tyler Ohlsen <ohltyler@amazon.com>
@tianleh
Copy link
Member

tianleh commented Sep 28, 2022

Some branches failed to backport. @ohltyler @CCongWang

@seraphjiang seraphjiang added the enhancement New feature or request label Oct 25, 2022
CCongWang pushed a commit that referenced this pull request Feb 10, 2023
Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>

Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>
(cherry picked from commit e9f6ae2)

Co-authored-by: Tyler Ohlsen <ohltyler@amazon.com>
Signed-off-by: Cong Wang <conjwang@amazon.com>
jakubp-eliatra pushed a commit to sebastianmichalski/opensearch-dashboards-functional-test that referenced this pull request Mar 24, 2023
Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>

Signed-off-by: Tyler Ohlsen <ohltyler@amazon.com>
Signed-off-by: Jakub Przybylski <jakub.przybylski@eliatra.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.

5 participants