HDFS-5535 subtasks: HDFS-5496. Make replication queue initialization asynchronous. (Vinay via jing9) HDFS-5645. Support upgrade marker in editlog streams. (szetszwo) HDFS-5752. Add a new DFSAdmin command to query, start and finalize rolling upgrade. (szetszwo) HDFS-5786. Support QUERY and FINALIZE actions of rolling upgrade. (szetszwo) HDFS-5753. Add new Namenode startup options for downgrade and rollback using upgrade marker. (szetszwo) HDFS-5835. Add a new option for starting Namenode when rolling upgrade is in progress. (szetszwo) HDFS-5754. Split LayoutVerion into NameNodeLayoutVersion and DataNodeLayoutVersion. (Brandon Li via szetszwo) HDFS-5848. Add rolling upgrade status to heartbeat response. (szetszwo) HDFS-5890. Avoid NPE in Datanode heartbeat. (Vinay via brandonli) HDFS-5869. When starting rolling upgrade or NN restarts, NN should create a checkpoint right before the upgrade marker. (szetszwo) HDFS-5874. Should not compare DataNode current layout version with that of NameNode in DataStrorage. (brandonli) HDFS-5889. When starting rolling upgrade, create a fs image for rollback so that the standby namenode can create checkpoints during upgrade. (szetszwo & jing9) HDFS-5535. Add BlockPoolSliceStorage 'trash' to handle block deletions during rolling upgrades. (Arpit Agarwal) HDFS-5494. Merge Protobuf-based-FSImage code from trunk - fix build break after the merge. (Jing Zhao via Arpit Agarwal) HDFS-5585. Provide admin commands for data node upgrade (kihwal) HDFS-5920. Support rollback of rolling upgrade in NameNode and JournalNodes. (jing9) HDFS-5945. Add rolling upgrade information to fsimage; and disallow upgrade and rolling upgrade to be started simultaneously. (szetszwo & jing9) HDFS-5966. Fix rollback of rolling upgrade in NameNode HA setup. (jing9 via szetszwo) HDFS-5974. Fix compilation error, NameNodeLayoutVersion and DataNodeLayoutVersion after merge from trunk. (szetszwo) HDFS-5963. TestRollingUpgrade#testSecondaryNameNode causes subsequent tests to fail. (szetszwo via Arpit Agarwal)