Examples of OIntentMassiveInsert


Examples of com.orientechnologies.orient.core.intent.OIntentMassiveInsert

    checkCurrentDatabase();

    out.println("Declaring intent '" + iIntentName + "'...");

    if (iIntentName.equalsIgnoreCase("massiveinsert"))
      currentDatabase.declareIntent(new OIntentMassiveInsert());
    else if (iIntentName.equalsIgnoreCase("massiveread"))
      currentDatabase.declareIntent(new OIntentMassiveRead());
    else
      throw new IllegalArgumentException("Intent '" + iIntentName
          + "' not supported. Available ones are: massiveinsert, massiveread");
View Full Code Here

Examples of com.orientechnologies.orient.core.intent.OIntentMassiveInsert

    @Override
    public void init() {
      database = new ODatabaseDocumentTx(System.getProperty("url")).open("admin", "admin");
      record = database.newInstance();
      database.declareIntent(new OIntentMassiveInsert());
      database.begin(TXTYPE.NOTX);

      synchronized (LocalCreateDocumentMultiThreadIndexedSpeedTest.class) {
        OClass c = database.getMetadata().getSchema().getClass("Account");
        if (c == null)
View Full Code Here

Examples of com.orientechnologies.orient.core.intent.OIntentMassiveInsert

    checkCurrentDatabase();

    out.println("Declaring intent '" + iIntentName + "'...");

    if (iIntentName.equalsIgnoreCase("massiveinsert"))
      currentDatabase.declareIntent(new OIntentMassiveInsert());
    else if (iIntentName.equalsIgnoreCase("massiveread"))
      currentDatabase.declareIntent(new OIntentMassiveRead());
    else
      throw new IllegalArgumentException("Intent '" + iIntentName
          + "' not supported. Available ones are: massiveinsert, massiveread");
View Full Code Here

Examples of com.orientechnologies.orient.core.intent.OIntentMassiveInsert

    } catch (Exception e) {
      inStream = new FileInputStream(fileName);
    }

    jsonReader = new OJSONReader(new InputStreamReader(inStream));
    database.declareIntent(new OIntentMassiveInsert());
  }
View Full Code Here

Examples of com.orientechnologies.orient.core.intent.OIntentMassiveInsert

  public ODatabaseImport(final ODatabaseDocument database, final InputStream iStream, final OCommandOutputListener iListener)
      throws IOException {
    super(database, "streaming", iListener);
    jsonReader = new OJSONReader(new InputStreamReader(iStream));
    database.declareIntent(new OIntentMassiveInsert());
  }
View Full Code Here

Examples of com.orientechnologies.orient.core.intent.OIntentMassiveInsert

    long currRecord = 0;

    if (progressListener != null)
      progressListener.onBegin(this, totRecords, false);

    database.declareIntent(new OIntentMassiveInsert());
    try {
      // BROWSE ALL THE RECORDS OF THE SOURCE CLASS
      for (ODocument doc : db.browseClass(sourceClass.getName())) {
        value = doc.field(sourceField);
View Full Code Here

Examples of com.orientechnologies.orient.core.intent.OIntentMassiveInsert

  }

  public void testSimpleRestore() throws Exception {
    List<Future<Void>> futures = new ArrayList<Future<Void>>();

    baseDocumentTx.declareIntent(new OIntentMassiveInsert());

    for (int i = 0; i < 5; i++)
      futures.add(executorService.submit(new DataPropagationTask()));

    for (Future<Void> future : futures)
View Full Code Here

Examples of com.orientechnologies.orient.core.intent.OIntentMassiveInsert

  }

  public void testSimpleRestore() throws Exception {
    List<Future<Void>> futures = new ArrayList<Future<Void>>();

    baseDocumentTx.declareIntent(new OIntentMassiveInsert());

    for (int i = 0; i < 5; i++)
      futures.add(executorService.submit(new DataPropagationTask()));

    for (Future<Void> future : futures)
View Full Code Here

Examples of com.orientechnologies.orient.core.intent.OIntentMassiveInsert

    checkForDatabase();

    message("\nDeclaring intent '" + iIntentName + "'...");

    if (iIntentName.equalsIgnoreCase("massiveinsert"))
      currentDatabase.declareIntent(new OIntentMassiveInsert());
    else if (iIntentName.equalsIgnoreCase("massiveread"))
      currentDatabase.declareIntent(new OIntentMassiveRead());
    else
      throw new IllegalArgumentException("Intent '" + iIntentName
          + "' not supported. Available ones are: massiveinsert, massiveread");
View Full Code Here

Examples of com.orientechnologies.orient.core.intent.OIntentMassiveInsert

   * Populates the index with all the existent records. Uses the massive insert intent to speed up and keep the consumed memory low.
   */
  public long rebuild(final OProgressListener iProgressListener) {
    long documentIndexed = 0;

    final boolean intentInstalled = getDatabase().declareIntent(new OIntentMassiveInsert());

    modificationLock.requestModificationLock();
    try {
      acquireExclusiveLock();
      try {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.