Skip to content

Geospatial indexing using RTree - #4355

Merged
normen662 merged 13 commits into
FoundationDB:mainfrom
MMcM:geospatial-rtree
Nov 17, 2026
Merged

normen662 merged 13 commits into
FoundationDB:mainfrom
MMcM:geospatial-rtree

Conversation

@MMcM

@MMcM MMcM commented Jul 15, 2026 •

Copy link
Copy Markdown
Collaborator

As an alternative to Geophile.

Includes #4369.

@MMcM
MMcM force-pushed the geospatial-rtree branch from 405c2de to 6947692 Compare July 15, 2026 03:18
@MMcM MMcM added the enhancement New feature or request label Jul 15, 2026
@MMcM
MMcM force-pushed the geospatial-rtree branch 2 times, most recently from e304293 to 7331c29 Compare July 18, 2026 03:04

@normen662 normen662 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

The comment I gave + the general comment that we probably should put a proper floating point support into the RTree index itself, so some of the logic here could be removed here.

@MMcM
MMcM force-pushed the geospatial-rtree branch from 7331c29 to 0ed2be2 Compare August 5, 2026 19:46
@MMcM

MMcM commented Aug 6, 2026

Copy link
Copy Markdown
Collaborator Author

proper floating point support into the RTree index

Added the Hilbert value based on the double bit pattern, as discussed. Plus a few other places that assumed longs.

@MMcM

MMcM commented Aug 6, 2026

Copy link
Copy Markdown
Collaborator Author

I did not change the geospatial R-tree to use double straight, but kept the fixed-point multiplier, since geo coordinates aren't really arbitrary floats.

@MMcM
MMcM force-pushed the geospatial-rtree branch from 4a24b51 to a856779 Compare August 19, 2026 15:29
@MMcM
MMcM marked this pull request as ready for review August 19, 2026 21:26
@MMcM
MMcM force-pushed the geospatial-rtree branch from 97f56ba to 485dcbe Compare August 31, 2026 21:05
@MMcM
MMcM force-pushed the geospatial-rtree branch from 485dcbe to 449bb76 Compare October 25, 2026 14:19
@MMcM
MMcM force-pushed the geospatial-rtree branch 3 times, most recently from 4d5107e to 7fa368a Compare November 11, 2026 17:15
MMcM added 11 commits November 16, 2026 07:10
Move common files up from spatial. The alternative would be to have the new index down there in a new package, but that makes planner integration harder.
 * Validate geospatial coordinate types in encodePoint
 * Preserve fractional dimension widths in RTree.Rectangle.area()
 * Fix overflow-bound comment in GeospatialRTreeIndexHelper
 * Widen geospatial coordinate type guard to any Number
 * Correct MAX_PRECISION_DIGITS overflow-bound comment
@normen662
normen662 merged commit 7138d3c into FoundationDB:main Nov 17, 2026
15 checks passed
@MMcM
MMcM deleted the geospatial-rtree branch November 17, 2026 19:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants