Skip to content

Conversation

@kikoso
Copy link
Collaborator

@kikoso kikoso commented Sep 4, 2025

The clustering logic for the ContinuousZoomEuclideanCentroidAlgorithm was previously misplaced in the getClusteringItems method. This resulted in the base class's clustering algorithm being used, which does not correctly apply the intended Euclidean distance check.

This change refactors the implementation by moving the continuous zoom scaling and Euclidean distance logic into an
overridden getClusters method, ensuring the correct clustering algorithm is executed. The getClusteringItems method now reverts to its default behavior of returning all items to be considered for clustering.

@googlemaps-bot
Copy link
Contributor

Code Coverage

Overall Project 39.65% -0.06% 🍏
Files changed 91.41% 🍏

File Coverage
ContinuousZoomEuclideanCentroidAlgorithm.java 94.14% -5.86% 🍏

@kikoso kikoso marked this pull request as ready for review September 5, 2025 17:46
@dkhawk dkhawk merged commit 1329850 into main Sep 5, 2025
8 checks passed
@dkhawk dkhawk deleted the fix/continuous-zoom-clustering-logic branch September 5, 2025 18:48
googlemaps-bot pushed a commit that referenced this pull request Sep 5, 2025
## [3.16.2](v3.16.1...v3.16.2) (2025-09-05)

### Bug Fixes

* Correct continuous zoom clustering implementation ([#1587](#1587)) ([1329850](1329850))
@googlemaps-bot
Copy link
Contributor

🎉 This PR is included in version 3.16.2 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants