mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

Jean-Noel Rouvignac
09.01.2015 5cd7bdbbda0fa9f1aa6e12d9171c3811b73feb07
opendj-server-legacy/src/main/java/org/opends/server/tools/RebuildIndex.java
@@ -42,7 +42,6 @@
import org.forgerock.i18n.LocalizableMessageDescriptor.Arg1;
import org.forgerock.i18n.slf4j.LocalizedLogger;
import org.forgerock.opendj.config.server.ConfigException;
import org.forgerock.opendj.ldap.ByteString;
import org.opends.server.admin.std.server.BackendCfg;
import org.opends.server.api.Backend;
import org.opends.server.api.Backend.BackendOperation;
@@ -767,13 +766,7 @@
    // Required attributes
    addLdapAttribute(attributes, ATTR_REBUILD_BASE_DN, baseDNString.getValue());
    final List<String> indexes = indexList.getValues();
    final ArrayList<ByteString> values = new ArrayList<>(indexes.size());
    for (final String s : indexes)
    {
      values.add(ByteString.valueOf(s));
    }
    attributes.add(new LDAPAttribute(ATTR_REBUILD_INDEX, values));
    attributes.add(new LDAPAttribute(ATTR_REBUILD_INDEX, indexList.getValues()));
    if (hasNonDefaultValue(tmpDirectory))
    {
@@ -798,7 +791,7 @@
  private void addLdapAttribute(List<RawAttribute> attributes, String attrType, String attrValue)
  {
    attributes.add(new LDAPAttribute(attrType, toByteStrings(attrValue)));
    attributes.add(new LDAPAttribute(attrType, attrValue));
  }
  private boolean hasNonDefaultValue(BooleanArgument arg)
@@ -813,13 +806,6 @@
        && !arg.getValue().equals(arg.getDefaultValue());
  }
  private ArrayList<ByteString> toByteStrings(String value)
  {
    final ArrayList<ByteString> values = new ArrayList<>(1);
    values.add(ByteString.valueOf(value));
    return values;
  }
  /** {@inheritDoc} */
  @Override
  public String getTaskObjectclass()