hadoop-zookeeper-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Erik Holstad <erikhols...@gmail.com>
Subject Accessing internal variables in DataNode and synchronization.
Date Fri, 11 Sep 2009 21:14:45 GMT
In most places in the server side code, internal variables are accessed
directly via something like, node.parent... instead of making the variable
private and using getters and setters, what is the purpose of this?

Another question is why the synchronization on for example the DataNode is
done on the node itself and not on the variables access, it seems reasonable
to me that 2 different threads would be allowed to modify for example the
data and the children at the same time, or is there something that I'm
missing here, watchers?


  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message