You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@iotdb.apache.org by "Chao Wang (Jira)" <ji...@apache.org> on 2021/03/09 07:45:00 UTC

[jira] [Commented] (IOTDB-1184) A separate file-purging thread

    [ https://issues.apache.org/jira/browse/IOTDB-1184?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17297908#comment-17297908 ] 

Chao Wang commented on IOTDB-1184:
----------------------------------

+ 1

> A separate file-purging thread
> ------------------------------
>
>                 Key: IOTDB-1184
>                 URL: https://issues.apache.org/jira/browse/IOTDB-1184
>             Project: Apache IoTDB
>          Issue Type: Improvement
>          Components: Core/Engine
>            Reporter: Tian Jiang
>            Priority: Major
>
> Currently, we use a synchronized file purging strategy, which means the thread that wants to remove a TsFile will try write-locking the file before removing it. If the file is being queried, the thread may have to wait for a relatively long time until the corresponding queries are finished and the file is read-unlocked.
> So I propose a separate purging thread, any other threads that want to delete a TsFile may register the file in that thread, and the purging thread will periodically check the registered files, if they can be locked, the thread will write lock and remove them physically. 



--
This message was sent by Atlassian Jira
(v8.3.4#803005)