Skip to content

Support Uber's H3 geospatial indexing system as geohex_grid (#179)#180

Merged
VijayanB merged 1 commit into
opensearch-project:2.xfrom
VijayanB:add-geo-hex-2.x
Oct 26, 2022
Merged

Support Uber's H3 geospatial indexing system as geohex_grid (#179)#180
VijayanB merged 1 commit into
opensearch-project:2.xfrom
VijayanB:add-geo-hex-2.x

Conversation

@VijayanB
Copy link
Copy Markdown
Member

Description

This PR is back port of #179 . However, in 3.x, Aggregation base class like InternalGeoXxxx were refactored. Hence, we have to use old class as base class for 2.x branch.

Issues Resolved

#98

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.

…ch-project#179)

* Import h3 library (opensearch-project#154)

Made following changes to make it compatible:
1. Rename package from elasticsearch to opensearch.geospatial
2. Update License headers
3. Update build file
4. Update settings to include sub projects

* Use Transport Request (opensearch-project#164)

Remove usage of deprecated BaseNodeRequest

* Update http client package to resolve build failure (opensearch-project#168) (opensearch-project#171)

* Introduce H3 min resolution constant (opensearch-project#165)

H3 version 1 has 16 resolutions, numbered 0 through 15.
Introduced a constant to represent min value, similar
to max value.

* Add geohex aggregation (opensearch-project#160)

This aggregation will use uber's h3 to group coordinates into H3 cell.
Created new aggregation type geohex_grid. The precision will be between
0 and 15. This aggreation has default precision as 5,
similar to geohash and geotile.

Signed-off-by: Vijayan Balasubramanian <balasvij@amazon.com>

* Add integration test (opensearch-project#176)

Included integration test for geohex_grid.

Signed-off-by: Vijayan Balasubramanian <balasvij@amazon.com>
@VijayanB VijayanB requested a review from a team October 26, 2022 01:52
@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Oct 26, 2022

Codecov Report

Attention: Patch coverage is 88.04348% with 11 lines in your changes missing coverage. Please review.

Project coverage is 84.99%. Comparing base (bfaba9c) to head (dcb2b40).
Report is 83 commits behind head on 2.x.

Files with missing lines Patch % Lines
...s/bucket/geogrid/GeoHexGridAggregationBuilder.java 76.00% 6 Missing ⚠️
...arch/aggregations/bucket/geogrid/GeoHexHelper.java 75.00% 2 Missing and 2 partials ⚠️
...search/aggregations/bucket/geogrid/GeoHexGrid.java 90.90% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##                2.x     #180      +/-   ##
============================================
+ Coverage     84.73%   84.99%   +0.25%     
- Complexity      332      376      +44     
============================================
  Files            44       52       +8     
  Lines          1094     1186      +92     
  Branches         97       98       +1     
============================================
+ Hits            927     1008      +81     
- Misses          128      137       +9     
- Partials         39       41       +2     

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@martin-gaievski
Copy link
Copy Markdown
Member

We probably need 2.4 label for this PR

@VijayanB VijayanB added the v2.4.0 'Issues and PRs related to version v2.4.0' label Oct 26, 2022
@VijayanB VijayanB merged commit 953337b into opensearch-project:2.x Oct 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature v2.4.0 'Issues and PRs related to version v2.4.0'

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants