zookeeper-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] [zookeeper] maoling commented on a change in pull request #1010: ZOOKEEPER-3425:ttl node should not have the children and ranking the ttl by expireTime asc for the performance
Date Mon, 08 Jul 2019 12:16:06 GMT
maoling commented on a change in pull request #1010: ZOOKEEPER-3425:ttl node should not have
the children and ranking the ttl by expireTime asc for the performance
URL: https://github.com/apache/zookeeper/pull/1010#discussion_r301061021
 
 

 ##########
 File path: zookeeper-server/src/main/java/org/apache/zookeeper/server/DataTree.java
 ##########
 @@ -1305,7 +1363,7 @@ public void deserialize(InputArchive ia, String tag) throws IOException
{
                 if (ephemeralType == EphemeralType.CONTAINER) {
                     containers.add(path);
                 } else if (ephemeralType == EphemeralType.TTL) {
-                    ttls.add(path);
+                    ttls.add(new TTLNode(path, node.stat.getCtime() + ephemeralType.getValue(node.stat.getEphemeralOwner())));
 
 Review comment:
   - `ttls` is a set only in the memory without any serializing into disk, so no backward
compatibility.
   
   > Are you an user of TTL nodes and you saw a bottle neck?
     - Look at the github description firstly
     - the ttl is a very import feature for a key-value storage system.Currently it's rusted.Look
at the [ZOOKEEPER-3428](https://issues.apache.org/jira/browse/ZOOKEEPER-3428) which wants
to improve the ttl further.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

Mime
View raw message