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

[backport 2.8] Replace re2 with RegExp in timeline and add unit tests #4208

Merged
merged 1 commit into from
Jun 8, 2023

Conversation

ananzh
Copy link
Member

@ananzh ananzh commented Jun 1, 2023

Description

Remove re2 usage and replace it with JavaScript built-in RegExp object. Also add more unit tests to make sure that using RegExp has same expressions as using re2 library.

Issue Resolve

#3901

Backport PR

#3908

Check List

  • All tests pass
    • yarn test:jest
    • yarn test:jest_integration
    • yarn test:ftr
  • New functionality includes testing.
  • New functionality has been documented.
  • Update CHANGELOG.md
  • Commits are signed per the DCO using --signoff

Remove re2 usage and replace it with JavaScript built-in
RegExp object. Also add more unit tests to make sure that
using RegExp has same expressions as using re2 library.

Issue Resolve
opensearch-project#3901

Backport PR
opensearch-project#3908

Signed-off-by: Anan Zhuang <ananzh@amazon.com>
@codecov
Copy link

codecov bot commented Jun 1, 2023

Codecov Report

Merging #4208 (2620585) into 2.8 (4ae0e3f) will decrease coverage by 0.06%.
The diff coverage is 72.41%.

@@            Coverage Diff             @@
##              2.8    #4208      +/-   ##
==========================================
- Coverage   66.35%   66.30%   -0.06%     
==========================================
  Files        3229     3229              
  Lines       62091    62093       +2     
  Branches     9611     9612       +1     
==========================================
- Hits        41201    41168      -33     
- Misses      18570    18599      +29     
- Partials     2320     2326       +6     
Flag Coverage Δ
Linux 66.30% <72.41%> (-0.01%) ⬇️
Windows ?

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
src/core/server/plugins/types.ts 100.00% <ø> (ø)
src/core/server/plugins/plugins_system.ts 91.13% <41.66%> (ø)
src/dev/build/tasks/patch_native_modules_task.ts 90.32% <85.71%> (+4.11%) ⬆️
...server/plugins/discovery/plugin_manifest_parser.ts 82.14% <100.00%> (ø)
src/core/server/plugins/plugin.ts 100.00% <100.00%> (ø)
...vis_type_timeline/server/series_functions/label.js 100.00% <100.00%> (ø)

... and 8 files with indirect coverage changes

@joshuarrrr joshuarrrr added the not in release PRs backported to already shipped releases with no future release planned label Jun 8, 2023
@joshuarrrr
Copy link
Member

whitesource check can be ignored.

@joshuarrrr joshuarrrr merged commit 7489db9 into opensearch-project:2.8 Jun 8, 2023
@ashwin-pc ashwin-pc changed the title [2.8 backport] Replace re2 with RegExp in timeline and add unit tests [backport 2.8] Replace re2 with RegExp in timeline and add unit tests Jun 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
not in release PRs backported to already shipped releases with no future release planned
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants