nus-yam/ex-repair huggingface dataset:
Program: 97866
Project: 97866
Buggy source:
@Override public Cursor<IndexPoint> indexView(String columnFamily,String column,String partitionBy,String partitionId){
  DboTableMeta meta=cachedMeta.getMeta(columnFamily);
  if (meta == null)   throw new IllegalArgumentException("String_Node_Str" + columnFamily + "String_Node_Str");
  DboColumnMeta colMeta=meta.getColumnMeta(column);
  if (colMeta == null) {
    colMeta=meta.getIdColumnMeta();
    if (!(colMeta != null && colMeta.getColumnName().equals(column)))     throw new IllegalArgumentException("String_Node_Str" + column + "String_Node_Str"+ columnFamily);
  }
 else   if (!colMeta.isIndexed())   throw new IllegalArgumentException("String_Node_Str" + column + "String_Node_Str");
 else   if (meta.getPartitionedColumns().size() > 1 && partitionBy == null)   throw new IllegalArgumentException("String_Node_Str" + columnFamily + "String_Node_Str");
  ScanInfo info=ScanInfo.createScanInfo(colMeta,partitionBy,partitionId);
  AbstractCursor<IndexColumn> indCol=session.scanIndex(info,null,null,null);
  AbstractCursor<IndexPoint> results=new CursorToIndexPoint(meta.getIdColumnMeta(),colMeta,indCol);
  return results;
}

Fixed version (ground truth):
@Override public Cursor<IndexPoint> indexView(String columnFamily,String column,String partitionBy,String partitionId){
  DboTableMeta meta=cachedMeta.getMeta(columnFamily);
  if (meta == null)   throw new IllegalArgumentException("String_Node_Str" + columnFamily + "String_Node_Str");
  DboColumnMeta colMeta=meta.getColumnMeta(column);
  if (colMeta == null) {
    colMeta=meta.getIdColumnMeta();
    if (!(colMeta != null && colMeta.getColumnName().equals(column)))     throw new IllegalArgumentException("String_Node_Str" + column + "String_Node_Str"+ columnFamily);
  }
  if (!colMeta.isIndexed())   throw new IllegalArgumentException("String_Node_Str" + column + "String_Node_Str");
 else   if (meta.getPartitionedColumns().size() > 1 && partitionBy == null)   throw new IllegalArgumentException("String_Node_Str" + columnFamily + "String_Node_Str");
  ScanInfo info=ScanInfo.createScanInfo(colMeta,partitionBy,partitionId);
  AbstractCursor<IndexColumn> indCol=session.scanIndex(info,null,null,null);
  AbstractCursor<IndexPoint> results=new CursorToIndexPoint(meta.getIdColumnMeta(),colMeta,indCol);
  return results;
}
Program: 97867
Project: 97867
Buggy source:
/** 
 * This method should only be used on small count CF's(less than 5 million or so).  For large count CF's, use map/reduce. Be away that millions of rows can take a while to read so this is usually reserved for longer operations. Returns all rows in a concrete CF.  If your CF is inheritance(many entity types in one CF), then your baseEntty should be the super class.  If you have many virtual tables in a CF(and you have inheritance in some virtual tables or not), then your baseEntity should be Object.class.  This method will return the proper types of entitys.  For inheritance base, it will return the types based on each rows discriminator column.  For virtual tables, it looks at each row and returns the type based on that virtual table so each row coming back would be a different type.
 * @param baseEntity
 * @param i
 * @return
 */
public <T>Cursor<T> allRows(Class<T> baseEntity,String cf,int batchSize);

Fixed version (ground truth):
/** 
 * This method should only be used on small count CF's(less than 5 million or so).  For large count CF's, use map/reduce. Be away that millions of rows can take a while to read so this is usually reserved for longer operations. Returns all rows in a concrete CF.  If your CF is inheritance(many entity types in one CF), then your baseEntty should be the super class.  If you have many virtual tables in a CF(and you have inheritance in some virtual tables or not), then your baseEntity should be Object.class.  This method will return the proper types of entitys.  For inheritance base, it will return the types based on each rows discriminator column.  For virtual tables, it looks at each row and returns the type based on that virtual table so each row coming back would be a different type.
 * @param baseEntity
 * @param cf
 * @param batchSize
 * @return A Cursor
 */
public <T>Cursor<T> allRows(Class<T> baseEntity,String cf,int batchSize);
Program: 97870
Project: 97870
Buggy source:
@SuppressWarnings({"String_Node_Str","String_Node_Str"}) private boolean processIdFieldWorks(MetaAbstractClass metaClass,DboTableMeta metaDbo,Field field){
  if (!field.isAnnotationPresent(NoSqlId.class))   return false;
  if (metaClass.getIdField() != null) {
    Field existingField=metaClass.getIdField().getField();
    if (field.equals(existingField)) {
      log.warn("String_Node_Str" + metaClass.getClass() + "String_Node_Str",new RuntimeException().fillInStackTrace());
      log.warn("String_Node_Str",metaClass.getFirstTrace());
      return true;
    }
 else {
      throw new IllegalArgumentException("String_Node_Str" + metaClass.getClass() + "String_Node_Str"+ field+ "String_Node_Str"+ existingField);
    }
  }
 else   if (log.isDebugEnabled()) {
    metaClass.setFirstTrace(new RuntimeException("String_Node_Str" + field + "String_Node_Str"+ metaClass).fillInStackTrace());
  }
  MetaIdField idField=inspectorField.processId(metaDbo,field,metaClass);
  metaClass.setIdField(idField);
  return true;
}

Fixed version (ground truth):
@SuppressWarnings({"String_Node_Str","String_Node_Str"}) private boolean processIdFieldWorks(MetaAbstractClass metaClass,DboTableMeta metaDbo,Field field){
  if (!field.isAnnotationPresent(NoSqlId.class))   return false;
  if (metaClass.getIdField() != null) {
    Field existingField=metaClass.getIdField().getField();
    if (field.equals(existingField)) {
      log.warn("String_Node_Str" + metaClass.getClass() + "String_Node_Str",new RuntimeException().fillInStackTrace());
      log.warn("String_Node_Str",metaClass.getFirstTrace());
      return true;
    }
 else     if (!metaClass.getMetaDbo().isEmbeddable()) {
      throw new IllegalArgumentException("String_Node_Str" + metaClass.getClass() + "String_Node_Str"+ field+ "String_Node_Str"+ existingField);
    }
  }
 else   if (log.isDebugEnabled()) {
    metaClass.setFirstTrace(new RuntimeException("String_Node_Str" + field + "String_Node_Str"+ metaClass).fillInStackTrace());
  }
  MetaIdField idField=inspectorField.processId(metaDbo,field,metaClass);
  metaClass.setIdField(idField);
  return true;
}
Program: 97871
Project: 97871
Buggy source:
@SuppressWarnings("String_Node_Str") @Override public void onApplicationStart(){
  List<Class> classes=Play.classloader.getAnnotatedClasses(NoSqlEntity.class);
  List<Class> classEmbeddables=Play.classloader.getAnnotatedClasses(NoSqlEmbeddable.class);
  classes.addAll(classEmbeddables);
  if (classes.isEmpty())   return;
 else   if (NoSql.getEntityManagerFactory() != null) {
    NoSqlEntityManagerFactory factory=NoSql.getEntityManagerFactory();
    factory.rescan(classes,Play.classloader);
    return;
  }
  Class<?> clazz=null;
  try {
    clazz=Class.forName("String_Node_Str");
    if (NoSqlConfig.class.isAssignableFrom(clazz)) {
      NoSqlConfig config=(NoSqlConfig)clazz.newInstance();
      config.configure(PROPS);
    }
 else {
      log.warn("String_Node_Str" + clazz + "String_Node_Str");
    }
  }
 catch (  ClassNotFoundException e) {
  }
catch (  InstantiationException e) {
    log.warn("String_Node_Str" + clazz,e);
  }
catch (  IllegalAccessException e) {
    log.warn("String_Node_Str" + clazz,e);
  }
  PROPS.put(Bootstrap.LIST_OF_EXTRA_CLASSES_TO_SCAN_KEY,classes);
  PROPS.put(Bootstrap.AUTO_CREATE_KEY,"String_Node_Str");
  for (  java.util.Map.Entry<Object,Object> entry : Play.configuration.entrySet()) {
    PROPS.put((String)entry.getKey(),entry.getValue());
  }
  if (log.isInfoEnabled())   log.info("String_Node_Str");
  NoSqlEntityManagerFactory factory=Bootstrap.create(PROPS,Play.classloader);
  NoSql.setEntityManagerFactory(factory);
  CassandraAppender.setFactory(factory);
}

Fixed version (ground truth):
@SuppressWarnings("String_Node_Str") @Override public void onApplicationStart(){
  List<Class> classes=Play.classloader.getAnnotatedClasses(NoSqlEntity.class);
  List<Class> classEmbeddables=Play.classloader.getAnnotatedClasses(NoSqlEmbeddable.class);
  classes.addAll(classEmbeddables);
  if (classes.isEmpty())   return;
 else   if (NoSql.getEntityManagerFactory() != null) {
    NoSqlEntityManagerFactory factory=NoSql.getEntityManagerFactory();
    factory.rescan(classes,Play.classloader);
    return;
  }
  Class<?> clazz=null;
  try {
    clazz=Class.forName("String_Node_Str");
    if (NoSqlConfig.class.isAssignableFrom(clazz)) {
      NoSqlConfig config=(NoSqlConfig)clazz.newInstance();
      config.configure(PROPS);
    }
 else {
      log.warn("String_Node_Str" + clazz + "String_Node_Str");
    }
  }
 catch (  ClassNotFoundException e) {
    log.info("String_Node_Str");
  }
catch (  InstantiationException e) {
    log.warn("String_Node_Str" + clazz,e);
  }
catch (  IllegalAccessException e) {
    log.warn("String_Node_Str" + clazz,e);
  }
  PROPS.put(Bootstrap.LIST_OF_EXTRA_CLASSES_TO_SCAN_KEY,classes);
  PROPS.put(Bootstrap.AUTO_CREATE_KEY,"String_Node_Str");
  for (  java.util.Map.Entry<Object,Object> entry : Play.configuration.entrySet()) {
    PROPS.put((String)entry.getKey(),entry.getValue());
  }
  if (log.isInfoEnabled())   log.info("String_Node_Str");
  NoSqlEntityManagerFactory factory=Bootstrap.create(PROPS,Play.classloader);
  NoSql.setEntityManagerFactory(factory);
  CassandraAppender.setFactory(factory);
}
Program: 97873
Project: 97873
Buggy source:
private void addColumn(PROXY proxy,Field singleField,byte[] idValue,RowToPersist row){
  Object value=ReflectionUtil.fetchFieldValue(proxy,singleField);
  Column c=new Column();
  byte[] columnName=formTheColumnName(proxy,idValue,singleField);
  c.setName(columnName);
  if (value != null) {
    byte[] columnValue=StandardConverters.convertToBytes(value);
    c.setValue(columnValue);
  }
  row.getColumns().add(c);
}

Fixed version (ground truth):
private void addColumn(PROXY proxy,Field singleField,byte[] idValue,RowToPersist row){
  Object value=ReflectionUtil.fetchFieldValue(proxy,singleField);
  Column c=new Column();
  byte[] columnName=formTheColumnName(proxy,idValue,singleField);
  c.setName(columnName);
  if (value != null) {
    byte[] columnValue=null;
    NoSqlConverter customConv=singleField.getAnnotation(NoSqlConverter.class);
    if (customConv != null) {
      columnValue=getBytesValue(value,customConv);
    }
 else {
      columnValue=StandardConverters.convertToBytes(value);
    }
    c.setValue(columnValue);
  }
  row.getColumns().add(c);
}
Program: 97874
Project: 97874
Buggy source:
private void addColumnWithoutId(PROXY proxy,Field singleField,RowToPersist row){
  Object value=ReflectionUtil.fetchFieldValue(proxy,singleField);
  Column c=new Column();
  byte[] prefix=StandardConverters.convertToBytes(columnName);
  byte[] singleFieldName=StandardConverters.convertToBytes(singleField.getName());
  byte[] columnName=new byte[prefix.length + singleFieldName.length];
  for (int i=0; i < columnName.length; i++) {
    if (i < prefix.length)     columnName[i]=prefix[i];
 else     columnName[i]=singleFieldName[i - prefix.length];
  }
  c.setName(columnName);
  if (value != null) {
    byte[] columnValue=StandardConverters.convertToBytes(value);
    c.setValue(columnValue);
  }
  row.getColumns().add(c);
}

Fixed version (ground truth):
private void addColumnWithoutId(PROXY proxy,Field singleField,RowToPersist row){
  Object value=ReflectionUtil.fetchFieldValue(proxy,singleField);
  Column c=new Column();
  byte[] prefix=StandardConverters.convertToBytes(columnName);
  byte[] singleFieldName=StandardConverters.convertToBytes(singleField.getName());
  byte[] columnName=new byte[prefix.length + singleFieldName.length];
  for (int i=0; i < columnName.length; i++) {
    if (i < prefix.length)     columnName[i]=prefix[i];
 else     columnName[i]=singleFieldName[i - prefix.length];
  }
  c.setName(columnName);
  if (value != null) {
    byte[] columnValue=null;
    NoSqlConverter customConv=singleField.getAnnotation(NoSqlConverter.class);
    if (customConv != null) {
      columnValue=getBytesValue(value,customConv);
    }
 else {
      columnValue=StandardConverters.convertToBytes(value);
    }
    c.setValue(columnValue);
  }
  row.getColumns().add(c);
}
Program: 97875
Project: 97875
Buggy source:
@SuppressWarnings("String_Node_Str") @Override public void rescan(List<Class> classesToScan,ClassLoader cl){
  List<Class> classes=classesToScan;
  if (classes == null)   classes=new ArrayList<Class>();
  metaInfo.clearAll();
  listener.setClassLoader(cl);
  discoverer.setFilter(new OurFilter());
  discoverer.addAnnotationListener(listener);
  discoverer.discover(cl);
  for (  Class c : classes) {
    listener.scanClass(c);
    if (c.getSuperclass() != java.lang.Object.class) {
      listener.scanClass(c.getSuperclass());
    }
  }
  if (log.isTraceEnabled()) {
    URL[] resources=discoverer.findResources(cl);
    for (    URL res : resources) {
      log.trace("String_Node_Str" + res);
    }
  }
  Collection<MetaAbstractClass> allEntities=metaInfo.getAllEntities();
  for (  MetaAbstractClass meta : allEntities) {
    setupQueryStuff(meta);
  }
  log.info("String_Node_Str");
  isScanned=true;
  BaseEntityManagerImpl tempMgr=(BaseEntityManagerImpl)createEntityManager();
  tempMgr.saveMetaData();
  cache.init(this);
  log.info("String_Node_Str");
}

Fixed version (ground truth):
@SuppressWarnings("String_Node_Str") @Override public void rescan(List<Class> classesToScan,ClassLoader cl){
  List<Class> classes=classesToScan;
  if (classes == null)   classes=new ArrayList<Class>();
  metaInfo.clearAll();
  listener.setClassLoader(cl);
  discoverer.setFilter(new OurFilter());
  discoverer.addAnnotationListener(listener);
  discoverer.discover(cl);
  for (  Class c : classes) {
    listener.scanClass(c);
    if (c.getSuperclass() != java.lang.Object.class) {
      listener.scanClass(c.getSuperclass());
    }
  }
  if (log.isTraceEnabled()) {
    URL[] resources=discoverer.findResources(cl);
    for (    URL res : resources) {
      if (log.isTraceEnabled())       log.trace("String_Node_Str" + res);
    }
  }
  Collection<MetaAbstractClass> allEntities=metaInfo.getAllEntities();
  for (  MetaAbstractClass meta : allEntities) {
    setupQueryStuff(meta);
  }
  log.info("String_Node_Str");
  isScanned=true;
  BaseEntityManagerImpl tempMgr=(BaseEntityManagerImpl)createEntityManager();
  tempMgr.saveMetaData();
  cache.init(this);
  log.info("String_Node_Str");
}
Program: 97876
Project: 97876
Buggy source:
@Override public void discovered(String clazzName,String annotation){
  log.debug("String_Node_Str" + clazzName + "String_Node_Str"+ annotation);
  try {
    Class<?> clazz=classLoader.loadClass(clazzName);
    scanClass(clazz);
    while (clazz.getSuperclass() != java.lang.Object.class) {
      clazz=clazz.getSuperclass();
      inspectorClass.addClassForQueries(clazz);
    }
  }
 catch (  ClassNotFoundException e) {
    throw new RuntimeException(e);
  }
}

Fixed version (ground truth):
@Override public void discovered(String clazzName,String annotation){
  if (log.isDebugEnabled())   log.debug("String_Node_Str" + clazzName + "String_Node_Str"+ annotation);
  try {
    Class<?> clazz=classLoader.loadClass(clazzName);
    scanClass(clazz);
    while (clazz.getSuperclass() != java.lang.Object.class) {
      clazz=clazz.getSuperclass();
      inspectorClass.addClassForQueries(clazz);
    }
  }
 catch (  ClassNotFoundException e) {
    throw new RuntimeException(e);
  }
}
Program: 97877
Project: 97877
Buggy source:
@Override public List<T> getResultList(int firstResult,Integer maxResults){
  if (maxResults != null && !batchSizeSetByUser)   setBatchSize(maxResults);
  AbstractCursor<KeyValue<T>> all=(AbstractCursor<KeyValue<T>>)getResults();
  List<T> foundElements=new ArrayList<T>();
  try {
    return getEntities(all,foundElements,firstResult,maxResults);
  }
 catch (  RowNotFoundException e) {
    log.trace("String_Node_Str",e);
    throw new StorageMissingEntitesException(foundElements,"String_Node_Str",e);
  }
}

Fixed version (ground truth):
@Override public List<T> getResultList(int firstResult,Integer maxResults){
  if (maxResults != null && !batchSizeSetByUser)   setBatchSize(maxResults);
  AbstractCursor<KeyValue<T>> all=(AbstractCursor<KeyValue<T>>)getResults();
  List<T> foundElements=new ArrayList<T>();
  try {
    return getEntities(all,foundElements,firstResult,maxResults);
  }
 catch (  RowNotFoundException e) {
    if (log.isTraceEnabled())     log.trace("String_Node_Str",e);
    throw new StorageMissingEntitesException(foundElements,"String_Node_Str",e);
  }
}
Program: 97878
Project: 97878
Buggy source:
private List<T> getEntities(AbstractCursor<KeyValue<T>> all,List<T> foundElements,int firstResult,Integer maxResults){
  List<T> entities=new ArrayList<T>();
  RowNotFoundException exc=null;
  int counter=0;
  while (true) {
    Holder<KeyValue<T>> holder=all.nextImpl();
    if (holder == null)     break;
    KeyValue<T> keyVal=holder.getValue();
    if (counter < firstResult) {
      counter++;
      continue;
    }
 else     if (maxResults != null && counter >= firstResult + maxResults)     break;
    try {
      entities.add(keyVal.getValue());
      foundElements.add(keyVal.getValue());
    }
 catch (    RowNotFoundException e) {
      if (exc == null)       exc=e;
    }
    counter++;
  }
  if (exc != null) {
    log.trace("String_Node_Str",exc);
    throw new StorageMissingEntitesException(foundElements,"String_Node_Str",exc);
  }
  return entities;
}

Fixed version (ground truth):
private List<T> getEntities(AbstractCursor<KeyValue<T>> all,List<T> foundElements,int firstResult,Integer maxResults){
  List<T> entities=new ArrayList<T>();
  RowNotFoundException exc=null;
  int counter=0;
  while (true) {
    Holder<KeyValue<T>> holder=all.nextImpl();
    if (holder == null)     break;
    KeyValue<T> keyVal=holder.getValue();
    if (counter < firstResult) {
      counter++;
      continue;
    }
 else     if (maxResults != null && counter >= firstResult + maxResults)     break;
    try {
      entities.add(keyVal.getValue());
      foundElements.add(keyVal.getValue());
    }
 catch (    RowNotFoundException e) {
      if (exc == null)       exc=e;
    }
    counter++;
  }
  if (exc != null) {
    if (log.isTraceEnabled())     log.trace("String_Node_Str",exc);
    throw new StorageMissingEntitesException(foundElements,"String_Node_Str",exc);
  }
  return entities;
}
Program: 97879
Project: 97879
Buggy source:
private synchronized Exception createColFamily(String virtualCf,MetaLookup ormSession){
  try {
    long start=System.currentTimeMillis();
    createColFamilyImpl(virtualCf,ormSession);
    long total=System.currentTimeMillis() - start;
    if (log.isInfoEnabled())     log.info("String_Node_Str" + total);
  }
 catch (  Exception e) {
    log.trace("String_Node_Str",e);
    return e;
  }
  return null;
}

Fixed version (ground truth):
private synchronized Exception createColFamily(String virtualCf,MetaLookup ormSession){
  try {
    long start=System.currentTimeMillis();
    createColFamilyImpl(virtualCf,ormSession);
    long total=System.currentTimeMillis() - start;
    if (log.isInfoEnabled())     log.info("String_Node_Str" + total);
  }
 catch (  Exception e) {
    if (log.isTraceEnabled())     log.trace("String_Node_Str",e);
    return e;
  }
  return null;
}
Program: 97880
Project: 97880
Buggy source:
private synchronized Exception createColFamily(String virtualCf,MetaLookup ormSession){
  try {
    long start=System.currentTimeMillis();
    createColFamilyImpl(virtualCf,ormSession);
    long total=System.currentTimeMillis() - start;
    if (log.isInfoEnabled())     log.info("String_Node_Str" + total);
  }
 catch (  Exception e) {
    log.trace("String_Node_Str",e);
    return e;
  }
  return null;
}

Fixed version (ground truth):
private synchronized Exception createColFamily(String virtualCf,MetaLookup ormSession){
  try {
    long start=System.currentTimeMillis();
    createColFamilyImpl(virtualCf,ormSession);
    long total=System.currentTimeMillis() - start;
    if (log.isInfoEnabled())     log.info("String_Node_Str" + total);
  }
 catch (  Exception e) {
    if (log.isTraceEnabled())     log.trace("String_Node_Str",e);
    return e;
  }
  return null;
}
Program: 97881
Project: 97881
Buggy source:
@Override public byte[] next(){
  byte[] k=rowKeys.next();
  if (meta != null && log.isInfoEnabled()) {
    try {
      Object obj=meta.getIdColumnMeta().convertFromStorage2(k);
      String str=meta.getIdColumnMeta().convertTypeToString(obj);
      realKeys.add(str);
    }
 catch (    Exception e) {
      log.trace("String_Node_Str",e);
      realKeys.add("String_Node_Str");
    }
  }
  return k;
}

Fixed version (ground truth):
@Override public byte[] next(){
  byte[] k=rowKeys.next();
  if (meta != null && log.isInfoEnabled()) {
    try {
      Object obj=meta.getIdColumnMeta().convertFromStorage2(k);
      String str=meta.getIdColumnMeta().convertTypeToString(obj);
      realKeys.add(str);
    }
 catch (    Exception e) {
      if (log.isTraceEnabled())       log.trace("String_Node_Str",e);
      realKeys.add("String_Node_Str");
    }
  }
  return k;
}
Program: 97882
Project: 97882
Buggy source:
private Tuple init(String message2,RecognitionException cause){
  int characterPosition=-1;
  String tokenText=null;
  String message="String_Node_Str";
  try {
    characterPosition=cause.charPositionInLine;
    message="String_Node_Str" + characterPosition;
    Token token=cause.token;
    if (token != null) {
      tokenText=token.getText();
      message+="String_Node_Str" + token.getText();
    }
 else     tokenText=null;
    Object node=cause.node;
    if (node != null)     message+="String_Node_Str" + node;
    if (message2 != null)     message+="String_Node_Str" + message2;
  }
 catch (  Exception e) {
    log.trace("String_Node_Str",e);
    message="String_Node_Str" + cause;
    if (message2 != null)     message+="String_Node_Str" + message2;
  }
  Tuple tuple=new Tuple(message,tokenText,characterPosition);
  return tuple;
}

Fixed version (ground truth):
private Tuple init(String message2,RecognitionException cause){
  int characterPosition=-1;
  String tokenText=null;
  String message="String_Node_Str";
  try {
    characterPosition=cause.charPositionInLine;
    message="String_Node_Str" + characterPosition;
    Token token=cause.token;
    if (token != null) {
      tokenText=token.getText();
      message+="String_Node_Str" + token.getText();
    }
 else     tokenText=null;
    Object node=cause.node;
    if (node != null)     message+="String_Node_Str" + node;
    if (message2 != null)     message+="String_Node_Str" + message2;
  }
 catch (  Exception e) {
    if (log.isTraceEnabled())     log.trace("String_Node_Str",e);
    message="String_Node_Str" + cause;
    if (message2 != null)     message+="String_Node_Str" + message2;
  }
  Tuple tuple=new Tuple(message,tokenText,characterPosition);
  return tuple;
}
Program: 97883
Project: 97883
Buggy source:
@SuppressWarnings("String_Node_Str") private static <T>void compileExpression(ExpressionNode node,InfoForWiring wiring,MetaFacade facade){
  CommonTree expression=node.getASTNode();
  int type=expression.getType();
  log.debug("String_Node_Str" + expression.getType());
switch (type) {
case NoSqlLexer.AND:
case NoSqlLexer.OR:
    node.setState("String_Node_Str",null);
  List<CommonTree> children=expression.getChildren();
processSide(node,wiring,children,0,ChildSide.LEFT,facade);
processSide(node,wiring,children,1,ChildSide.RIGHT,facade);
break;
case NoSqlLexer.EQ:
case NoSqlLexer.NE:
case NoSqlLexer.GT:
case NoSqlLexer.LT:
case NoSqlLexer.GE:
case NoSqlLexer.LE:
compileComparator(node,wiring,facade,expression);
break;
case NoSqlLexer.IN:
compileComparatorIn(node,wiring,facade,expression);
break;
case NoSqlLexer.BETWEEN:
throw new UnsupportedOperationException("String_Node_Str");
default :
break;
}
}

Fixed version (ground truth):
@SuppressWarnings("String_Node_Str") private static <T>void compileExpression(ExpressionNode node,InfoForWiring wiring,MetaFacade facade){
  CommonTree expression=node.getASTNode();
  int type=expression.getType();
  if (log.isDebugEnabled())   log.debug("String_Node_Str" + expression.getType());
switch (type) {
case NoSqlLexer.AND:
case NoSqlLexer.OR:
    node.setState("String_Node_Str",null);
  List<CommonTree> children=expression.getChildren();
processSide(node,wiring,children,0,ChildSide.LEFT,facade);
processSide(node,wiring,children,1,ChildSide.RIGHT,facade);
break;
case NoSqlLexer.EQ:
case NoSqlLexer.NE:
case NoSqlLexer.GT:
case NoSqlLexer.LT:
case NoSqlLexer.GE:
case NoSqlLexer.LE:
compileComparator(node,wiring,facade,expression);
break;
case NoSqlLexer.IN:
compileComparatorIn(node,wiring,facade,expression);
break;
case NoSqlLexer.BETWEEN:
throw new UnsupportedOperationException("String_Node_Str");
default :
break;
}
}
Program: 97884
Project: 97884
Buggy source:
private Counter processAllColumns(NoSqlTypedSession s,ColFamilyData data,Map<Object,KeyValue<TypedRow>> keyToRow,Cursor<IndexPoint> indexView2){
  String colName=data.getColumn();
  indexView2.beforeFirst();
  int rowCounter=0;
  int changedCounter=0;
  while (indexView2.next()) {
    rowCounter++;
    IndexPoint pt=indexView2.getCurrent();
    KeyValue<TypedRow> row=keyToRow.get(pt.getKey());
    if (row == null) {
      log.debug("String_Node_Str" + pt.getKey());
    }
 else     if (row.getException() != null || row.getValue() == null) {
      removeIndexPt(s,data,pt);
      changedCounter++;
    }
 else {
      TypedRow val=row.getValue();
      if (processColumn(s,data,val,pt)) {
        changedCounter++;
      }
    }
    if (changedCounter > 50) {
      s.flush();
    }
    if (rowCounter % 20000 == 0) {
      System.out.println("String_Node_Str" + rowCounter + "String_Node_Str"+ changedCounter);
    }
  }
  if (totalRowCount == null)   totalRowCount=rowCounter;
  s.flush();
  return new Counter(rowCounter,changedCounter);
}

Fixed version (ground truth):
private Counter processAllColumns(NoSqlTypedSession s,ColFamilyData data,Map<Object,KeyValue<TypedRow>> keyToRow,Cursor<IndexPoint> indexView2){
  String colName=data.getColumn();
  indexView2.beforeFirst();
  int rowCounter=0;
  int changedCounter=0;
  while (indexView2.next()) {
    rowCounter++;
    IndexPoint pt=indexView2.getCurrent();
    KeyValue<TypedRow> row=keyToRow.get(pt.getKey());
    if (row == null) {
      if (log.isDebugEnabled())       log.debug("String_Node_Str" + pt.getKey());
    }
 else     if (row.getException() != null || row.getValue() == null) {
      removeIndexPt(s,data,pt);
      changedCounter++;
    }
 else {
      TypedRow val=row.getValue();
      if (processColumn(s,data,val,pt)) {
        changedCounter++;
      }
    }
    if (changedCounter > 50) {
      s.flush();
    }
    if (rowCounter % 20000 == 0) {
      System.out.println("String_Node_Str" + rowCounter + "String_Node_Str"+ changedCounter);
    }
  }
  if (totalRowCount == null)   totalRowCount=rowCounter;
  s.flush();
  return new Counter(rowCounter,changedCounter);
}
Program: 97885
Project: 97885
Buggy source:
private void process(String newLine){
  log.debug("String_Node_Str" + newLine);
  String[] commands=newLine.split("String_Node_Str");
  for (  String cmd : commands) {
    try {
      String justCmd=cmd.trim();
      processCommand(justCmd);
    }
 catch (    InvalidCommand e) {
      log.info("String_Node_Str",e);
      println("String_Node_Str" + cmd + "String_Node_Str");
      if (e.getMessage() != null)       println(e.getMessage());
    }
  }
}

Fixed version (ground truth):
private void process(String newLine){
  if (log.isDebugEnabled())   log.debug("String_Node_Str" + newLine);
  String[] commands=newLine.split("String_Node_Str");
  for (  String cmd : commands) {
    try {
      String justCmd=cmd.trim();
      processCommand(justCmd);
    }
 catch (    InvalidCommand e) {
      log.info("String_Node_Str",e);
      println("String_Node_Str" + cmd + "String_Node_Str");
      if (e.getMessage() != null)       println(e.getMessage());
    }
  }
}
Program: 97886
Project: 97886
Buggy source:
/** 
 * Uses java.class.path system-property to fetch URLs
 * @return the URL[]
 */
@Override public final URL[] findResources(ClassLoader cl){
  List<URL> list=new ArrayList<URL>();
  Enumeration<URL> resources=loadPersistenceFiles(cl);
  log.trace("String_Node_Str");
  Set<URL> urlsToScan=new HashSet<URL>();
  while (resources.hasMoreElements()) {
    URL url=resources.nextElement();
    if (urlsToScan.contains(url))     continue;
    urlsToScan.add(url);
    log.trace("String_Node_Str" + url);
  }
  if (urlsToScan.size() == 0)   throw new IllegalArgumentException("String_Node_Str");
  for (  URL fileInJarOrFolderUrl : urlsToScan) {
    String protocol=fileInJarOrFolderUrl.getProtocol();
    if ("String_Node_Str".equals(protocol)) {
      processFile(fileInJarOrFolderUrl,list);
    }
 else     if ("String_Node_Str".equals(protocol)) {
      processJar(fileInJarOrFolderUrl,list);
    }
 else     throw new RuntimeException("String_Node_Str" + protocol + "String_Node_Str");
  }
  return list.toArray(new URL[list.size()]);
}

Fixed version (ground truth):
/** 
 * Uses java.class.path system-property to fetch URLs
 * @return the URL[]
 */
@Override public final URL[] findResources(ClassLoader cl){
  List<URL> list=new ArrayList<URL>();
  Enumeration<URL> resources=loadPersistenceFiles(cl);
  if (log.isTraceEnabled())   log.trace("String_Node_Str");
  Set<URL> urlsToScan=new HashSet<URL>();
  while (resources.hasMoreElements()) {
    URL url=resources.nextElement();
    if (urlsToScan.contains(url))     continue;
    urlsToScan.add(url);
    if (log.isTraceEnabled())     log.trace("String_Node_Str" + url);
  }
  if (urlsToScan.size() == 0)   throw new IllegalArgumentException("String_Node_Str");
  for (  URL fileInJarOrFolderUrl : urlsToScan) {
    String protocol=fileInJarOrFolderUrl.getProtocol();
    if ("String_Node_Str".equals(protocol)) {
      processFile(fileInJarOrFolderUrl,list);
    }
 else     if ("String_Node_Str".equals(protocol)) {
      processJar(fileInJarOrFolderUrl,list);
    }
 else     throw new RuntimeException("String_Node_Str" + protocol + "String_Node_Str");
  }
  return list.toArray(new URL[list.size()]);
}
Program: 97887
Project: 97887
Buggy source:
@Override public void run(){
  try {
    log.debug("String_Node_Str");
    runImpl();
  }
 catch (  Exception e) {
    log.warn("String_Node_Str",e);
  }
}

Fixed version (ground truth):
@Override public void run(){
  try {
    if (log.isDebugEnabled())     log.debug("String_Node_Str");
    runImpl();
  }
 catch (  Exception e) {
    log.warn("String_Node_Str",e);
  }
}
Program: 97888
Project: 97888
Buggy source:
private void runMonitor(NoSqlEntityManager mgr,MonitorDbo monitor,DateTime now){
  log.debug("String_Node_Str" + monitor.getId());
  PlayOrmCronJob p=CopyUtil.copy(monitor);
  fireToListener(p);
  monitor.setLastRun(now);
  mgr.put(monitor);
  mgr.flush();
}

Fixed version (ground truth):
private void runMonitor(NoSqlEntityManager mgr,MonitorDbo monitor,DateTime now){
  if (log.isDebugEnabled())   log.debug("String_Node_Str" + monitor.getId());
  PlayOrmCronJob p=CopyUtil.copy(monitor);
  fireToListener(p);
  monitor.setLastRun(now);
  mgr.put(monitor);
  mgr.flush();
}
Program: 97889
Project: 97889
Buggy source:
private boolean calculateShouldRun(NoSqlEntityManager mgr,MonitorDbo monitor,DateTime now){
  DateTime lastRunTime=monitor.getLastRun();
  log.debug("String_Node_Str" + now + "String_Node_Str"+ lastRunTime+ "String_Node_Str"+ monitor.getId());
  if (lastRunTime == null) {
    return isInRunWindow(monitor,now);
  }
 else   if (nextRuntimeHasPassed(lastRunTime,monitor,now))   return true;
  return false;
}

Fixed version (ground truth):
private boolean calculateShouldRun(NoSqlEntityManager mgr,MonitorDbo monitor,DateTime now){
  DateTime lastRunTime=monitor.getLastRun();
  if (log.isDebugEnabled())   log.debug("String_Node_Str" + now + "String_Node_Str"+ lastRunTime+ "String_Node_Str"+ monitor.getId());
  if (lastRunTime == null) {
    return isInRunWindow(monitor,now);
  }
 else   if (nextRuntimeHasPassed(lastRunTime,monitor,now))   return true;
  return false;
}
Program: 97890
Project: 97890
Buggy source:
public void runImpl(){
  if (listener == null)   return;
  NoSqlEntityManager mgr=factory.createEntityManager();
  Cursor<KeyValue<WebNodeDbo>> cursor=WebNodeDbo.findAllNodes(mgr);
  List<WebNodeDbo> all=new ArrayList<WebNodeDbo>();
  List<WebNodeDbo> servers=new ArrayList<WebNodeDbo>();
  while (cursor.next()) {
    KeyValue<WebNodeDbo> kv=cursor.getCurrent();
    WebNodeDbo val=kv.getValue();
    all.add(val);
    log.debug("String_Node_Str" + val.getWebServerName());
    if (isServerUp(mgr,val)) {
      log.debug("String_Node_Str" + val.getWebServerName());
      servers.add(val);
    }
    if (val.getWebServerName().equals(config.getHostName())) {
      log.debug("String_Node_Str" + val.getWebServerName());
      saveNodeIsUp(mgr,val);
    }
  }
  mgr.clear();
  Collections.sort(servers,new ServerComparator());
  int serverNumber=-1;
  for (int i=0; i < servers.size(); i++) {
    WebNodeDbo node=servers.get(i);
    if (node.getWebServerName().equals(config.getHostName())) {
      log.debug("String_Node_Str" + i + "String_Node_Str"+ servers.size());
      serverNumber=i;
      break;
    }
  }
  if (serverNumber == -1)   throw new IllegalStateException("String_Node_Str" + all);
  runOurMonitors(mgr,servers.size(),serverNumber);
}

Fixed version (ground truth):
public void runImpl(){
  if (listener == null)   return;
  NoSqlEntityManager mgr=factory.createEntityManager();
  Cursor<KeyValue<WebNodeDbo>> cursor=WebNodeDbo.findAllNodes(mgr);
  List<WebNodeDbo> all=new ArrayList<WebNodeDbo>();
  List<WebNodeDbo> servers=new ArrayList<WebNodeDbo>();
  while (cursor.next()) {
    KeyValue<WebNodeDbo> kv=cursor.getCurrent();
    WebNodeDbo val=kv.getValue();
    all.add(val);
    if (log.isDebugEnabled())     log.debug("String_Node_Str" + val.getWebServerName());
    if (isServerUp(mgr,val)) {
      if (log.isDebugEnabled())       log.debug("String_Node_Str" + val.getWebServerName());
      servers.add(val);
    }
    if (val.getWebServerName().equals(config.getHostName())) {
      if (log.isDebugEnabled())       log.debug("String_Node_Str" + val.getWebServerName());
      saveNodeIsUp(mgr,val);
    }
  }
  mgr.clear();
  Collections.sort(servers,new ServerComparator());
  int serverNumber=-1;
  for (int i=0; i < servers.size(); i++) {
    WebNodeDbo node=servers.get(i);
    if (node.getWebServerName().equals(config.getHostName())) {
      if (log.isDebugEnabled())       log.debug("String_Node_Str" + i + "String_Node_Str"+ servers.size());
      serverNumber=i;
      break;
    }
  }
  if (serverNumber == -1)   throw new IllegalStateException("String_Node_Str" + all);
  runOurMonitors(mgr,servers.size(),serverNumber);
}
Program: 97891
Project: 97891
Buggy source:
@SuppressWarnings("String_Node_Str") @Override public void onApplicationStart(){
  List<Class> classes=Play.classloader.getAnnotatedClasses(NoSqlEntity.class);
  if (classes.isEmpty())   return;
 else   if (NoSql.getEntityManagerFactory() != null) {
    NoSqlEntityManagerFactory factory=NoSql.getEntityManagerFactory();
    factory.rescan(classes,Play.classloader);
    return;
  }
  Map<String,Object> props=new HashMap<String,Object>();
  props.put(Bootstrap.LIST_OF_EXTRA_CLASSES_TO_SCAN_KEY,classes);
  props.put(Bootstrap.AUTO_CREATE_KEY,"String_Node_Str");
  for (  java.util.Map.Entry<Object,Object> entry : Play.configuration.entrySet()) {
    props.put((String)entry.getKey(),entry.getValue());
  }
  if (log.isInfoEnabled())   log.info("String_Node_Str");
  NoSqlEntityManagerFactory factory=Bootstrap.create(props,Play.classloader);
  NoSql.setEntityManagerFactory(factory);
  CassandraAppender.setFactory(factory);
}

Fixed version (ground truth):
@SuppressWarnings("String_Node_Str") @Override public void onApplicationStart(){
  List<Class> classes=Play.classloader.getAnnotatedClasses(NoSqlEntity.class);
  if (classes.isEmpty())   return;
 else   if (NoSql.getEntityManagerFactory() != null) {
    NoSqlEntityManagerFactory factory=NoSql.getEntityManagerFactory();
    factory.rescan(classes,Play.classloader);
    return;
  }
  PROPS.put(Bootstrap.LIST_OF_EXTRA_CLASSES_TO_SCAN_KEY,classes);
  PROPS.put(Bootstrap.AUTO_CREATE_KEY,"String_Node_Str");
  for (  java.util.Map.Entry<Object,Object> entry : Play.configuration.entrySet()) {
    PROPS.put((String)entry.getKey(),entry.getValue());
  }
  if (log.isInfoEnabled())   log.info("String_Node_Str");
  NoSqlEntityManagerFactory factory=Bootstrap.create(PROPS,Play.classloader);
  NoSql.setEntityManagerFactory(factory);
  CassandraAppender.setFactory(factory);
}
Program: 97892
Project: 97892
Buggy source:
void saveMetaData(){
  BaseEntityManagerImpl tempMgr=this;
  DboDatabaseMeta existing=tempMgr.find(DboDatabaseMeta.class,DboDatabaseMeta.META_DB_ROWKEY);
  for (  DboTableMeta table : databaseInfo.getAllTables()) {
    for (    DboColumnMeta col : table.getAllColumns()) {
      tempMgr.put(col);
    }
    if (!table.isEmbeddable() && table.getIdColumnMeta() != null)     tempMgr.put(table.getIdColumnMeta());
    tempMgr.put(table);
  }
  databaseInfo.setId(DboDatabaseMeta.META_DB_ROWKEY);
  for (  StorageTypeEnum type : StorageTypeEnum.values()) {
    if (type != StorageTypeEnum.DECIMAL && type != StorageTypeEnum.INTEGER && type != StorageTypeEnum.STRING)     continue;
    DboTableMeta cf=new DboTableMeta();
    cf.setup(null,type.getIndexTableName(),false);
    cf.setColNamePrefixType(type);
    DboColumnIdMeta idMeta=new DboColumnIdMeta();
    idMeta.setup(cf,"String_Node_Str",String.class,false);
    tempMgr.put(idMeta);
    tempMgr.put(cf);
    databaseInfo.addMetaClassDbo(cf);
  }
  tempMgr.put(databaseInfo);
  tempMgr.flush();
}

Fixed version (ground truth):
void saveMetaData(){
  BaseEntityManagerImpl tempMgr=this;
  for (  DboTableMeta table : databaseInfo.getAllTables()) {
    for (    DboColumnMeta col : table.getAllColumns()) {
      tempMgr.put(col);
    }
    if (!table.isEmbeddable() && table.getIdColumnMeta() != null)     tempMgr.put(table.getIdColumnMeta());
    tempMgr.put(table);
  }
  databaseInfo.setId(DboDatabaseMeta.META_DB_ROWKEY);
  for (  StorageTypeEnum type : StorageTypeEnum.values()) {
    if (type != StorageTypeEnum.DECIMAL && type != StorageTypeEnum.INTEGER && type != StorageTypeEnum.STRING)     continue;
    DboTableMeta cf=new DboTableMeta();
    cf.setup(null,type.getIndexTableName(),false);
    cf.setColNamePrefixType(type);
    DboColumnIdMeta idMeta=new DboColumnIdMeta();
    idMeta.setup(cf,"String_Node_Str",String.class,false);
    tempMgr.put(idMeta);
    tempMgr.put(cf);
    databaseInfo.addMetaClassDbo(cf);
  }
  tempMgr.put(databaseInfo);
  tempMgr.flush();
}
Program: 97893
Project: 97893
Buggy source:
@Override public <T>T find(Class<T> entityType,Object key){
  if (key == null)   throw new IllegalArgumentException("String_Node_Str");
  List<Object> keys=new ArrayList<Object>();
  keys.add(key);
  Cursor<KeyValue<T>> entities=findAll(entityType,keys);
  entities.next();
  return entities.getCurrent().getValue();
}

Fixed version (ground truth):
@Override public <T>T find(Class<T> entityType,Object key){
  if (key == null)   throw new IllegalArgumentException("String_Node_Str");
  List<Object> keys=new ArrayList<Object>();
  keys.add(key);
  Cursor<KeyValue<T>> entities=findAll(entityType,keys);
  if (entities.next())   return entities.getCurrent().getValue();
 else   return null;
}
Program: 97894
Project: 97894
Buggy source:
@Test public void testFailureOnGetSingleResultAndSuccess(){
  Activity act=new Activity("String_Node_Str");
  act.setName("String_Node_Str");
  act.setUniqueColumn("String_Node_Str");
  act.setNumTimes(5);
  mgr.put(act);
  Activity act2=new Activity("String_Node_Str");
  act2.setUniqueColumn(act.getUniqueColumn());
  act2.setName("String_Node_Str");
  act2.setNumTimes(4);
  mgr.put(act2);
  Activity act3=new Activity("String_Node_Str");
  act3.setUniqueColumn("String_Node_Str");
  act3.setName("String_Node_Str");
  act3.setNumTimes(8);
  mgr.put(act3);
  mgr.flush();
  try {
    Activity.findSingleResult(mgr,act.getUniqueColumn());
    Assert.fail("String_Node_Str");
  }
 catch (  TooManyResultException e) {
    log.info("String_Node_Str");
  }
  Activity activity=Activity.findSingleResult(mgr,act3.getUniqueColumn());
  Assert.assertEquals(act3.getNumTimes(),activity.getNumTimes());
  Activity activityNull=Activity.findSingleResult(mgr,"String_Node_Str");
  Assert.assertNull(activityNull);
}

Fixed version (ground truth):
@Test public void testFailureOnGetSingleResultAndSuccess(){
  Activity act=new Activity("String_Node_Str");
  act.setName("String_Node_Str");
  act.setUniqueColumn("String_Node_Str");
  act.setNumTimes(5);
  mgr.put(act);
  Activity act2=new Activity("String_Node_Str");
  act2.setUniqueColumn(act.getUniqueColumn());
  act2.setName("String_Node_Str");
  act2.setNumTimes(4);
  mgr.put(act2);
  Activity act3=new Activity("String_Node_Str");
  act3.setUniqueColumn("String_Node_Str");
  act3.setName("String_Node_Str");
  act3.setNumTimes(8);
  mgr.put(act3);
  mgr.flush();
  try {
    Activity.findSingleResult(mgr,act.getUniqueColumn());
    Assert.fail("String_Node_Str");
  }
 catch (  TooManyResultException e) {
    log.info("String_Node_Str");
  }
  Activity activity=Activity.findSingleResult(mgr,act3.getUniqueColumn());
  Assert.assertEquals(act3.getNumTimes(),activity.getNumTimes());
  Activity activityNull=Activity.findSingleResult(mgr,"String_Node_Str");
  Assert.assertNull(activityNull);
  Activity activityNull2=mgr.find(Activity.class,"String_Node_Str");
  Assert.assertNull(activityNull2);
}
Program: 97895
Project: 97895
Buggy source:
private boolean isNeedPersist(OWNER entity,Object value,Map<Field,Object> fieldToValue){
  if (!(entity instanceof NoSqlProxy))   return true;
  Object originalValue=fieldToValue.get(field);
  if (value == null)   return false;
 else   if (value.equals(originalValue))   return false;
  return true;
}

Fixed version (ground truth):
private boolean isNeedPersist(OWNER entity,Object value,Map<Field,Object> fieldToValue){
  if (!(entity instanceof NoSqlProxy))   return true;
  Object originalValue=fieldToValue.get(field);
  if (valuesEqual(originalValue,value))   return false;
  return true;
}
Program: 97896
Project: 97896
Buggy source:
private void addIndexRemoves(InfoForIndex<OWNER> info,Object value,byte[] byteVal,StorageTypeEnum storageType){
  RowToPersist row=info.getRow();
  Map<Field,Object> fieldToValue=info.getFieldToValue();
  Object originalValue=fieldToValue.get(field);
  if (originalValue == null)   return;
 else   if (originalValue.equals(value))   return;
  byte[] pk=row.getKey();
  byte[] oldIndexedVal=translateValue(originalValue);
  List<IndexData> indexList=row.getIndexToRemove();
  addToList(info,oldIndexedVal,storageType,pk,indexList);
}

Fixed version (ground truth):
private void addIndexRemoves(InfoForIndex<OWNER> info,Object value,byte[] byteVal,StorageTypeEnum storageType){
  RowToPersist row=info.getRow();
  Map<Field,Object> fieldToValue=info.getFieldToValue();
  Object originalValue=fieldToValue.get(field);
  if (valuesEqual(originalValue,value))   return;
  byte[] pk=row.getKey();
  byte[] oldIndexedVal=translateValue(originalValue);
  List<IndexData> indexList=row.getIndexToRemove();
  addToList(info,oldIndexedVal,storageType,pk,indexList);
}
Program: 97897
Project: 97897
Buggy source:
public void testToOneWithUUID(){
  Account acc1=new Account();
  acc1.setId("String_Node_Str");
  acc1.setName("String_Node_Str");
  mgr.fillInWithKey(acc1);
  EntityWithUUIDKey entity=new EntityWithUUIDKey();
  entity.setSomething("String_Node_Str");
  entity.setAccount(acc1);
  mgr.fillInWithKey(entity);
  User user=new User();
  user.setUuidEntity(entity);
  mgr.put(user);
  mgr.flush();
  User user2=mgr.find(User.class,user.getId());
  Assert.assertNotNull(user2);
  Assert.assertEquals(entity.getId(),user2.getUuidEntity().getId());
}

Fixed version (ground truth):
@Test public void testToOneWithUUID(){
  Account acc1=new Account();
  acc1.setId("String_Node_Str");
  acc1.setName("String_Node_Str");
  mgr.fillInWithKey(acc1);
  EntityWithUUIDKey entity=new EntityWithUUIDKey();
  entity.setSomething("String_Node_Str");
  entity.setAccount(acc1);
  mgr.fillInWithKey(entity);
  User user=new User();
  user.setUuidEntity(entity);
  mgr.put(user);
  mgr.flush();
  User user2=mgr.find(User.class,user.getId());
  Assert.assertNotNull(user2);
  Assert.assertEquals(entity.getId(),user2.getUuidEntity().getId());
}
Program: 97898
Project: 97898
Buggy source:
private Counter processAllColumns(NoSqlTypedSession s,ColFamilyData data,Map<Object,KeyValue<TypedRow>> keyToRow,Cursor<IndexPoint> indexView2){
  String colName=data.getColumn();
  indexView2.beforeFirst();
  int rowCounter=0;
  int changedCounter=0;
  while (indexView2.next()) {
    IndexPoint pt=indexView2.getCurrent();
    KeyValue<TypedRow> row=keyToRow.get(pt.getKey());
    if (row == null) {
      log.debug("String_Node_Str" + pt.getKey());
    }
 else     if (row.getException() != null || row.getValue() == null) {
      removeIndexPt(s,data,pt);
      changedCounter++;
    }
 else {
      TypedRow val=row.getValue();
      if (processColumn(s,data,val,pt)) {
        changedCounter++;
      }
    }
    rowCounter++;
    if (changedCounter > 50) {
      s.flush();
    }
    if (rowCounter % 20000 == 0) {
      System.out.println("String_Node_Str" + rowCounter + "String_Node_Str"+ changedCounter);
    }
  }
  s.flush();
  return new Counter(rowCounter,changedCounter);
}

Fixed version (ground truth):
private Counter processAllColumns(NoSqlTypedSession s,ColFamilyData data,Map<Object,KeyValue<TypedRow>> keyToRow,Cursor<IndexPoint> indexView2){
  String colName=data.getColumn();
  indexView2.beforeFirst();
  int rowCounter=0;
  int changedCounter=0;
  while (indexView2.next()) {
    IndexPoint pt=indexView2.getCurrent();
    KeyValue<TypedRow> row=keyToRow.get(pt.getKey());
    if (row == null) {
      log.debug("String_Node_Str" + pt.getKey());
    }
 else     if (row.getException() != null || row.getValue() == null) {
      removeIndexPt(s,data,pt);
      changedCounter++;
    }
 else {
      TypedRow val=row.getValue();
      TypedColumn column=val.getColumn(colName);
      if (column == null) {
        continue;
      }
      Object value=column.getValue();
      if (!valuesEqual(pt.getIndexedValue(),value)) {
        System.out.println("String_Node_Str" + pt.getKeyAsString() + "String_Node_Str"+ pt.getIndexedValueAsString()+ "String_Node_Str"+ column.getValueAsString());
        s.removeIndexPoint(pt,data.getPartitionBy(),data.getPartitionId());
        IndexColumn col=new IndexColumn();
        col.setColumnName(colName);
        col.setPrimaryKey(pt.getRawKey());
        byte[] indValue=column.getValueRaw();
        col.setIndexedValue(indValue);
        IndexPoint newPoint=new IndexPoint(pt.getRowKeyMeta(),col,data.getColumnMeta());
        s.addIndexPoint(newPoint,data.getPartitionBy(),data.getPartitionId());
        changedCounter++;
      }
    }
    rowCounter++;
    if (changedCounter > 50) {
      s.flush();
    }
    if (rowCounter % 20000 == 0) {
      System.out.println("String_Node_Str" + rowCounter + "String_Node_Str"+ changedCounter);
    }
  }
  s.flush();
  return new Counter(rowCounter,changedCounter);
}