[TACHYON-220] WIP Comments describing issues and possible solutions 

Some initial comments to help improve the performance of master info. From what I gather there is locking on stack local objects that are never really put back into the map. I would appreciate suggestions before implementing it, hence the WIP tag.
Agree
On Nov 20, 2014 9:47 AM, "Manu Goyal" <notifications@github.com> wrote:

> In core/src/main/java/tachyon/master/MasterInfo.java:
>
> > @@ -240,8 +242,10 @@ public void run() {
> >    private final Object mRootLock = new Object();
> >
> >    // A map from file ID's to Inodes. All operations on it are currently synchronized on mRootLock.
> > -  private final Map<Integer, Inode> mFileIdToInodes = new HashMap<Integer, Inode>();
> > -  private final Map<Integer, Dependency> mFileIdToDependency = new HashMap<Integer, Dependency>();
> > +  private final ConcurrentHashMap<Integer, Inode> mFileIdToInodes =
>
> I'm not sure we need to be changing any of these maps to
> ConcurrentHashMaps right now. Right now, all of these maps are called
> inside a synchronized (mRootLock) or synchcronized (mWorkers) or some other
> type of synchronized block, so nobody will be running concurrent operations
> on them. Maybe we keep these as regular HashMaps until we figure out how to
> refactor the MasterInfo to remove those synchronized blocks.
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/amplab/tachyon/pull/527/files#r20663634>.
>