Add read and write optional enum sets methods to stream input and output#17556
Conversation
Signed-off-by: Andy Qin <qinandy@amazon.com>
Signed-off-by: Andy Qin <qinandy@amazon.com>
b386dbb to
2087291
Compare
Signed-off-by: Andy Qin <qinandy@amazon.com>
8df906d to
ad0c5ce
Compare
|
❌ Gradle check result for ad0c5ce: FAILURE Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change? |
Signed-off-by: Andy Qin <qinandy@amazon.com>
bf3a8f5 to
f65cfc8
Compare
|
@dbwiddis thanks for the review, I added unit tests to the BaseStreamTests in core so all the StreamInput implementations should inherit tests as well |
|
❌ Gradle check result for f65cfc8: FAILURE Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change? |
f65cfc8 to
9ff9553
Compare
|
❌ Gradle check result for 9ff9553: FAILURE Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change? |
|
DCO failing, looks like no email address:
|
|
❕ Gradle check result for 78de87a: UNSTABLE
Please review all flaky tests that succeeded after retry and create an issue if one does not already exist to track the flaky failure. |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #17556 +/- ##
============================================
- Coverage 72.43% 72.38% -0.05%
- Complexity 65694 65719 +25
============================================
Files 5311 5311
Lines 304937 304945 +8
Branches 44226 44226
============================================
- Hits 220872 220745 -127
- Misses 65912 66061 +149
+ Partials 18153 18139 -14 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Signed-off-by: Andy Qin <qinandy@amazon.com>
78de87a to
221f397
Compare
|
❌ Gradle check result for 221f397: FAILURE Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change? |
|
❕ Gradle check result for 221f397: UNSTABLE
Please review all flaky tests that succeeded after retry and create an issue if one does not already exist to track the flaky failure. |
…put (opensearch-project#17556) * Add read and write optional enum sets to stream Signed-off-by: Andy Qin <qinandy@amazon.com> * Only write set if it is non-empty Signed-off-by: Andy Qin <qinandy@amazon.com> * Update javadoc Signed-off-by: Andy Qin <qinandy@amazon.com> * Read false presence flag as empty set Co-authored-by: Daniel Widdis <widdis@gmail.com> Signed-off-by: Andy <qinandy@amazon.com> * Update javadoc Signed-off-by: Andy Qin <qinandy@amazon.com> * Add unit tests Signed-off-by: Andy Qin <qinandy@amazon.com> * Fix typos Signed-off-by: Andy Qin <qinandy@amazon.com> * Update changelog Signed-off-by: Andy Qin <qinandy@amazon.com> --------- Signed-off-by: Andy Qin <qinandy@amazon.com> Signed-off-by: Andy <qinandy@amazon.com> Co-authored-by: Daniel Widdis <widdis@gmail.com> Signed-off-by: Vinay Krishna Pudyodu <vinkrish.neo@gmail.com>
Description
In some plugins there are use cases to read and write optional EnumSets to and from StreamOutput/StreamInput, similar to existing
readOptionalStringCollection/writeOptionalStringListmethods.Currently this is done with plugin specific private helper methods, but since this functionality is common to multiple plugins and we are planning on building similar systems for geospatial and search relevance lab plugins, it may be more elegant to consolidate them in core. Examples:
Related Issues
n/a
Check List
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.