Package org.nasutekds.server.core

Examples of org.nasutekds.server.core.AddOperationBasis


   * @throws Exception   If something went wrong.
   */
  private ResultCode addEntry(String entryString) throws Exception
  {
    Entry entry;
    AddOperationBasis addOp;
    entry = TestCaseUtils.entryFromLdifString(entryString);
    addOp = new AddOperationBasis(connection,
       InternalClientConnection.nextOperationID(), InternalClientConnection
       .nextMessageID(), null, entry.getDN(), entry.getObjectClasses(),
       entry.getUserAttributes(), entry.getOperationalAttributes());
    addOp.setInternalOperation(true);
    addOp.run();

    entryList.add(entry.getDN());
    return addOp.getResultCode();
  }
View Full Code Here


      InternalClientConnection connection, String newDn)
  throws LDAPException, ASN1Exception
  {
    ArrayList<RawAttribute> attr = decodeRawAttributes(encodedAttributes);

    AddOperationBasis add =  new AddOperationBasis(connection,
        InternalClientConnection.nextOperationID(),
        InternalClientConnection.nextMessageID(), null,
        ByteString.valueOf(newDn), attr);
    AddContext ctx = new AddContext(getChangeNumber(), getUniqueId(),
        parentUniqueId);
    add.setAttachment(SYNCHROCONTEXT, ctx);
    return add;
  }
View Full Code Here

            "ds-cfg-enabled: true",
            "ds-cfg-use-ssl: false", "ds-cfg-listen-port: "
                + serverJmxPort, "cn: JMX Connection Handler");
    InternalClientConnection connection =
      InternalClientConnection.getRootConnection();
    AddOperationBasis addOp = new AddOperationBasis(connection,
        InternalClientConnection.nextOperationID(),
        InternalClientConnection.nextMessageID(), null,
        newJmxConnectionJmx.getDN(), newJmxConnectionJmx
            .getObjectClasses(), newJmxConnectionJmx
            .getUserAttributes(), newJmxConnectionJmx
            .getOperationalAttributes());
    addOp.run();
    Thread.sleep(200);
    OpendsJmxConnector newJmxConnector = connect(
        "cn=Privileged User,o=test", "password", serverJmxPort);
    assertNotNull(newJmxConnector);
    newJmxConnector.close();
View Full Code Here

      assertTrue(checkWindows(WINDOW_SIZE));
      assertTrue(checkChangelogQueueSize(REPLICATION_QUEUE_SIZE));

      // Create an Entry (add operation) that will be later used in the test.
      Entry tmp = personEntry.duplicate(false);
      AddOperationBasis addOp = new AddOperationBasis(connection,
          InternalClientConnection.nextOperationID(), InternalClientConnection
          .nextMessageID(), null, tmp.getDN(),
          tmp.getObjectClasses(), tmp.getUserAttributes(),
          tmp.getOperationalAttributes());
      addOp.run();
      assertEquals(addOp.getResultCode(), ResultCode.SUCCESS);
      assertTrue(DirectoryServer.entryExists(personEntry.getDN()),
        "The Add Entry operation failed");

      // Check if the client has received the MSG
      ReplicationMsg msg = broker.receive();
View Full Code Here

TOP

Related Classes of org.nasutekds.server.core.AddOperationBasis

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.