code: private String getMergedMetadataForPartitionAndBranch(String partitionId, int branchId) {
      String mergedMd = null;
      MetadataMerger<String> mergerForBranch = metadataMergers.get(new PartitionIdentifier(partitionId, branchId));
      if (mergerForBranch != null) {
        mergedMd = mergerForBranch.getMergedMetadata();
        if (mergedMd == null) {
          LOG.warn("Metadata merger for branch {} returned null - bug in merger?", branchId);
        }
      }
  
      return mergedMd;
    }
docs: /*
  Get the merged metadata given a workunit state and branch id. This method assumes
  all intermediate metadata has already been passed to the MetadataMerger.
  
  If metadata mergers are not configured, instead return the metadata from job config that was
  passed in by the user.