Package com.orientechnologies.orient.core.db.document

Examples of com.orientechnologies.orient.core.db.document.ODatabaseDocumentTx.load()


    emptyCompositeIndex.addIndex(new OPropertyIndexDefinition("testClass", "fTwo", OType.STRING));

    final ODocument docToStore = emptyCompositeIndex.toStream();
    database.save(docToStore);

    final ODocument docToLoad = database.load(docToStore.getIdentity());

    final OCompositeIndexDefinition result = new OCompositeIndexDefinition();
    result.fromStream(docToLoad);

    database.drop();
View Full Code Here


    Assert.assertEquals(emptyCompositeIndex, emptyCompositeIndexTwo);

    final ODocument docToStore = emptyCompositeIndex.toStream();
    database.save(docToStore);

    final ODocument docToLoad = database.load(docToStore.getIdentity());

    final OCompositeIndexDefinition result = new OCompositeIndexDefinition();
    result.fromStream(docToLoad);

    database.drop();
View Full Code Here

    cont = false;

    for (Future<Void> future : futures)
      future.get();

    document = db.load(document.getIdentity());
    document.setLazyLoad(false);

    ridBag = document.field("ridBag");

    for (OIdentifiable identifiable : ridBag)
View Full Code Here

          for (int i = 0; i < 10; i++) {
            ridsToAdd.add(new ORecordId(0, OClusterPositionFactory.INSTANCE.valueOf(positionCounter.incrementAndGet())));
          }

          while (true) {
            ODocument document = db.load(docContainerRid);
            document.setLazyLoad(false);

            ORidBag ridBag = document.field("ridBag");
            for (ORID rid : ridsToAdd)
              ridBag.add(rid);
View Full Code Here

      db.declareIntent(new OIntentMassiveInsert());

      try {
        while (cont) {
          while (true) {
            ODocument document = db.load(docContainerRid);
            document.setLazyLoad(false);
            ORidBag ridBag = document.field("ridBag");
            Iterator<OIdentifiable> iterator = ridBag.iterator();

            List<ORID> ridsToDelete = new ArrayList<ORID>();
View Full Code Here

            while (test.get()) {
              final long time = System.currentTimeMillis();

              for (ODocument doc : data) {
                connection.load(doc);
                System.out.println("read " + name + " " + time);
                TimeUnit.MILLISECONDS.sleep(25);
              }

            }
View Full Code Here

    for (Future<?> future : futures)
      future.get();

    long amountOfRids = 0;
    for (ORID rid : ridTreePerDocument.keySet()) {
      ODocument document = db.load(rid);
      document.setLazyLoad(false);

      final ConcurrentSkipListSet<ORID> ridTree = ridTreePerDocument.get(rid);

      final ORidBag ridBag = document.field("ridBag");
View Full Code Here

          final long position = random.nextInt(lastClusterPosition.get().intValue());
          final ORID orid = new ORecordId(defaultClusterId, OClusterPositionFactory.INSTANCE.valueOf(position));

          while (true) {
            ODocument document = db.load(orid);
            document.setLazyLoad(false);

            ORidBag ridBag = document.field("ridBag");
            for (ORID rid : ridsToAdd)
              ridBag.add(rid);
View Full Code Here

        while (cont) {
          final long position = random.nextInt(lastClusterPosition.get().intValue());
          final ORID orid = new ORecordId(defaultClusterId, OClusterPositionFactory.INSTANCE.valueOf(position));

          while (true) {
            ODocument document = db.load(orid);
            document.setLazyLoad(false);
            ORidBag ridBag = document.field("ridBag");
            Iterator<OIdentifiable> iterator = ridBag.iterator();

            List<ORID> ridsToDelete = new ArrayList<ORID>();
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.