Skip to content

Delete the tsfile and related attachments When only one table and dat…#16687

Merged
jt2594838 merged 18 commits intoapache:masterfrom
zerolbsony:optimize_delete_tsfile
Nov 10, 2025
Merged

Delete the tsfile and related attachments When only one table and dat…#16687
jt2594838 merged 18 commits intoapache:masterfrom
zerolbsony:optimize_delete_tsfile

Conversation

@zerolbsony
Copy link
Contributor

Delete the tsfile and related attachments When only one table and data is cleared fully in the tsfile. Avoid to create a same table and insert data slower after delete a table.

Copy link
Contributor

@jt2594838 jt2594838 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also add some tests

@jt2594838 jt2594838 merged commit f675264 into apache:master Nov 10, 2025
27 of 28 checks passed
JackieTien97 pushed a commit that referenced this pull request Nov 26, 2025
#16687)

* Delete the tsfile and related attachments When only one table and data is cleared fully in the tsfile

* Adjust logic is only effective in the table model, and refers to the tree model to delete files related to tsfile.

* Supply an IT test to validate if involved supporting files about tsfile are deleted after delete all data in a table.

* Resolve problem reported that file is not exist in the situation of 1C3D.

* File may be not exist in the situation of 1C3D so that verify if it is exists first before scan the directory.

* Fix the logic that verify only on table When multiple devices in same one table.

* Don't delete file until all devices matched by time.

* Avoid to delete the file when the device that need be deleted and  other devices are all in the same one tsfile.

* Increment a break to avoid extra I/O in the same file.

* After delete all datas from a table, validate multiple devices involved files are deleted by different time range if it's success.

* Add some logs and trace cause.

* Debug

* Change into logger

* Decrement interval time

* Clean environment before run testCompletelyDeleteTable

* Recover all workflow yml files, log level need change into "debug" level.

* Add a verification due to performance considerations.

* Add some verification due to performance considerations.

(cherry picked from commit f675264)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

Comments