How to browse through records in in-memoryDB

102 views
Skip to first unread message

Shivanandan Gupta

unread,
Feb 19, 2015, 12:37:12 PM2/19/15
to orient-...@googlegroups.com
Hi All,

We wanted to use in-memory DB in orientdb. So i created an in-memoryDB and create a class with 74 properties, then I used jsonETL code to bulk load 1 million vertex to the class. The load was over in 50 seconds and I was very happy to see the quick data load. Now I went to the orientdb browser and did select from class and post execution I got 0 records, then I went to the schema tab and there also I can see that 0 records are there for the class I loaded 1 million records.

Can someone help me to browse through the records which I loaded in the in-memoryDB. the server I have not shutdown post records load.

The same set of records I loaded to the plocal database and I can browse through the records there.

If anyone has implemented and used the in-memory orientDB thenplease help me.

Thanks,
Shivanandan Gupta

Shivanandan Gupta

unread,
Feb 20, 2015, 2:40:41 AM2/20/15
to orient-...@googlegroups.com
Can someone please help me on this , as currently I am doing evaluation of orientdb and based on this we will decide to go with orientdb or to analyze another no-sql db.

really appreciate your help.

Thanks,
Shivanandan Gupta

Luigi Dell'Aquila

unread,
Feb 20, 2015, 4:25:22 AM2/20/15
to orient-...@googlegroups.com
Hi Shivanandan,

sorry for late answer. To do what you want to achieve you have to start an embedded server and then use the ETL from the Java API. This way the ETL will be executed in the same VM of the server, and when the ETL terminates the server will remain up and running and you will be able to query the in-memory db. Of course, when you shut down the application the DB will be lost (if it's an in-memory only db...)

To create a simple application that launches an embedded server you can refer to this:


About invoking the ETL from Java API instead of command line, I suggest you to take a look at the source code of OETLProcessor (its main() method is directly invoked from the command line tool)


Thanks

Luigi






--

---
You received this message because you are subscribed to the Google Groups "OrientDB" group.
To unsubscribe from this group and stop receiving emails from it, send an email to orient-databa...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Shivanandan Gupta

unread,
Feb 20, 2015, 6:14:51 AM2/20/15
to orient-...@googlegroups.com
Hi Luige,

Thanks a lot for your help , I will try this out.

Thanks.
Shivanandan Gupta

Shivanandan Gupta

unread,
Feb 23, 2015, 4:38:09 AM2/23/15
to orient-...@googlegroups.com
Hi Luigi,

I am getting below given error when trying to run the script (PFA the script). java program is not able to import the jar files , I have placed them in the lib folder inside jdk.

Error Message:

C:\Program Files\Java\jdk1.8.0_31\bin>javac.exe C:\odb\OrientDBEmbeddable.java
C:\odb\OrientDBEmbeddable.java:3: error: package com.orientechnologies.orient.server does not exist
import com.orientechnologies.orient.server.OServerMain;
                                          ^
C:\odb\OrientDBEmbeddable.java:8: error: cannot find symbol
                OServerMain
                ^
  symbol:   variable OServerMain
  location: class OrientDBEmbeddable
2 errors



Thanks,
Shivanandan Gupta
OrientDBEmbeddable.txt

Shivanandan Gupta

unread,
Feb 23, 2015, 5:11:30 AM2/23/15
to orient-...@googlegroups.com
Hi Luigi,

I have fixed that class path issue, but now getting the below given error for the same program.


C:\Program Files\Java\jdk1.8.0_31\bin>javac -classpath ..\lib\orientdb-server-2.0.1.jar OrientDBEmbeddable.java
OrientDBEmbeddable.java:6: error: cannot find symbol
  OServer server = OServerMain.create();
  ^
  symbol:   class OServer
  location: class OrientDBEmbeddable
1 error


Thanks,
Shivanandan Gupta

Shivanandan Gupta

unread,
Feb 23, 2015, 5:25:49 AM2/23/15
to orient-...@googlegroups.com
Hi Luigi,

I imported all classes from like this "com.orientechnologies.orient.server.*;" and the code ran without giving any error or any other message. I ran for approx. 2 seconds and then came out from the program without any message.


Am i doing something wrong here?


C:\Program Files\Java\jdk1.8.0_31\bin>javac -classpath ..\lib\orientdb-server-2.0.1.jar OrientDBEmbeddable.java

C:\Program Files\Java\jdk1.8.0_31\bin>


-- Shivanandan Gupta
Message has been deleted

Shivanandan Gupta

unread,
Feb 24, 2015, 2:37:18 AM2/24/15
to orient-...@googlegroups.com
Hi Luigi,

It will be great if you can guide me here. I am attaching OrientDBEmbeddable.java file and the configuration file which I am using.

Thank you.

Shivanandan Gupta

OrientDBEmbeddable.java
orientdb-server-config.xml
Reply all
Reply to author
Forward
0 new messages