Class TTLManager
java.lang.Object
org.apache.iotdb.confignode.manager.TTLManager
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionlonggetDatabaseMaxTTL(String database) Get the maximum ttl of the subtree of the corresponding database.intvoidOnly used for upgrading from old database-level ttl to device-level ttl.setTTL(DatabaseSchemaPlan databaseSchemaPlan, boolean isGeneratedByPipe) Set ttl when creating database.setTTL(SetTTLPlan setTTLPlan, boolean isGeneratedByPipe) showTTL(ShowTTLPlan showTTLPlan) unsetTTL(SetTTLPlan setTTLPlan, boolean isGeneratedByPipe)
-
Constructor Details
-
TTLManager
-
-
Method Details
-
setTTL
public TSStatus setTTL(DatabaseSchemaPlan databaseSchemaPlan, boolean isGeneratedByPipe) throws IllegalPathException Set ttl when creating database.- Throws:
IllegalPathException
-
setTTL
-
unsetTTL
-
showTTL
-
getAllTTL
-
getTTLCount
public int getTTLCount() -
getDatabaseMaxTTL
Get the maximum ttl of the subtree of the corresponding database.- Parameters:
database- the path of the database.- Returns:
- the maximum ttl of the subtree of the corresponding database. return NULL_TTL if the TTL is not set or the database does not exist.
-
setTTL
Only used for upgrading from old database-level ttl to device-level ttl.- Throws:
IllegalPathException
-