POI缓存key升版v2,作废坐标未截断的旧缓存

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
王文艳
2026-08-16 21:08:35 +08:00
parent 7665e2f3ce
commit d33bb1c75c
@@ -120,7 +120,8 @@ public class BaiduApiServiceImpl extends AbstractHttpApiService implements Baidu
@SuppressWarnings("unchecked")
public List<BaiduPlacePoi> searchNearbyPoi(final String city ,final double lat,final double lng, final double radius) {
String cacheKey = city + "_" + lat + "_" + lng + "_" + radius;
// v2: 坐标保留6位小数后升版,作废旧缓存
String cacheKey = "v2_" + city + "_" + lat + "_" + lng + "_" + radius;
Object cached = CacheUtils.getValue(this.getClass(), cacheKey);
if (cached != null) {
return (List<BaiduPlacePoi>) cached;