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

Remove useCase and defaultParams field in WorkflowRequest #952

Merged
merged 3 commits into from
Nov 11, 2024

Conversation

junweid62
Copy link
Contributor

@junweid62 junweid62 commented Nov 8, 2024

Description

  • Removed useCase And defaultParams since the WorkflowRequest class doesn't serialize the use case and default parameters over transport.

  • Also removed the constructor that has never been used in our code base

Related Issues

Resolves #758

Check List

  • New functionality includes testing.
  • [ ] New functionality has been documented.
  • [ ] API changes companion pull request created.
  • Commits are signed per the DCO using --signoff.
  • [ ] Public documentation issue/PR created.

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.

Copy link

codecov bot commented Nov 8, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 78.08%. Comparing base (9b9ebb2) to head (f5f777d).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff            @@
##               main     #952   +/-   ##
=========================================
  Coverage     78.07%   78.08%           
+ Complexity      996      993    -3     
=========================================
  Files            99       99           
  Lines          4625     4617    -8     
  Branches        431      431           
=========================================
- Hits           3611     3605    -6     
+ Misses          834      832    -2     
  Partials        180      180           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@dbwiddis dbwiddis left a comment

Choose a reason for hiding this comment

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

LGTM, but not sure if the removed tests are completely duplicated somewhere else or provide at least one interesting change worth testing (even if not the new params)

Copy link
Member

@dbwiddis dbwiddis left a comment

Choose a reason for hiding this comment

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

Also removed the constructor that has never been used in our code base

Although this comment seems to be the "new thing" that was tested so probably good to remove.

@dbwiddis dbwiddis merged commit 219aec5 into opensearch-project:main Nov 11, 2024
20 checks passed
@opensearch-trigger-bot
Copy link
Contributor

The backport to 2.x failed:

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

To backport manually, run these commands in your terminal:

# Navigate to the root of your repository
cd $(git rev-parse --show-toplevel)
# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add ../.worktrees/flow-framework/backport-2.x 2.x
# Navigate to the new working tree
pushd ../.worktrees/flow-framework/backport-2.x
# Create a new branch
git switch --create backport/backport-952-to-2.x
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 219aec5c1b85b8aa3e5e15cdf0029c13666ae37e
# Push it to GitHub
git push --set-upstream origin backport/backport-952-to-2.x
# Go back to the original working tree
popd
# Delete the working tree
git worktree remove ../.worktrees/flow-framework/backport-2.x

Then, create a pull request where the base branch is 2.x and the compare/head branch is backport/backport-952-to-2.x.

@opensearch-trigger-bot opensearch-trigger-bot bot added the backport-failed Applied to PRs when the automatic backport fails label Nov 11, 2024
junweid62 added a commit to junweid62/flow-framework that referenced this pull request Nov 11, 2024
…-project#952)

* Remove useCase and defaultParams field in WorkflowRequest

Signed-off-by: Junwei Dai <[email protected]>

* Remove useCase and defaultParams field in WorkflowRequest

Signed-off-by: Junwei Dai <[email protected]>

* Removed the constructor that has never been used and tested.

Signed-off-by: Junwei Dai <[email protected]>

---------

Signed-off-by: Junwei Dai <[email protected]>
Co-authored-by: Junwei Dai <[email protected]>
(cherry picked from commit 219aec5)
junweid62 added a commit to junweid62/flow-framework that referenced this pull request Nov 11, 2024
…-project#952)

* Remove useCase and defaultParams field in WorkflowRequest

Signed-off-by: Junwei Dai <[email protected]>

* Remove useCase and defaultParams field in WorkflowRequest

Signed-off-by: Junwei Dai <[email protected]>

* Removed the constructor that has never been used and tested.

Signed-off-by: Junwei Dai <[email protected]>

---------

Signed-off-by: Junwei Dai <[email protected]>
Co-authored-by: Junwei Dai <[email protected]>
(cherry picked from commit 219aec5)
junweid62 added a commit to junweid62/flow-framework that referenced this pull request Nov 11, 2024
…-project#952)

* Remove useCase and defaultParams field in WorkflowRequest

Signed-off-by: Junwei Dai <[email protected]>

* Remove useCase and defaultParams field in WorkflowRequest

Signed-off-by: Junwei Dai <[email protected]>

* Removed the constructor that has never been used and tested.

Signed-off-by: Junwei Dai <[email protected]>

---------

Signed-off-by: Junwei Dai <[email protected]>
Co-authored-by: Junwei Dai <[email protected]>
(cherry picked from commit 219aec5)
owaiskazi19 pushed a commit that referenced this pull request Nov 11, 2024
…est (#952) (#954)

* Remove useCase and defaultParams field in WorkflowRequest (#952)

* Remove useCase and defaultParams field in WorkflowRequest

Signed-off-by: Junwei Dai <[email protected]>

* Remove useCase and defaultParams field in WorkflowRequest

Signed-off-by: Junwei Dai <[email protected]>

* Removed the constructor that has never been used and tested.

Signed-off-by: Junwei Dai <[email protected]>

---------

Signed-off-by: Junwei Dai <[email protected]>
Co-authored-by: Junwei Dai <[email protected]>
(cherry picked from commit 219aec5)

* Remove useCase and defaultParams field in WorkflowRequest (#952)

* Remove useCase and defaultParams field in WorkflowRequest

Signed-off-by: Junwei Dai <[email protected]>

* Remove useCase and defaultParams field in WorkflowRequest

Signed-off-by: Junwei Dai <[email protected]>

* Removed the constructor that has never been used and tested.

Signed-off-by: Junwei Dai <[email protected]>

---------

Signed-off-by: Junwei Dai <[email protected]>
Co-authored-by: Junwei Dai <[email protected]>
(cherry picked from commit 219aec5)

---------

Signed-off-by: Junwei Dai <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport 2.x backport PRs to 2.x branch backport-failed Applied to PRs when the automatic backport fails
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] WorkflowRequest doesn't serialize the use case and default parameters over transport
3 participants