JackieTien97 commented on code in PR #12299:
URL: https://github.com/apache/iotdb/pull/12299#discussion_r1556969557
##########
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/queryengine/plan/analyze/cache/schema/dualkeycache/impl/DualKeyCacheImpl.java:
##########
@@ -240,6 +242,63 @@ private int evictOneCacheEntry() {
}
}
+ @Override
+ public void invalidateLastCache(PartialPath path) {
+ String measurement = path.getMeasurement();
+ PartialPath devicePath = path.getDevicePath();
+ Function<FK, Boolean> deviceFilter = null;
+ Function<SK, Boolean> measurementFilter = null;
+
+ if (PathPatternUtil.hasWildcard(devicePath.getFullPath())) {
+ deviceFilter = d -> devicePath.matchFullPath((PartialPath) d);
+ }
+ if (PathPatternUtil.isMultiLevelMatchWildcard(measurement)) {
+ measurementFilter = m -> true;
+ }
+ if (deviceFilter == null) {
+ deviceFilter = d -> ((PartialPath) d).equals(devicePath.getFullPath());
Review Comment:
```suggestion
deviceFilter = d -> ((PartialPath) d).equals(devicePath);
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]