nus-yam/ex-repair huggingface dataset:
Program: 173153
Project: 173153
Buggy source:
private static boolean copyDoubles(double[] data,ByteBuffer targetBuffer,SerializeState state){
  int totalBytes=state.getTotalBytes();
  int remainingCapacity=targetBuffer.remaining();
  int bytesCopied=state.getBytesCopied();
  int remainingToCopy=data.length - bytesCopied / 8;
  int canCopy=(remainingCapacity > remainingToCopy ? remainingToCopy : remainingCapacity) / 8;
  int offSet=bytesCopied / 8;
  for (int i=0; i < canCopy; i++) {
    targetBuffer.putDouble(data[i + offSet]);
  }
  totalBytes+=canCopy * 8;
  state.setTotalBytes(totalBytes);
  if (canCopy == remainingToCopy) {
    state.setData(null);
    state.setBytesCopied(0);
    return true;
  }
 else {
    state.setBytesCopied(canCopy * 8 + bytesCopied);
    return false;
  }
}

Fixed version (ground truth):
private static boolean copyDoubles(double[] data,ByteBuffer targetBuffer,SerializeState state){
  int totalBytes=state.getTotalBytes();
  int remainingCapacity=targetBuffer.remaining();
  int bytesCopied=state.getBytesCopied();
  int remainingToCopy=data.length * 8 - bytesCopied;
  int canCopy=(remainingCapacity > remainingToCopy ? remainingToCopy : remainingCapacity) / 8;
  int offSet=bytesCopied / 8;
  for (int i=0; i < canCopy; i++) {
    targetBuffer.putDouble(data[i + offSet]);
  }
  totalBytes+=canCopy * 8;
  state.setTotalBytes(totalBytes);
  if ((canCopy * 8) == remainingToCopy) {
    state.setData(null);
    state.setBytesCopied(0);
    return true;
  }
 else {
    state.setBytesCopied(canCopy * 8 + bytesCopied);
    return false;
  }
}
Program: 173154
Project: 173154
Buggy source:
private static boolean copyLong(long[] data,ByteBuffer targetBuffer,SerializeState state){
  int totalBytes=state.getTotalBytes();
  int remainingCapacity=targetBuffer.remaining();
  int bytesCopied=state.getBytesCopied();
  int remainingToCopy=data.length - bytesCopied / 8;
  int canCopy=(remainingCapacity > remainingToCopy ? remainingToCopy : remainingCapacity) / 8;
  int offSet=bytesCopied / 8;
  for (int i=0; i < canCopy; i++) {
    targetBuffer.putLong(data[i + offSet]);
  }
  totalBytes+=canCopy * 8;
  state.setTotalBytes(totalBytes);
  if (canCopy == remainingToCopy) {
    state.setData(null);
    state.setBytesCopied(0);
    return true;
  }
 else {
    state.setBytesCopied(canCopy * 8 + bytesCopied);
    return false;
  }
}

Fixed version (ground truth):
private static boolean copyLong(long[] data,ByteBuffer targetBuffer,SerializeState state){
  int totalBytes=state.getTotalBytes();
  int remainingCapacity=targetBuffer.remaining();
  int bytesCopied=state.getBytesCopied();
  int remainingToCopy=data.length * 8 - bytesCopied;
  int canCopy=(remainingCapacity > remainingToCopy ? remainingToCopy : remainingCapacity) / 8;
  int offSet=bytesCopied / 8;
  for (int i=0; i < canCopy; i++) {
    targetBuffer.putLong(data[i + offSet]);
  }
  totalBytes+=canCopy * 8;
  state.setTotalBytes(totalBytes);
  if ((canCopy * 8) == remainingToCopy) {
    state.setData(null);
    state.setBytesCopied(0);
    return true;
  }
 else {
    state.setBytesCopied(canCopy * 8 + bytesCopied);
    return false;
  }
}
Program: 173155
Project: 173155
Buggy source:
private static boolean copyShort(short[] data,ByteBuffer targetBuffer,SerializeState state){
  int totalBytes=state.getTotalBytes();
  int remainingCapacity=targetBuffer.remaining();
  int bytesCopied=state.getBytesCopied();
  int remainingToCopy=data.length - bytesCopied / 2;
  int canCopy=(remainingCapacity > remainingToCopy ? remainingToCopy : remainingCapacity) / 2;
  int offSet=bytesCopied / 2;
  for (int i=0; i < canCopy; i++) {
    targetBuffer.putShort(data[i + offSet]);
  }
  totalBytes+=canCopy * 2;
  state.setTotalBytes(totalBytes);
  if (canCopy == remainingToCopy) {
    state.setData(null);
    state.setBytesCopied(0);
    return true;
  }
 else {
    state.setBytesCopied(canCopy * 2 + bytesCopied);
    return false;
  }
}

Fixed version (ground truth):
private static boolean copyShort(short[] data,ByteBuffer targetBuffer,SerializeState state){
  int totalBytes=state.getTotalBytes();
  int remainingCapacity=targetBuffer.remaining();
  int bytesCopied=state.getBytesCopied();
  int remainingToCopy=data.length * 2 - bytesCopied;
  int canCopy=(remainingCapacity > remainingToCopy ? remainingToCopy : remainingCapacity) / 2;
  int offSet=bytesCopied / 2;
  for (int i=0; i < canCopy; i++) {
    targetBuffer.putShort(data[i + offSet]);
  }
  totalBytes+=canCopy * 2;
  state.setTotalBytes(totalBytes);
  if ((canCopy * 2) == remainingToCopy) {
    state.setData(null);
    state.setBytesCopied(0);
    return true;
  }
 else {
    state.setBytesCopied(canCopy * 2 + bytesCopied);
    return false;
  }
}
Program: 173156
Project: 173156
Buggy source:
/** 
 * Buffers the inputs before submitting it to the store. If the value is already present it will be replaced
 */
public boolean putBulk(int opID,String key,ByteBuffer value){
  if (!keyMap.containsKey(opID) && !memoryManager.containsKey(opID,key)) {
    registerKey(opID,key,MemoryManagerContext.BULK_MM_STEP_SIZE);
  }
 else {
    delete(opID,key);
    registerKey(opID,key,MemoryManagerContext.BULK_MM_STEP_SIZE);
  }
  keyMapCurrent.get(opID).put(key,1);
  keyMapBuffers.get(opID).get(key).add(value);
  keyBufferSizes.get(opID).put(key,keyBufferSizes.get(opID).get(key) + value.limit());
  return true;
}

Fixed version (ground truth):
/** 
 * Buffers the inputs before submitting it to the store. If the value is already present it will be replaced
 */
public boolean putBulk(int opID,String key,ByteBuffer value){
  if (value.position() != 0) {
    value.flip();
  }
  if (!keyMap.get(opID).containsKey(key) && !memoryManager.containsKey(opID,key)) {
    registerKey(opID,key,MemoryManagerContext.BULK_MM_STEP_SIZE);
  }
 else {
    delete(opID,key);
    registerKey(opID,key,MemoryManagerContext.BULK_MM_STEP_SIZE);
  }
  keyMapCurrent.get(opID).put(key,1);
  keyMapBuffers.get(opID).get(key).add(value);
  keyBufferSizes.get(opID).put(key,keyBufferSizes.get(opID).get(key) + value.limit());
  return true;
}
Program: 173157
Project: 173157
Buggy source:
/** 
 * Buffers the inputs before submitting to the store. The new values will be appended to the end
 */
public boolean appendBulk(int opID,String key,ByteBuffer value){
  if (!keyMap.containsKey(opID)) {
    registerKey(opID,key,MemoryManagerContext.BULK_MM_STEP_SIZE);
  }
  int step=keyMap.get(opID).get(key);
  int currentCount=keyMapCurrent.get(opID).get(key);
  if ((currentCount + 1) % step == 0) {
    flush(opID,key,value);
    keyMapCurrent.get(opID).put(key,currentCount + 1);
  }
 else {
    keyMapCurrent.get(opID).put(key,currentCount + 1);
    keyMapBuffers.get(opID).get(key).add(value);
    keyBufferSizes.get(opID).put(key,keyBufferSizes.get(opID).get(key) + value.limit());
  }
  return true;
}

Fixed version (ground truth):
/** 
 * Buffers the inputs before submitting to the store. The new values will be appended to the end
 */
public boolean appendBulk(int opID,String key,ByteBuffer value){
  if (value.position() != 0) {
    value.flip();
  }
  if (!keyMap.get(opID).containsKey(key)) {
    registerKey(opID,key,MemoryManagerContext.BULK_MM_STEP_SIZE);
  }
  int step=keyMap.get(opID).get(key);
  int currentCount=keyMapCurrent.get(opID).get(key);
  if ((currentCount + 1) % step == 0) {
    flush(opID,key,value);
    keyMapCurrent.get(opID).put(key,currentCount + 1);
  }
 else {
    keyMapCurrent.get(opID).put(key,currentCount + 1);
    keyMapBuffers.get(opID).get(key).add(value);
    keyBufferSizes.get(opID).put(key,keyBufferSizes.get(opID).get(key) + value.limit());
  }
  return true;
}
Program: 173158
Project: 173158
Buggy source:
/** 
 * Buffers the inputs before submitting to the store. The new values will be appended to the end
 */
public boolean appendBulk(int opID,String key,ByteBuffer value){
  if (!keyMap.containsKey(key)) {
    registerKey(opID,key,MemoryManagerContext.BULK_MM_STEP_SIZE);
  }
  int step=keyMap.get(opID).get(key);
  int currentCount=keyMapCurrent.get(opID).get(key);
  if ((currentCount + 1) % step == 0) {
    flush(opID,key,value);
    keyMapCurrent.get(opID).put(key,currentCount + 1);
  }
 else {
    keyMapCurrent.get(opID).put(key,currentCount + 1);
    keyMapBuffers.get(opID).get(key).add(value);
    keyBufferSizes.get(opID).put(key,keyBufferSizes.get(opID).get(key) + value.limit());
  }
  return true;
}

Fixed version (ground truth):
/** 
 * Buffers the inputs before submitting to the store. The new values will be appended to the end
 */
public boolean appendBulk(int opID,String key,ByteBuffer value){
  if (!keyMap.containsKey(opID)) {
    registerKey(opID,key,MemoryManagerContext.BULK_MM_STEP_SIZE);
  }
  int step=keyMap.get(opID).get(key);
  int currentCount=keyMapCurrent.get(opID).get(key);
  if ((currentCount + 1) % step == 0) {
    flush(opID,key,value);
    keyMapCurrent.get(opID).put(key,currentCount + 1);
  }
 else {
    keyMapCurrent.get(opID).put(key,currentCount + 1);
    keyMapBuffers.get(opID).get(key).add(value);
    keyBufferSizes.get(opID).put(key,keyBufferSizes.get(opID).get(key) + value.limit());
  }
  return true;
}
Program: 173159
Project: 173159
Buggy source:
public void progress(){
  for (  int t : messages.keySet()) {
    if (batchDone.get(t)) {
      continue;
    }
    boolean allFinished=true;
    Map<Integer,List<Object>> map=messages.get(t);
    Map<Integer,Boolean> finishedForTarget=finished.get(t);
    Map<Integer,Integer> countMap=counts.get(t);
    boolean found=true;
    for (    Map.Entry<Integer,List<Object>> e : map.entrySet()) {
      if (e.getValue().size() == 0 && !finishedForTarget.get(e.getKey())) {
        found=false;
      }
      if (!finishedForTarget.get(e.getKey())) {
        allFinished=false;
      }
    }
    if (found) {
      List<Object> out=new ArrayList<>();
      for (      Map.Entry<Integer,List<Object>> e : map.entrySet()) {
        List<Object> valueList=e.getValue();
        if (valueList.size() > 0) {
          Object value=valueList.get(0);
          out.add(value);
          allFinished=false;
          valueList.remove(0);
        }
      }
      finalMessages.get(t).addAll(out);
    }
 else {
      allFinished=false;
    }
    if (allFinished) {
      LOG.info(String.format("String_Node_Str",executor,t));
      batchDone.put(t,true);
      gatherBatchReceiver.receive(t,finalMessages.get(t).iterator());
    }
  }
}

Fixed version (ground truth):
/** 
 * Method used to progress work
 */
public void progress(){
  for (  int t : messages.keySet()) {
    if (batchDone.get(t)) {
      continue;
    }
    boolean allFinished=true;
    Map<Integer,List<Object>> map=messages.get(t);
    Map<Integer,Boolean> finishedForTarget=finished.get(t);
    Map<Integer,Integer> countMap=counts.get(t);
    boolean found=true;
    for (    Map.Entry<Integer,List<Object>> e : map.entrySet()) {
      if (e.getValue().size() == 0 && !finishedForTarget.get(e.getKey())) {
        found=false;
      }
      if (!finishedForTarget.get(e.getKey())) {
        allFinished=false;
      }
    }
    if (found) {
      List<Object> out=new ArrayList<>();
      for (      Map.Entry<Integer,List<Object>> e : map.entrySet()) {
        List<Object> valueList=e.getValue();
        if (valueList.size() > 0) {
          Object value=valueList.get(0);
          out.add(value);
          allFinished=false;
          valueList.remove(0);
        }
      }
      finalMessages.get(t).addAll(out);
    }
 else {
      allFinished=false;
    }
    if (allFinished) {
      LOG.info(String.format("String_Node_Str",executor,t));
      batchDone.put(t,true);
      gatherBatchReceiver.receive(t,finalMessages.get(t).iterator());
    }
  }
}
Program: 173160
Project: 173160
Buggy source:
@Override public void receive(int target,Iterator<Object> it){
  Map<String,Integer> wordCounts=new HashMap<>();
  while (it.hasNext()) {
    Object next=it.next();
    if (next instanceof List) {
      for (      Object o : (List)next) {
        int count=0;
        String value=o.toString();
        if (wordCounts.containsKey(value)) {
          count=wordCounts.get(value);
        }
        count++;
        totalCount++;
        wordCounts.put(value,count);
      }
    }
  }
  LOG.info(String.format("String_Node_Str",executor,wordCounts));
}

Fixed version (ground truth):
@Override public void receive(int target,Iterator<Object> it){
  Map<String,Integer> localwordCounts=new HashMap<>();
  while (it.hasNext()) {
    Object next=it.next();
    if (next instanceof List) {
      for (      Object o : (List)next) {
        int count=0;
        String value=o.toString();
        if (localwordCounts.containsKey(value)) {
          count=localwordCounts.get(value);
        }
        count++;
        totalCount++;
        localwordCounts.put(value,count);
      }
    }
  }
  LOG.info(String.format("String_Node_Str",executor,localwordCounts));
}
Program: 173161
Project: 173161
Buggy source:
@Override public URI uploadPackage(String sourceLocation) throws UploaderException {
  File file=new File(sourceLocation);
  String fileName=file.getName();
  boolean dirExist=file.isDirectory();
  if (!dirExist) {
    throw new UploaderException(String.format("String_Node_Str",sourceLocation));
  }
  if (!this.controller.mkdirsIfNotExists(destinationDirectory)) {
    throw new UploaderException(String.format("String_Node_Str",destinationDirectory));
  }
  LOG.log(Level.INFO,String.format("String_Node_Str",sourceLocation,destinationDirectory));
  try {
    if (!this.controller.copyFromLocalDirectory(sourceLocation,destinationDirectory)) {
      throw new UploaderException(String.format("String_Node_Str",sourceLocation,destinationDirectory));
    }
    LOG.log(Level.INFO,String.format("String_Node_Str",sourceLocation,destinationDirectory));
    return new URI(destinationDirectory + "String_Node_Str" + fileName);
  }
 catch (  URISyntaxException e) {
    throw new RuntimeException("String_Node_Str" + destinationDirectory,e);
  }
}

Fixed version (ground truth):
@Override public URI uploadPackage(String sourceLocation) throws UploaderException {
  File file=new File(sourceLocation);
  String fileName=file.getName();
  boolean dirExist=file.isDirectory();
  if (!dirExist) {
    throw new UploaderException(String.format("String_Node_Str",sourceLocation));
  }
  if (!this.controller.mkdirsIfNotExists(destinationDirectory)) {
    throw new UploaderException(String.format("String_Node_Str",destinationDirectory));
  }
  LOG.log(Level.INFO,String.format("String_Node_Str" + "String_Node_Str",sourceLocation,destinationDirectory));
  try {
    if (!this.controller.copyFromLocalDirectory(sourceLocation,destinationDirectory)) {
      throw new UploaderException(String.format("String_Node_Str",sourceLocation,destinationDirectory));
    }
    LOG.log(Level.INFO,String.format("String_Node_Str",sourceLocation,destinationDirectory));
    return new URI(destinationDirectory + "String_Node_Str" + fileName);
  }
 catch (  URISyntaxException e) {
    throw new RuntimeException("String_Node_Str" + destinationDirectory,e);
  }
}
Program: 173162
Project: 173162
Buggy source:
@Override public void initialize(Config config){
  this.config=config;
  this.controller=getScpController();
  this.destinationDirectory=ScpContext.uploaderJobDirectory(config);
}

Fixed version (ground truth):
@Override public void initialize(Config conf){
  this.config=conf;
  this.controller=getScpController();
  this.destinationDirectory=ScpContext.uploaderJobDirectory(conf);
}
Program: 173163
Project: 173163
Buggy source:
@Override public void init(Config cfg,DataFlowOperation op,Map<Integer,List<Integer>> expectedIds){
  for (  Map.Entry<Integer,List<Integer>> e : expectedIds.entrySet()) {
    Map<Integer,List<Object>> messagesPerTask=new HashMap<>();
    Map<Integer,Integer> countsPerTask=new HashMap<>();
    for (    int i : e.getValue()) {
      messagesPerTask.put(i,new ArrayList<Object>());
      countsPerTask.put(i,0);
    }
    messages.put(e.getKey(),messagesPerTask);
    counts.put(e.getKey(),countsPerTask);
  }
  this.dataFlowOperation=op;
  this.executor=dataFlowOperation.getTaskPlan().getThisExecutor();
}

Fixed version (ground truth):
@Override public void init(Config cfg,DataFlowOperation op,Map<Integer,List<Integer>> expectedIds){
  executor=op.getTaskPlan().getThisExecutor();
  LOG.info(String.format("String_Node_Str",executor,expectedIds));
  for (  Map.Entry<Integer,List<Integer>> e : expectedIds.entrySet()) {
    Map<Integer,List<Object>> messagesPerTask=new HashMap<>();
    Map<Integer,Integer> countsPerTask=new HashMap<>();
    for (    int i : e.getValue()) {
      messagesPerTask.put(i,new ArrayList<Object>());
      countsPerTask.put(i,0);
    }
    messages.put(e.getKey(),messagesPerTask);
    counts.put(e.getKey(),countsPerTask);
  }
  this.dataFlowOperation=op;
  this.executor=dataFlowOperation.getTaskPlan().getThisExecutor();
}
Program: 173164
Project: 173164
Buggy source:
public void progress(){
  for (  int t : messages.keySet()) {
    boolean canProgress=true;
    while (canProgress) {
      Map<Integer,List<Object>> map=messages.get(t);
      Map<Integer,Integer> cMap=counts.get(t);
      boolean found=true;
      for (      Map.Entry<Integer,List<Object>> e : map.entrySet()) {
        if (e.getValue().size() == 0) {
          found=false;
          canProgress=false;
        }
      }
      if (found) {
        List<Object> out=new ArrayList<>();
        for (        Map.Entry<Integer,List<Object>> e : map.entrySet()) {
          Object e1=e.getValue().get(0);
          out.add(e1);
        }
        if (dataFlowOperation.sendPartial(t,out,0,MessageFlags.FLAGS_MULTI_MSG)) {
          for (          Map.Entry<Integer,List<Object>> e : map.entrySet()) {
            e.getValue().remove(0);
          }
          for (          Map.Entry<Integer,Integer> e : cMap.entrySet()) {
            Integer i=e.getValue();
            e.setValue(i - 1);
          }
        }
 else {
          canProgress=false;
        }
      }
    }
  }
}

Fixed version (ground truth):
public void progress(){
  if (this.threadName == null) {
    this.threadName=Thread.currentThread().getName();
  }
  String tn=Thread.currentThread().getName();
  if (!tn.equals(threadName)) {
    throw new RuntimeException(String.format("String_Node_Str",executor,threadName,tn));
  }
  for (  int t : messages.keySet()) {
    boolean canProgress=true;
    while (canProgress) {
      Map<Integer,List<Object>> map=messages.get(t);
      Map<Integer,Integer> cMap=counts.get(t);
      boolean found=true;
      for (      Map.Entry<Integer,List<Object>> e : map.entrySet()) {
        if (e.getValue().size() == 0) {
          found=false;
          canProgress=false;
        }
      }
      if (map.entrySet().size() == 0) {
        LOG.info(String.format("String_Node_Str",executor,t,counts));
      }
      if (found) {
        List<Object> out=new ArrayList<>();
        for (        Map.Entry<Integer,List<Object>> e : map.entrySet()) {
          Object e1=e.getValue().get(0);
          out.add(e1);
        }
        if (dataFlowOperation.sendPartial(t,out,0,MessageFlags.FLAGS_MULTI_MSG)) {
          for (          Map.Entry<Integer,List<Object>> e : map.entrySet()) {
            List<Object> value=e.getValue();
            if (value.size() == 0) {
              LOG.info(String.format("String_Node_Str",executor,t,e.getKey()));
            }
            value.remove(0);
          }
          for (          Map.Entry<Integer,Integer> e : cMap.entrySet()) {
            Integer i=e.getValue();
            e.setValue(i - 1);
          }
        }
 else {
          canProgress=false;
        }
      }
    }
  }
}
Program: 173165
Project: 173165
Buggy source:
@Override public boolean onMessage(int source,int path,int target,int flags,Object object){
  boolean canAdd=true;
  if (messages.get(target) == null) {
    throw new RuntimeException(String.format("String_Node_Str",executor,target));
  }
  List<Object> m=messages.get(target).get(source);
  Integer c=counts.get(target).get(source);
  if (m.size() > 16) {
    canAdd=false;
    LOG.info(String.format("String_Node_Str",executor,target,source));
  }
 else {
    LOG.info(String.format("String_Node_Str",executor,target,source,counts.get(target)));
    if (object instanceof MPIMessage) {
      ((MPIMessage)object).incrementRefCount();
    }
    m.add(object);
    counts.get(target).put(source,c + 1);
  }
  return canAdd;
}

Fixed version (ground truth):
@Override public boolean onMessage(int source,int path,int target,int flags,Object object){
  boolean canAdd=true;
  if (this.threadName == null) {
    this.threadName=Thread.currentThread().getName();
  }
  String tn=Thread.currentThread().getName();
  if (!tn.equals(threadName)) {
    throw new RuntimeException(String.format("String_Node_Str",executor,threadName,tn));
  }
  if (messages.get(target) == null) {
    throw new RuntimeException(String.format("String_Node_Str",executor,target));
  }
  List<Object> m=messages.get(target).get(source);
  Integer c=counts.get(target).get(source);
  if (m.size() > 16) {
    canAdd=false;
  }
 else {
    if (object instanceof MPIMessage) {
      ((MPIMessage)object).incrementRefCount();
    }
    m.add(object);
    counts.get(target).put(source,c + 1);
  }
  return canAdd;
}
Program: 173166
Project: 173166
Buggy source:
@Override public boolean send(int source,Object message,int flags,int dest){
  return false;
}

Fixed version (ground truth):
@Override public boolean send(int source,Object message,int flags,int dest){
  return delegete.sendMessage(source,message,dest,flags,sendRoutingParameters(source,dest));
}
Program: 173167
Project: 173167
Buggy source:
@Override public TaskPlan getTaskPlan(){
  return null;
}

Fixed version (ground truth):
@Override public TaskPlan getTaskPlan(){
  return plan;
}
Program: 173168
Project: 173168
Buggy source:
@Override public MessageType getType(){
  return null;
}

Fixed version (ground truth):
@Override public MessageType getType(){
  return type;
}
Program: 173169
Project: 173169
Buggy source:
public boolean build(){
  if (header == null && buffers.size() > 0) {
    return false;
  }
  if (header != null) {
    int currentSize=0;
    for (    MPIBuffer buffer : buffers) {
      currentSize+=buffer.getByteBuffer().remaining();
    }
    if (currentSize == header.getLength()) {
      complete=true;
      return true;
    }
  }
  return false;
}

Fixed version (ground truth):
public boolean build(){
  if (header == null && buffers.size() > 0) {
    return false;
  }
  if (header != null) {
    int currentSize=0;
    for (    MPIBuffer buffer : buffers) {
      currentSize+=buffer.getByteBuffer().remaining();
    }
    LOG.info(String.format("String_Node_Str",currentSize,header.getLength()));
    if (currentSize == header.getLength()) {
      complete=true;
      return true;
    }
  }
  return false;
}
Program: 173174
Project: 173174
Buggy source:
/** 
 * add one file to tar.gz file
 * @param file file to be added to the tar.gz
 * @dirPrefixForTar directory structure of this file in tar.gz
 */
public void addFileToArchive(File file,String dirPrefixForTar){
  try {
    String filePathInTar=dirPrefixForTar + file.getName();
    TarArchiveEntry entry=new TarArchiveEntry(file,filePathInTar);
    entry.setSize(file.length());
    tarOutputStream.putArchiveEntry(entry);
    IOUtils.copy(new FileInputStream(file),tarOutputStream);
    tarOutputStream.closeArchiveEntry();
  }
 catch (  IOException e) {
    e.printStackTrace();
  }
}

Fixed version (ground truth):
/** 
 * add one file to tar.gz file
 * @param file file to be added to the tar.gz
 */
public void addFileToArchive(File file,String dirPrefixForTar){
  try {
    String filePathInTar=dirPrefixForTar + file.getName();
    TarArchiveEntry entry=new TarArchiveEntry(file,filePathInTar);
    entry.setSize(file.length());
    tarOutputStream.putArchiveEntry(entry);
    IOUtils.copy(new FileInputStream(file),tarOutputStream);
    tarOutputStream.closeArchiveEntry();
  }
 catch (  IOException e) {
    e.printStackTrace();
  }
}
Program: 173175
Project: 173175
Buggy source:
/** 
 * add all files in the given directory to the tar.gz file add the given prefix to all files in tar names do not copy files recursively. Only one level copying.
 * @param path of the firectory to be added
 */
public void addDirectoryToArchive(String path){
  File dir=new File(path);
  String prefix=dirPrefixForArchive + dir.getName() + "String_Node_Str";
  for (  File file : dir.listFiles()) {
    addFileToArchive(file,prefix);
  }
}

Fixed version (ground truth):
/** 
 * add all files in the given directory to the tar.gz file add the given prefix to all files in tar names do not copy files recursively. Only one level copying.
 * @param path of the firectory to be added
 */
public void addDirectoryToArchive(String path){
  File dir=new File(path);
  String prefix=DIR_PREFIX_FOR_ARCHIVE + dir.getName() + "String_Node_Str";
  for (  File file : dir.listFiles()) {
    addFileToArchive(file,prefix);
  }
}
Program: 173176
Project: 173176
Buggy source:
/** 
 * @param targetDir
 * @return
 */
public static TarGzipPacker createTarGzipPacker(String targetDir,Config config){
  String archiveFilename=SchedulerContext.jobPackageName(config);
  Path archiveFile=Paths.get(targetDir + "String_Node_Str" + archiveFilename);
  try {
    OutputStream outStream=Files.newOutputStream(archiveFile);
    GzipCompressorOutputStream gzipOutputStream=new GzipCompressorOutputStream(outStream);
    TarArchiveOutputStream tarOutputStream=new TarArchiveOutputStream(gzipOutputStream);
    return new TarGzipPacker(archiveFile,tarOutputStream);
  }
 catch (  IOException ioe) {
    System.out.println("String_Node_Str");
    ioe.printStackTrace();
    return null;
  }
}

Fixed version (ground truth):
/** 
 * Create
 * @param targetDir
 * @return
 */
public static TarGzipPacker createTarGzipPacker(String targetDir,Config config){
  String archiveFilename=SchedulerContext.jobPackageName(config);
  Path archiveFile=Paths.get(targetDir + "String_Node_Str" + archiveFilename);
  try {
    OutputStream outStream=Files.newOutputStream(archiveFile);
    GzipCompressorOutputStream gzipOutputStream=new GzipCompressorOutputStream(outStream);
    TarArchiveOutputStream tarOutputStream=new TarArchiveOutputStream(gzipOutputStream);
    return new TarGzipPacker(archiveFile,tarOutputStream);
  }
 catch (  IOException ioe) {
    System.out.println("String_Node_Str");
    ioe.printStackTrace();
    return null;
  }
}
Program: 173177
Project: 173177
Buggy source:
/** 
 * @param archiveFile
 * @param tarOutputStream
 */
private TarGzipPacker(Path archiveFile,TarArchiveOutputStream tarOutputStream){
  this.archiveFile=archiveFile;
  this.tarOutputStream=tarOutputStream;
}

Fixed version (ground truth):
/** 
 * Pack
 * @param archiveFile
 * @param tarOutputStream
 */
private TarGzipPacker(Path archiveFile,TarArchiveOutputStream tarOutputStream){
  this.archiveFile=archiveFile;
  this.tarOutputStream=tarOutputStream;
}
Program: 173178
Project: 173178
Buggy source:
/** 
 * At this level the method does not return an OperationMemoryManager since the implementaion does not handle OperationMemoryManager's
 * @param opID
 * @return
 */
@Override public OperationMemoryManager addOperation(int opID){
  dbMap.put(opID,env.openDbi(String.valueOf(opID),MDB_CREATE));
  return null;
}

Fixed version (ground truth):
/** 
 * At this level the method does not return an OperationMemoryManager since the implementaion does not handle OperationMemoryManager's
 */
@Override public OperationMemoryManager addOperation(int opID){
  dbMap.put(opID,env.openDbi(String.valueOf(opID),MDB_CREATE));
  return null;
}
Program: 173179
Project: 173179
Buggy source:
@Override public void init(Config cfg,MessageType messageType,TaskPlan plan,int graphEdge){
  this.config=cfg;
  this.instancePlan=plan;
  this.edge=graphEdge;
  this.type=messageType;
  this.bounded=false;
  this.executor=instancePlan.getThisExecutor();
  int noOfSendBuffers=MPIContext.broadcastBufferCount(config);
  int sendBufferSize=MPIContext.bufferSize(config);
  this.sendBuffers=new ArrayBlockingQueue<MPIBuffer>(noOfSendBuffers);
  for (int i=0; i < noOfSendBuffers; i++) {
    sendBuffers.offer(new MPIBuffer(sendBufferSize));
  }
  this.receiveBuffers=new HashMap<>();
  this.pendingSendMessagesPerSource=new HashMap<>();
  this.pendingReceiveMessagesPerSource=new HashMap<>();
  this.pendingReceiveDeSerializations=new HashMap<>();
  LOG.info(String.format("String_Node_Str",instancePlan.getThisExecutor()));
  setupRouting();
  LOG.info(String.format("String_Node_Str",instancePlan.getThisExecutor()));
  setupCommunication();
  LOG.info(String.format("String_Node_Str",instancePlan.getThisExecutor()));
  initSerializers();
}

Fixed version (ground truth):
@Override public void init(Config cfg,MessageType messageType,TaskPlan plan,int graphEdge){
  this.config=cfg;
  this.instancePlan=plan;
  this.edge=graphEdge;
  this.type=messageType;
  this.debug=false;
  this.executor=instancePlan.getThisExecutor();
  int noOfSendBuffers=MPIContext.broadcastBufferCount(config);
  int sendBufferSize=MPIContext.bufferSize(config);
  this.sendBuffers=new ArrayBlockingQueue<MPIBuffer>(noOfSendBuffers);
  for (int i=0; i < noOfSendBuffers; i++) {
    sendBuffers.offer(new MPIBuffer(sendBufferSize));
  }
  this.receiveBuffers=new HashMap<>();
  this.pendingSendMessagesPerSource=new HashMap<>();
  this.pendingReceiveMessagesPerSource=new HashMap<>();
  this.pendingReceiveDeSerializations=new HashMap<>();
  LOG.info(String.format("String_Node_Str",instancePlan.getThisExecutor()));
  setupRouting();
  LOG.info(String.format("String_Node_Str",instancePlan.getThisExecutor()));
  setupCommunication();
  LOG.info(String.format("String_Node_Str",instancePlan.getThisExecutor()));
  initSerializers();
}
Program: 173181
Project: 173181
Buggy source:
public static int receiveBufferCount(Config cfg){
  return cfg.getIntegerValue(RECEIVE_BUFFERS_COUNT,128);
}

Fixed version (ground truth):
public static int receiveBufferCount(Config cfg){
  return cfg.getIntegerValue(RECEIVE_BUFFERS_COUNT,32);
}
Program: 173182
Project: 173182
Buggy source:
public static int sendPendingMax(Config cfg){
  return cfg.getIntegerValue(SEND_PENDING_MAX,128);
}

Fixed version (ground truth):
public static int sendPendingMax(Config cfg){
  return cfg.getIntegerValue(SEND_PENDING_MAX,16);
}
Program: 173183
Project: 173183
Buggy source:
public static int bufferSize(Config cfg){
  return cfg.getIntegerValue(BUFFER_SIZE,256000);
}

Fixed version (ground truth):
public static int bufferSize(Config cfg){
  return cfg.getIntegerValue(BUFFER_SIZE,2048000);
}
Program: 173184
Project: 173184
Buggy source:
public static int sendBuffersCount(Config cfg){
  return cfg.getIntegerValue(SEND_BUFFERS_COUNT,128);
}

Fixed version (ground truth):
public static int sendBuffersCount(Config cfg){
  return cfg.getIntegerValue(SEND_BUFFERS_COUNT,16);
}
Program: 173185
Project: 173185
Buggy source:
public void progress(){
  for (  int t : messages.keySet()) {
    boolean canProgress=true;
    while (canProgress) {
      Map<Integer,List<Object>> map=messages.get(t);
      Map<Integer,Integer> cMap=counts.get(t);
      boolean found=true;
      for (      Map.Entry<Integer,List<Object>> e : map.entrySet()) {
        if (e.getValue().size() == 0) {
          found=false;
          canProgress=false;
        }
      }
      if (found) {
        List<Object> out=new ArrayList<>();
        for (        Map.Entry<Integer,List<Object>> e : map.entrySet()) {
          Object e1=e.getValue().get(0);
          if (!(e1 instanceof MPIMessage)) {
            out.add(new MultiObject(e.getKey(),e1));
          }
 else {
            out.add(e1);
          }
          e.getValue().remove(0);
        }
        if (sendMessagePartial(t,out,0,MPIContext.FLAGS_MULTI_MSG,type)) {
          for (          Map.Entry<Integer,Integer> e : cMap.entrySet()) {
            Integer i=e.getValue();
            cMap.put(e.getKey(),i - 1);
          }
        }
 else {
          canProgress=false;
        }
      }
    }
  }
}

Fixed version (ground truth):
public void progress(){
  for (  int t : messages.keySet()) {
    boolean canProgress=true;
    while (canProgress) {
      Map<Integer,List<Object>> map=messages.get(t);
      Map<Integer,Integer> cMap=counts.get(t);
      boolean found=true;
      for (      Map.Entry<Integer,List<Object>> e : map.entrySet()) {
        if (e.getValue().size() == 0) {
          found=false;
          canProgress=false;
        }
      }
      if (found) {
        List<Object> out=new ArrayList<>();
        for (        Map.Entry<Integer,List<Object>> e : map.entrySet()) {
          Object e1=e.getValue().get(0);
          if (!(e1 instanceof MPIMessage)) {
            out.add(new MultiObject(e.getKey(),e1));
          }
 else {
            out.add(e1);
          }
        }
        if (sendMessagePartial(t,out,0,MPIContext.FLAGS_MULTI_MSG,type)) {
          for (          Map.Entry<Integer,List<Object>> e : map.entrySet()) {
            e.getValue().remove(0);
          }
          for (          Map.Entry<Integer,Integer> e : cMap.entrySet()) {
            Integer i=e.getValue();
            e.setValue(i - 1);
          }
        }
 else {
          canProgress=false;
        }
      }
    }
  }
}
Program: 173186
Project: 173186
Buggy source:
@Override public boolean onMessage(int source,int path,int target,int flags,Object object){
  boolean canAdd=true;
  if (messages.get(target) == null) {
    throw new RuntimeException(String.format("String_Node_Str",executor,target));
  }
  List<Object> m=messages.get(target).get(source);
  Integer c=counts.get(target).get(source);
  if (m.size() > 128) {
    canAdd=false;
  }
 else {
    if (object instanceof MPIMessage) {
      ((MPIMessage)object).incrementRefCount();
    }
    m.add(object);
    counts.get(target).put(source,c + 1);
  }
  return canAdd;
}

Fixed version (ground truth):
@Override public boolean onMessage(int source,int path,int target,int flags,Object object){
  boolean canAdd=true;
  if (messages.get(target) == null) {
    throw new RuntimeException(String.format("String_Node_Str",executor,target));
  }
  List<Object> m=messages.get(target).get(source);
  Integer c=counts.get(target).get(source);
  if (m.size() > 16) {
    canAdd=false;
  }
 else {
    if (object instanceof MPIMessage) {
      ((MPIMessage)object).incrementRefCount();
    }
    m.add(object);
    counts.get(target).put(source,c + 1);
  }
  return canAdd;
}
Program: 173189
Project: 173189
Buggy source:
@Override public boolean onMessage(int source,int path,int target,int flags,Object object){
  boolean canAdd=true;
  if (count == 0) {
    start=System.nanoTime();
  }
  try {
    List<Object> m=messages.get(target).get(source);
    if (messages.get(target) == null) {
      throw new RuntimeException(String.format("String_Node_Str",id,target));
    }
    Integer c=counts.get(target).get(source);
    if (m.size() > 128) {
      canAdd=false;
    }
 else {
      m.add(object);
      counts.get(target).put(source,c + 1);
    }
    return canAdd;
  }
 catch (  Throwable t) {
    t.printStackTrace();
  }
  return true;
}

Fixed version (ground truth):
@Override public boolean onMessage(int source,int path,int target,int flags,Object object){
  boolean canAdd=true;
  if (count == 0) {
    start=System.nanoTime();
  }
  try {
    List<Object> m=messages.get(target).get(source);
    if (messages.get(target) == null) {
      throw new RuntimeException(String.format("String_Node_Str",id,target));
    }
    Integer c=counts.get(target).get(source);
    if (m.size() > 16) {
      canAdd=false;
    }
 else {
      m.add(object);
      counts.get(target).put(source,c + 1);
    }
    return canAdd;
  }
 catch (  Throwable t) {
    t.printStackTrace();
  }
  return true;
}
Program: 173190
Project: 173190
Buggy source:
/** 
 * Generate data with an integer array
 * @return IntData
 */
private IntData generateData(){
  int s=12800;
  int[] d=new int[s];
  for (int i=0; i < s; i++) {
    d[i]=i;
  }
  return new IntData(d);
}

Fixed version (ground truth):
/** 
 * Generate data with an integer array
 * @return IntData
 */
private IntData generateData(){
  int s=128000;
  int[] d=new int[s];
  for (int i=0; i < s; i++) {
    d[i]=i;
  }
  return new IntData(d);
}
Program: 173191
Project: 173191
Buggy source:
@Override public void run(){
  try {
    LOG.log(Level.INFO,"String_Node_Str" + id);
    IntData data=generateData();
    for (int i=0; i < 100; i++) {
      while (!aggregate.send(task,data,0)) {
        try {
          Thread.sleep(1);
        }
 catch (        InterruptedException e) {
          e.printStackTrace();
        }
      }
      if (i % 1000 == 0) {
        LOG.info(String.format("String_Node_Str",id,i));
      }
      Thread.yield();
    }
    LOG.info(String.format("String_Node_Str",id));
  }
 catch (  Throwable t) {
    t.printStackTrace();
  }
}

Fixed version (ground truth):
@Override public void run(){
  try {
    LOG.log(Level.INFO,"String_Node_Str" + id);
    IntData data=generateData();
    for (int i=0; i < 100; i++) {
      while (!aggregate.send(task,data,0)) {
        try {
          Thread.sleep(1);
        }
 catch (        InterruptedException e) {
          e.printStackTrace();
        }
      }
      if (i % 10 == 0) {
        LOG.info(String.format("String_Node_Str",id,i));
      }
      Thread.yield();
    }
    LOG.info(String.format("String_Node_Str",id));
  }
 catch (  Throwable t) {
    t.printStackTrace();
  }
}
Program: 173192
Project: 173192
Buggy source:
public void progress(){
  for (  int t : messages.keySet()) {
    boolean canProgress=true;
    while (canProgress) {
      Map<Integer,List<Object>> map=messages.get(t);
      Map<Integer,Integer> cMap=counts.get(t);
      boolean found=true;
      Object o=null;
      for (      Map.Entry<Integer,List<Object>> e : map.entrySet()) {
        if (e.getValue().size() == 0) {
          found=false;
          canProgress=false;
        }
 else {
          o=e.getValue().get(0);
        }
      }
      if (found) {
        for (        Map.Entry<Integer,List<Object>> e : map.entrySet()) {
          o=e.getValue().remove(0);
        }
        for (        Map.Entry<Integer,Integer> e : cMap.entrySet()) {
          Integer i=e.getValue();
          cMap.put(e.getKey(),i - 1);
        }
        if (o != null) {
          count++;
          if (count % 1 == 0) {
            LOG.info(String.format("String_Node_Str",id,t,count,counts));
          }
          if (count >= 10000) {
            LOG.info("String_Node_Str" + (System.nanoTime() - start) / 1000000 + "String_Node_Str" + count);
          }
        }
 else {
          LOG.severe("String_Node_Str");
        }
      }
    }
  }
}

Fixed version (ground truth):
public void progress(){
  for (  int t : messages.keySet()) {
    boolean canProgress=true;
    while (canProgress) {
      Map<Integer,List<Object>> map=messages.get(t);
      Map<Integer,Integer> cMap=counts.get(t);
      boolean found=true;
      Object o=null;
      for (      Map.Entry<Integer,List<Object>> e : map.entrySet()) {
        if (e.getValue().size() == 0) {
          found=false;
          canProgress=false;
        }
 else {
          o=e.getValue().get(0);
        }
      }
      if (found) {
        for (        Map.Entry<Integer,List<Object>> e : map.entrySet()) {
          o=e.getValue().remove(0);
        }
        for (        Map.Entry<Integer,Integer> e : cMap.entrySet()) {
          Integer i=e.getValue();
          cMap.put(e.getKey(),i - 1);
        }
        if (o != null) {
          count++;
          if (count % 1 == 0) {
            LOG.info(String.format("String_Node_Str",id,t,count,counts));
          }
          if (count >= 100) {
            LOG.info("String_Node_Str" + (System.nanoTime() - start) / 1000000 + "String_Node_Str" + count);
          }
        }
 else {
          LOG.severe("String_Node_Str");
        }
      }
    }
  }
}
Program: 173193
Project: 173193
Buggy source:
public void progress(){
  for (  int t : messages.keySet()) {
    boolean canProgress=true;
    while (canProgress) {
      Map<Integer,List<Object>> map=messages.get(t);
      Map<Integer,Integer> cMap=counts.get(t);
      boolean found=true;
      Object o=null;
      for (      Map.Entry<Integer,List<Object>> e : map.entrySet()) {
        if (e.getValue().size() == 0) {
          found=false;
          canProgress=false;
        }
 else {
          o=e.getValue().get(0);
        }
      }
      if (found) {
        for (        Map.Entry<Integer,List<Object>> e : map.entrySet()) {
          o=e.getValue().remove(0);
        }
        for (        Map.Entry<Integer,Integer> e : cMap.entrySet()) {
          Integer i=e.getValue();
          cMap.put(e.getKey(),i - 1);
        }
        if (o != null) {
          count++;
          if (count % 1 == 0) {
            LOG.info(String.format("String_Node_Str",id,t,count,counts));
          }
          if (count >= 100) {
            LOG.info("String_Node_Str" + (System.nanoTime() - start) / 1000000 + "String_Node_Str" + count);
          }
        }
 else {
          LOG.severe("String_Node_Str");
        }
      }
    }
  }
}

Fixed version (ground truth):
public void progress(){
  for (  int t : messages.keySet()) {
    boolean canProgress=true;
    while (canProgress) {
      Map<Integer,List<Object>> map=messages.get(t);
      Map<Integer,Integer> cMap=counts.get(t);
      boolean found=true;
      Object o=null;
      for (      Map.Entry<Integer,List<Object>> e : map.entrySet()) {
        if (e.getValue().size() == 0) {
          found=false;
          canProgress=false;
        }
 else {
          o=e.getValue().get(0);
        }
      }
      if (found) {
        for (        Map.Entry<Integer,List<Object>> e : map.entrySet()) {
          o=e.getValue().remove(0);
        }
        for (        Map.Entry<Integer,Integer> e : cMap.entrySet()) {
          Integer i=e.getValue();
          cMap.put(e.getKey(),i - 1);
        }
        if (o != null) {
          count++;
          if (count % 100 == 0) {
            LOG.info(String.format("String_Node_Str",id,t,count,counts));
          }
          if (count >= 100) {
            LOG.info("String_Node_Str" + (System.nanoTime() - start) / 1000000 + "String_Node_Str" + count);
          }
        }
 else {
          LOG.severe("String_Node_Str");
        }
      }
    }
  }
}
Program: 173194
Project: 173194
Buggy source:
/** 
 * test method for BasicJob write to a file
 * @param basicJob
 */
public static void jobWriteTest(BasicJob basicJob){
  String file="String_Node_Str";
  JobUtils.writeJobFile(basicJob.serialize(),file);
}

Fixed version (ground truth):
/** 
 * test method for BasicJob write to a file
 */
public static void jobWriteTest(BasicJob basicJob){
  String file="String_Node_Str";
  JobUtils.writeJobFile(basicJob.serialize(),file);
}
Program: 173195
Project: 173195
Buggy source:
public void progress(){
  for (  int t : messages.keySet()) {
    boolean canProgress=true;
    if (done.get(t)) {
      continue;
    }
    while (canProgress) {
      Map<Integer,List<Object>> map=messages.get(t);
      Map<Integer,Boolean> finishedMap=finished.get(t);
      boolean found=true;
      int finishedInputs=0;
      for (      Map.Entry<Integer,List<Object>> e : map.entrySet()) {
        Boolean f=finishedMap.get(e.getKey());
        if (e.getValue().size() == 0) {
          if (!f) {
            found=false;
            canProgress=false;
          }
        }
        if (f) {
          finishedInputs++;
        }
      }
      if (finishedInputs == map.keySet().size()) {
        done.put(t,true);
      }
      if (found) {
        List<Object> out=new ArrayList<>();
        for (        Map.Entry<Integer,List<Object>> e : map.entrySet()) {
          List<Object> objectList=e.getValue();
          if (objectList.size() > 0) {
            Object object=objectList.get(0);
            if (!(object instanceof MPIMessage)) {
              out.add(new MultiObject(e.getKey(),object));
            }
 else {
              out.add(object);
            }
          }
        }
        if (!operation.sendMessagePartial(t,out,0,MPIContext.FLAGS_MULTI_MSG,operation.getType())) {
          canProgress=false;
        }
      }
    }
  }
}

Fixed version (ground truth):
/** 
 * progress
 */
public void progress(){
  for (  int t : messages.keySet()) {
    boolean canProgress=true;
    if (done.get(t)) {
      continue;
    }
    while (canProgress) {
      Map<Integer,List<Object>> map=messages.get(t);
      Map<Integer,Boolean> finishedMap=finished.get(t);
      boolean found=true;
      int finishedInputs=0;
      for (      Map.Entry<Integer,List<Object>> e : map.entrySet()) {
        Boolean f=finishedMap.get(e.getKey());
        if (e.getValue().size() == 0) {
          if (!f) {
            found=false;
            canProgress=false;
          }
        }
        if (f) {
          finishedInputs++;
        }
      }
      if (finishedInputs == map.keySet().size()) {
        done.put(t,true);
      }
      if (found) {
        List<Object> out=new ArrayList<>();
        for (        Map.Entry<Integer,List<Object>> e : map.entrySet()) {
          List<Object> objectList=e.getValue();
          if (objectList.size() > 0) {
            Object object=objectList.get(0);
            if (!(object instanceof MPIMessage)) {
              out.add(new MultiObject(e.getKey(),object));
            }
 else {
              out.add(object);
            }
          }
        }
        if (!operation.sendMessagePartial(t,out,0,MPIContext.FLAGS_MULTI_MSG,operation.getType())) {
          canProgress=false;
        }
      }
    }
  }
}
Program: 173197
Project: 173197
Buggy source:
public AuroraClientController(String cluster,String role,String env,String jobName,boolean isVerbose){
  this.jobSpec=String.format("String_Node_Str",cluster,role,env,jobName);
  this.isVerbose=isVerbose;
}

Fixed version (ground truth):
AuroraClientController(String cluster,String role,String env,String jobName,boolean isVerbose){
  this.jobSpec=String.format("String_Node_Str",cluster,role,env,jobName);
  this.isVerbose=isVerbose;
}
Program: 173198
Project: 173198
Buggy source:
/** 
 * add new containers to this job
 * @param count
 */
public void addContainers(Integer count){
  List<String> auroraCmd=new ArrayList<>(Arrays.asList("String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str",jobSpec + "String_Node_Str",count.toString()));
  if (isVerbose) {
    auroraCmd.add("String_Node_Str");
  }
  LOG.info(String.format("String_Node_Str",count,auroraCmd));
  if (!runProcess(auroraCmd)) {
    throw new RuntimeException("String_Node_Str" + count + "String_Node_Str");
  }
}

Fixed version (ground truth):
/** 
 * add new containers to this job
 */
public void addContainers(Integer count){
  List<String> auroraCmd=new ArrayList<>(Arrays.asList("String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str",jobSpec + "String_Node_Str",count.toString()));
  if (isVerbose) {
    auroraCmd.add("String_Node_Str");
  }
  LOG.info(String.format("String_Node_Str",count,auroraCmd));
  if (!runProcess(auroraCmd)) {
    throw new RuntimeException("String_Node_Str" + count + "String_Node_Str");
  }
}