OrientDB 1.7 -> OGraphDatabase will be removed. What ?!?!

956 views
Skip to first unread message

Luca Garulli

unread,
Jan 29, 2014, 5:26:21 AM1/29/14
to orient-database
Hi all,
we're very close to merge the new storage structure to the 1.7 branch. Andrey has some awesome numbers about the performance of the new engine in terms of benchmarks, he will share them with us on this group very soon.

But in order to complete the merge, we should remove the old Graph API: OGraphDatabase! This is mainly for 2 big reasons:
  1. it's not compatible with Lightweight edges and other improvements we introduced since version 1.4.x
  2. it heavily uses MVRB-Tree indexes so it wouldn't scale on the new storage structure
So after a while we deprecated the old Graph API, it's time to removed it from the v1.7 code base. I know some users are still sticked with this API, they can decide to:
  1. Migrate to the Blueprints API (well documented on OrientDB & TinkerPop sites)
  2. Stay with old API and remain sticked to last OrientDB v1.6.x.
Obviously we strongly suggest 1st solution!

For the users want to migrate we will provide a new guide to migrate the old code (very easy, most of the concepts are the same). In this way they could benefits of HUGE improvement with last version of OrientDB, specially with big databases.

Any comments are welcome :-)

Lvc@

Andrey Yesyev

unread,
Jan 29, 2014, 9:34:46 AM1/29/14
to orient-...@googlegroups.com
I just started looking into OrientDB as substitution for Neo4j. It really looks good, especially performance, but documentation....
Guys, take some time to clean up docs!!! It's very confusing now. If 1.7 uses Blueprints API only, this is huge improvement in documentation.
Can't wait to try it.

Krasimir Cholakov

unread,
Jan 30, 2014, 2:44:25 AM1/30/14
to orient-...@googlegroups.com
Yes, the old deprecated API should go away. Looking forward to see Andrey's new cool stuff :)

Cheers. 

Claudio

unread,
Jan 30, 2014, 10:30:30 AM1/30/14
to orient-...@googlegroups.com
Hi Luca,
we use the old OGraphDatabase API  to create a new fresh graph database if it does not exists when our application starts.
db = new OGraphDatabase( "plocal:" + dbPath ) ; 
if (!db.exists()) {
info("DB does not exist, BaasBox will create a new one");
db.create();
}

As far I know the OrientGraph API hasn't got the exists() method, on the contrary, its constructor raises an error if the specified DB  does not exists.
Any advice on this?

Furthermore we use it to create vertices:
ODocument vertex = db.createVertex(CLASS_VERTEX_NAME);

Inspecting the OrientGraph API, I cannot find a similar API. I just found the addVertex(iClassName, iClusterName) that accepts two parameters instead of just the class name

Thanks,
Claudio

Andrey Lomakin

unread,
Jan 30, 2014, 11:33:10 AM1/30/14
to orient-database

Hi,
To create graph db in such way just use 

db = Orient.instance().getDatabaseFactory().createDatabase("graph", "plocal:" + dbPath)
if (!db.exists()) {
info("DB does not exist, BaasBox will create a new one");
db.create();
}

About the second question, you have several variants.

Two of them:
1.   db.addVertex("class:" + CLASS_VERTEX_NAME);
2.  db.addVertex(CLASS_VERTEX_NAME, null);  



--
 
---
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/groups/opt_out.



--
Best regards,
Andrey Lomakin.

Orient Technologies
the Company behind OrientDB

Claudio Tesoriero

unread,
Jan 30, 2014, 12:28:30 PM1/30/14
to orient-...@googlegroups.com

Thanks!

You received this message because you are subscribed to a topic in the Google Groups "OrientDB" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/orient-database/oFYb96sM7Jg/unsubscribe.
To unsubscribe from this group and all its topics, send an email to orient-databa...@googlegroups.com.

Riccardo Tasso

unread,
Jan 30, 2014, 3:59:03 PM1/30/14
to orient-...@googlegroups.com
And what about the ConnectionPool? If I remember well it was usable only from OGraphDatabase.

Thanks,
   Riccardo


2014-01-30 Claudio Tesoriero <giast...@gmail.com>:

Andrey Lomakin

unread,
Jan 31, 2014, 3:37:12 AM1/31/14
to orient-database
Hi,
Connection pool can be used from document database.
Create document database and pass it in OrientGraph it is a bit inconvenient but we did benchmark of import of wikipedia data structure it is 10-15 times faster on some data sets.

Luca Garulli

unread,
Jan 31, 2014, 3:55:21 AM1/31/14
to orient-database
Hi,
we've this issue about a new graph pool to avoid mixing API:


This will be fixed at days.

Lvc@

Andrey Lomakin

unread,
Jan 31, 2014, 4:22:20 AM1/31/14
to orient-database
Hi,
Here is difference in implementations in tx mode, local + mvrbtree + unique index (old) and plocal + ridbag + unique index (new).
benchmark-ridbag-wal-sbtree.csv
benchmark-local-mvrbtree-unique-txmode.csv

Andrey Lomakin

unread,
Jan 31, 2014, 4:25:59 AM1/31/14
to orient-database
Couple of words about benchmark.

We imported wikipedia data using OrientGraph database, to be sure that we have no duplications unique index by page key was created.

First benchmark that is benchmark which uses 1.6.4 version of OrientDB and second benchmark uses version from https://github.com/orientechnologies/orientdb/tree/rid-set-sbtree branch.


Sylvain Spinelli

unread,
Jan 31, 2014, 5:26:20 AM1/31/14
to orient-...@googlegroups.com
Hi Andrey,

interesting benchmark.

The point interesting for me is memory consumption.
With plocal how memory is configured ? Could you execute the same test with max memory settings divided by 2, by 4, by 8... ? In order to estimate when times became crazy or OOM is thrown.

Why this point is important for me ? Of course in dedicated server with 64 or 128Gb RAM it's not so important, but I have 2 other use cases :
  • standalone application (with orient embedded running on the client computer). Memory settings must be automatic/dynamic and should start to work with very few memory. Of course if the user create millions records, it is normal that the application requires more memory.
  • low-cost cloud. We plan to deploy a new very low-cost solution with shared server. Each user has his own webapp and OriendDb instance but running in the same Tomcat server. So we must fix memory settings, with quite low values for each user.
That's why evaluate how performance degrades with less memory is very interesting.

Thanks,
Sylvain

Luca Garulli

unread,
Jan 31, 2014, 6:34:15 AM1/31/14
to orient-database

Andrey Lomakin

unread,
Jan 31, 2014, 7:06:37 AM1/31/14
to orient-database
Hi Sylvain,
What I can not run such many tests, what is RAM amount you are interesting for.
Lets say 2 GB will good enough ?
Actually I can push benchmark on github so you will be able to run it if you do not mind.

Riccardo Tasso

unread,
Feb 5, 2014, 3:38:52 AM2/5/14
to orient-...@googlegroups.com

2014-01-31 Andrey Lomakin <lomakin...@gmail.com>:

Create document database and pass it in OrientGraph it is a bit inconvenient

What do you mean with inconvenient?

Riccardo

Andrey Lomakin

unread,
Feb 5, 2014, 3:42:37 AM2/5/14
to orient-database
Hi Riccardo,
I lost context that is answer on what message ?

Also we found that passing of database may lead to problems in multithreading environment so you I suggest you to use graph factory with active pool.


--
 
---
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/groups/opt_out.

Riccardo Tasso

unread,
Feb 6, 2014, 5:50:38 AM2/6/14
to orient-...@googlegroups.com
Hi, I'm using the following code:

ODatabaseDocumentPool pool = new ODatabaseDocumentPool(url, user, password);

...

ODatabaseDocumentTx db = null;
try {
db = pool.acquire();
final OSQLSynchQuery<ODocument> query = getQuery(params);
List<ODocument> queryResult = db.query(query, paramsMap);
return results;
} catch(Exception e) {
e.printStackTrace();
} finally {
if (isNotNull(db)) db.close();
}

I can't use the GraphFactory since I'm tight to OrientDB 1.6.3 and can't swithc right now.

Do you think it's appropriate use of connection pool?
Cheers,
   Riccardo

Andrey Lomakin

unread,
Feb 6, 2014, 6:13:16 AM2/6/14
to orient-database
Hi,
Yes, all is correct.

Anders Persson

unread,
May 8, 2014, 12:46:37 PM5/8/14
to orient-...@googlegroups.com
Hi

Do you havea link to this:

  1. Migrate to the Blueprints API (well documented on OrientDB & TinkerPop sites)

Regards

Anders
Reply all
Reply to author
Forward
0 new messages