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

Adding new use cases #588

Merged
merged 1 commit into from
Mar 18, 2024
Merged

Conversation

amitgalitz
Copy link
Member

Description

This PR mainly adds a few new use cases, including there defaults and templates.
Additionally:

  1. Changed neural sparse step required fields based on new upgrades made in 2.12 so only name, version and format is required
  2. Added some extra escaping logic in substitution so i can handle substituting in complicated painless script
  3. Added logic in create pipeline step to escape " of an array.

Some open questions:

  1. I have quite a few templates that are very similar cause of slight changes in connectors, should I keep it that way for 2.13 or potentially have connectors get made with fields that are never used and that look like this:
    "post_process_function": "${{create_connector.actions.post_process_function}}"
    I was thinking it might confuse customers and not be the cleanest look.

  2. For some of the more nested param I want users to have control over like the mapping and processors the keys were getting pretty nested so I tried to limit them but then it might not be as consistent. Let me know if you think this can be improved. Another potential solution is to just have the key be ${{node_id.last-field-name}} or two fields back incase they are the same like in hybrid-template.

for example now I have:
"${{normalization-processor.combination.technique}}" and "${{normalization-processor.normalization.technique}}".

this could be changed to "${{create_search_pipeline.combination.technique}}" and "${{create_search_pipeline.normalization.technique}}"

other fields like: "text_embedding.field_map.input" will change to "create_ingest_pipeline.field_map.input"

other option is keeping as is or having the full path in dot form

Issues Resolved

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 Mar 18, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 72.95%. Comparing base (b148eb5) to head (a6fd478).

Additional details and impacted files
@@             Coverage Diff              @@
##               main     #588      +/-   ##
============================================
+ Coverage     72.85%   72.95%   +0.10%     
  Complexity      680      680              
============================================
  Files            81       81              
  Lines          3466     3479      +13     
  Branches        278      278              
============================================
+ Hits           2525     2538      +13     
  Misses          822      822              
  Partials        119      119              

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

Signed-off-by: Amit Galitzky <[email protected]>
Copy link
Member

@owaiskazi19 owaiskazi19 left a comment

Choose a reason for hiding this comment

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

Great work @amitgalitz! This feature would widen our plugin's use cases.

build.gradle Show resolved Hide resolved
Copy link
Member

@joshpalis joshpalis left a comment

Choose a reason for hiding this comment

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

A few questions

@amitgalitz amitgalitz merged commit eab5ab6 into opensearch-project:main Mar 18, 2024
30 of 34 checks passed
opensearch-trigger-bot bot pushed a commit that referenced this pull request Mar 18, 2024
adding new use cases

Signed-off-by: Amit Galitzky <[email protected]>
(cherry picked from commit eab5ab6)
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
joshpalis pushed a commit that referenced this pull request Mar 18, 2024
* Adding new use cases (#588)

adding new use cases

Signed-off-by: Amit Galitzky <[email protected]>
(cherry picked from commit eab5ab6)
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>

* removing _doc

Signed-off-by: Amit Galitzky <[email protected]>

---------

Signed-off-by: Amit Galitzky <[email protected]>
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Amit Galitzky <[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 skip-changelog
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants