code: static public Value get( Key key, int len, int priority ) {
      while( true ) {
        // Read the Cloud once per put-attempt, to keep a consistent snapshot.
        H2O cloud = H2O.CLOUD;
        Value val = H2O.get(key);
        // Hit in local cache?
        if( val != null ) {
          if( len > val._max ) len = val._max; // See if we have enough data cached locally
          if( len == 0 || val.rawMem() != null || val.rawPOJO() != null || val.isPersisted() ) return val;
          assert !key.home(); // Master must have *something*; we got nothing & need to fetch
        }
  
        // While in theory we could read from any replica, we always need to
        // inform the home-node that his copy has been Shared... in case it
        // changes and he needs to issue an invalidate.  For now, always and only
        // fetch from the Home node.
        H2ONode home = cloud._memary[key.home(cloud)];
  
        // If we missed in the cache AND we are the home node, then there is
        // no V for this K (or we have a disk failure).
        if( home == H2O.SELF ) return null;
  
        // Pending write to same key from this node?  Take that write instead.
        // Moral equivalent of "peeking into the cpu store buffer".  Can happen,
        // e.g., because a prior 'put' of a null (i.e. a remove) is still mid-
        // send to the remote, so the local get has missed above, but a remote
        // get still might 'win' because the remote 'remove' is still in-progress.
        for( RPC<?> rpc : home.tasks() )
          if( rpc._dt instanceof TaskPutKey ) {
            assert rpc._target == home;
            TaskPutKey tpk = (TaskPutKey)rpc._dt;
            Key k = tpk._key;
            if( k != null && key.equals(k) )
              return tpk._xval;
          }
  
        return TaskGetKey.get(home,key,priority);
      }
    }
docs: User-Weak-Get a Key from the distributed cloud.