POI缓存key升版v2,作废坐标未截断的旧缓存
Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
+2
-1
@@ -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;
|
||||
|
||||
Reference in New Issue
Block a user