Projects >> accumulo >>344b4d3a31bab7b42538497843df6420bb95b593

Chunk
Conflicting content
import java.util.List;
import java.util.concurrent.TimeUnit;

<<<<<<< HEAD
import org.apache.accumulo.core.Constants;
=======
import org.apache.commons.lang.builder.HashCodeBuilder;
>>>>>>> f99b5654340e86bb283e43641a92bc125fb43ef5
import org.apache.hadoop.io.Writable;
import org.apache.hadoop.util.StringUtils;
Solution content
import java.util.List;
import java.util.concurrent.TimeUnit;

import org.apache.accumulo.core.Constants;
import org.apache.commons.lang.builder.HashCodeBuilder;
import org.apache.hadoop.io.Writable;
import org.apache.hadoop.util.StringUtils;
File
BatchWriterConfig.java
Developer's decision
Concatenation
Kind of conflict
Import
Chunk
Conflicting content
    if (timeout != null)
      addField(fields, "timeout", timeout);
    String output = StringUtils.join(",", fields);
<<<<<<< HEAD
    
    byte[] bytes = output.getBytes(Constants.UTF8);
    byte[] len = String.format("%6s#", Integer.toString(bytes.length, 36)).getBytes(Constants.UTF8);
=======

    byte[] bytes = output.getBytes(Charset.forName("UTF-8"));
    byte[] len = String.format("%6s#", Integer.toString(bytes.length, 36)).getBytes("UTF-8");
>>>>>>> f99b5654340e86bb283e43641a92bc125fb43ef5
    if (len.length != 7)
      throw new IllegalStateException("encoded length does not match expected value");
    out.write(len);
Solution content
    if (timeout != null)
      addField(fields, "timeout", timeout);
    String output = StringUtils.join(",", fields);

    byte[] bytes = output.getBytes(Constants.UTF8);
    byte[] len = String.format("%6s#", Integer.toString(bytes.length, 36)).getBytes(Constants.UTF8);
    if (len.length != 7)
      throw new IllegalStateException("encoded length does not match expected value");
    out.write(len);
File
BatchWriterConfig.java
Developer's decision
Version 1
Kind of conflict
Method invocation
Variable
Chunk
Conflicting content
      throw new IllegalStateException("length was not encoded correctly");
    byte[] bytes = new byte[Integer.parseInt(strLen.substring(strLen.lastIndexOf(' ') + 1, strLen.length() - 1), 36)];
    in.readFully(bytes);
<<<<<<< HEAD
    
    String strFields = new String(bytes, Constants.UTF8);
=======

    String strFields = new String(bytes, Charset.forName("UTF-8"));
>>>>>>> f99b5654340e86bb283e43641a92bc125fb43ef5
    String[] fields = StringUtils.split(strFields, '\\', ',');
    for (String field : fields) {
      String[] keyValue = StringUtils.split(field, '\\', '=');
Solution content
      throw new IllegalStateException("length was not encoded correctly");
    byte[] bytes = new byte[Integer.parseInt(strLen.substring(strLen.lastIndexOf(' ') + 1, strLen.length() - 1), 36)];
    in.readFully(bytes);

    String strFields = new String(bytes, Constants.UTF8);
    String[] fields = StringUtils.split(strFields, '\\', ',');
    for (String field : fields) {
      String[] keyValue = StringUtils.split(field, '\\', '=');
File
BatchWriterConfig.java
Developer's decision
Version 1
Kind of conflict
Method invocation
Variable