*Hi good afternoon,* Thanks for measuring the cache invalidation cost. I pushed commit f85503e <https://github.com/apache/iotdb/pull/19431/commits/f85503ed02ffe2ef4f43154e357201649fdd0ac2> to address your review. DELETE DEVICES FROM sensors now invalidates the table’s cache directly, without reading any device TAGs. For filtered deletes, each pattern identifies its constrained TAGs once and checks only those positions. This preserves matching for IS NULL, LIKE, and literal values such as tag = '*'.
Both new regression tests reproduced the unnecessary TAG reads before the fix and passed afterward. All 36 related unit tests passed, and all five IoTDBDeviceIT cases passed with both one and three DataNodes. Could you take another look at PR #19431 <https://github.com/apache/iotdb/pull/19431>? *Thanks,DaZuiZui* Bryan Yang <[email protected]> 于2026年12月1日周二 14:51写道: > Hi Yuan Tian, > > Thank you for reviewing PR #19431 > <https://github.com/apache/iotdb/pull/19431>. I reproduced both issues > and pushed fixes in commit f63ab9a > <https://github.com/apache/iotdb/pull/19431/commits/f63ab9a4bd37ad7a1ff810932b319ade132c7f0b>. > Could you take another look when you have a chance? > > I added regression tests for both cases you reported. In the "**" table, > filtering on name = 'rack*' now returns only rack*, and deleting it > leaves pump untouched. With the device cache warmed, deleting ('*', NULL) > now reports one deletion and preserves ('plain', 'north'). > > All 17 related unit tests passed locally. The full IoTDBDeviceIT suite > also passed with both one and three DataNodes. > > Thanks, > DaZuiZui > > Bryan Yang <[email protected]> 于2026年11月28日周六 16:23写道: > >> Thanks for the review. I addressed both comments in commit 5d14c0f4 >> <https://github.com/apache/iotdb/pull/19431/commits/5d14c0f47b4d47178bcf2a1fcb2bea6fd86f58fc> >> and updated the PR title as suggested. >> >> The new TestVisitor test verifies that each TAG literal, including * and >> **, matches through a single direct lookup without scanning siblings. It >> also checks that a device with a trailing NULL TAG does not match. >> >> The integration test now queries rack* on every DataNode before >> deletion, then repeats the filtered SELECT and SHOW DEVICES after >> deletion. It checks that rack1 and its data survive, that absent * and ** >> values each report zero deletions, and that leading-asterisk and dotted >> literals match exactly. Each delete returns exactly one count row. >> >> All 15 DeviceFilterUtilTest tests passed locally. The integration test >> also passed with both one and three DataNodes. PR #19431 is ready for >> another look. <https://github.com/apache/iotdb/pull/19431> >> >> Thanks, >> DaZuiZui >> >> Yuan Tian <[email protected]> 于2026年11月28日周六 08:38写道: >> >>> Hi Bryan, >>> >>> Maybe @Tian Jiang could take a look. >>> >>> Best regards, >>> --------------------- >>> Yuan Tian >>> >>> >>> On Fri, Nov 27, 2026 at 4:54 PM Bryan Yang <[email protected]> wrote: >>> >>> > Hi IoTDB , >>> > >>> > Could you review PR #19431 <https://github.com/apache/iotdb/pull/19431 >>> >? >>> > It >>> > fixes a table-model bug reported against IoTDB 2.0.11 in issue #19423 >>> > <https://github.com/apache/iotdb/issues/19423>. >>> > >>> > For example, if two devices have TAG values rack* and *rack1*, an >>> equality >>> > condition for *rack** can select both devices for deletion. This >>> happens >>> > because device lookup interprets the trailing asterisk as a path >>> wildcard. >>> > The fix uses exact-name lookup for TAG values with leading or trailing >>> > asterisks. >>> > >>> > All 14 tests in DeviceFilterUtilTest passed locally. I also ran the >>> > regression test with one DataNode and with three DataNodes. In both >>> cases, >>> > the first delete removed only rack*, repeating it removed zero >>> devices, and >>> > rack1 and its data remained readable. >>> > >>> > Thanks, >>> > DaZuiZui >>> > >>> >>
