Re: [Neo4j] Neo4j embedded

2011-10-07 Thread Jim Webber
Hi,

When using Neo4j in embedded mode, communication with the database is via 
in-process Java method calls* since the database resides in your process.

However when Neo4j is used in HA mode (irrespective of whether it is  embedded 
or server), then it will use sockets to maintain consistency of the cluster.

Jim

* so I guess technically the communication mechanism is stack frames :-)
___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] Neo4j embedded

2011-10-07 Thread Antriani Stylianou
Ok,thanks!

Do you have any suggestions as to what is the best way to use neo4j to 
benchmark it against a mysql  database (with an equal in communication 
overhead manner)?

On 10/7/11 12:23 PM, Jim Webber wrote:
 Hi,

 When using Neo4j in embedded mode, communication with the database is via 
 in-process Java method calls* since the database resides in your process.

 However when Neo4j is used in HA mode (irrespective of whether it is  
 embedded or server), then it will use sockets to maintain consistency of the 
 cluster.

 Jim

 * so I guess technically the communication mechanism is stack frames :-)
 ___
 Neo4j mailing list
 User@lists.neo4j.org
 https://lists.neo4j.org/mailman/listinfo/user

___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] Neo4j embedded

2011-10-07 Thread Jim Webber
Hi Antriani,

Since Neo4j is an embedded database, the equal is quite legitimately to use 
the Java APIs.

If you want to introduce network and serialisation overhead, then use the REST 
API.

But I really believe that you should measure the performance of your *system* 
not just your database. So if you can replace MySQL (or whatever) in your 
system with Neo4j embedded, then do so and measure that. If you can't (e.g. 
you're not on the JVM) then replace it with a sensible use of the REST API and 
measure that.

Jim

On 7 Oct 2011, at 11:28, Antriani Stylianou wrote:

 Ok,thanks!
 
 Do you have any suggestions as to what is the best way to use neo4j to 
 benchmark it against a mysql  database (with an equal in communication 
 overhead manner)?
 
 On 10/7/11 12:23 PM, Jim Webber wrote:
 Hi,
 
 When using Neo4j in embedded mode, communication with the database is via 
 in-process Java method calls* since the database resides in your process.
 
 However when Neo4j is used in HA mode (irrespective of whether it is  
 embedded or server), then it will use sockets to maintain consistency of the 
 cluster.
 
 Jim
 
 * so I guess technically the communication mechanism is stack frames :-)
 ___
 Neo4j mailing list
 User@lists.neo4j.org
 https://lists.neo4j.org/mailman/listinfo/user
 
 ___
 Neo4j mailing list
 User@lists.neo4j.org
 https://lists.neo4j.org/mailman/listinfo/user

___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] Neo4j embedded

2011-10-07 Thread Antriani Stylianou
Ok, but the REST API doesn't produce more network overhead (i.e. 
HTTP...) compared to a driver implementation using sockets for access 
for example MySQL JDBC  ?

On 10/7/11 12:53 PM, Jim Webber wrote:
 Hi Antriani,

 Since Neo4j is an embedded database, the equal is quite legitimately to use 
 the Java APIs.

 If you want to introduce network and serialisation overhead, then use the 
 REST API.

 But I really believe that you should measure the performance of your *system* 
 not just your database. So if you can replace MySQL (or whatever) in your 
 system with Neo4j embedded, then do so and measure that. If you can't (e.g. 
 you're not on the JVM) then replace it with a sensible use of the REST API 
 and measure that.

 Jim

 On 7 Oct 2011, at 11:28, Antriani Stylianou wrote:

 Ok,thanks!

 Do you have any suggestions as to what is the best way to use neo4j to
 benchmark it against a mysql  database (with an equal in communication
 overhead manner)?

 On 10/7/11 12:23 PM, Jim Webber wrote:
 Hi,

 When using Neo4j in embedded mode, communication with the database is via 
 in-process Java method calls* since the database resides in your process.

 However when Neo4j is used in HA mode (irrespective of whether it is  
 embedded or server), then it will use sockets to maintain consistency of 
 the cluster.

 Jim

 * so I guess technically the communication mechanism is stack frames :-)
 ___
 Neo4j mailing list
 User@lists.neo4j.org
 https://lists.neo4j.org/mailman/listinfo/user
 ___
 Neo4j mailing list
 User@lists.neo4j.org
 https://lists.neo4j.org/mailman/listinfo/user
 ___
 Neo4j mailing list
 User@lists.neo4j.org
 https://lists.neo4j.org/mailman/listinfo/user

___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] Neo4j embedded

2011-10-07 Thread Jim Webber
Hi Antriani,

 Ok, but the REST API doesn't produce more network overhead (i.e. 
 HTTP...) compared to a driver implementation using sockets for access 
 for example MySQL JDBC  ?

I have no data to support this, but I'm going to make an educated guess and say 
that the MySQL JDBC driver is overall faster than our REST API :-)

But my point stands: measure your system, not its components.

Neo4j might well have a slower network API than MySQL, but you might find that 
because of the data model, you ship less data over the network, or the queries 
run so much faster that network differences become negligible.

Something will be your bottleneck in either the Neo4j case or the MySQL case, 
but if the Neo4j case is faster despite having a slower network interface, then 
you might not care.

Jim
___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] Neo4j embedded

2011-10-07 Thread Jacob Hansson
If you choose to use the server or if you choose the embedded database will
have a significant impact on how those results turn out. For performing
large queries, the server should not be much slower than the embedded
database. It will be significantly slower (more than two orders of
magnitude) on single read/write operations.

Like Jim mentioned, we are looking at a new REST implementation that
essentially nullifies this speed difference. It is currently at an
experimental stage, but we will make sure to share details and get feedback
on it from y'all as it progresses, stay tuned.

/Jake

On Fri, Oct 7, 2011 at 3:15 PM, Antriani Stylianou antrian...@gmail.comwrote:

 Thanks again for the answer but my system is actually a benchmarking
 system!
 In other words I am trying to find out if there are performance
 difference between the 2 DBs not through an application.

 On 10/7/11 1:36 PM, Jim Webber wrote:
  Hi Antriani,
 
  Ok, but the REST API doesn't produce more network overhead (i.e.
  HTTP...) compared to a driver implementation using sockets for access
  for example MySQL JDBC  ?
  I have no data to support this, but I'm going to make an educated guess
 and say that the MySQL JDBC driver is overall faster than our REST API :-)
 
  But my point stands: measure your system, not its components.
 
  Neo4j might well have a slower network API than MySQL, but you might find
 that because of the data model, you ship less data over the network, or the
 queries run so much faster that network differences become negligible.
 
  Something will be your bottleneck in either the Neo4j case or the MySQL
 case, but if the Neo4j case is faster despite having a slower network
 interface, then you might not care.
 
  Jim
  ___
  Neo4j mailing list
  User@lists.neo4j.org
  https://lists.neo4j.org/mailman/listinfo/user

 ___
 Neo4j mailing list
 User@lists.neo4j.org
 https://lists.neo4j.org/mailman/listinfo/user




-- 
Jacob Hansson
Phone: +46 (0) 763503395
Twitter: @jakewins
___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] Neo4j embedded database with monitoring tool

2011-08-09 Thread Anders Nawroth
Hi!

Neoclipse instantiates an EmbeddedReadOnlyGraphDatabase to read the 
database.

Regarding monitoring, have a look here:
http://docs.neo4j.org/chunked/snapshot/tutorials-java-embedded-jmx.html
and here:
http://docs.neo4j.org/chunked/snapshot/operations-monitoring.html

/anders

On 08/09/2011 12:40 AM, noppanit wrote:
 Just out of interests, what about neoclipse? I think I can run neoclipse in
 read-only mode parallel with the working database. How can I achieve the
 same thing?

 --
 View this message in context: 
 http://neo4j-community-discussions.438527.n3.nabble.com/Neo4j-embedded-database-with-monitoring-tool-tp3236863p3237094.html
 Sent from the Neo4j Community Discussions mailing list archive at Nabble.com.
 ___
 Neo4j mailing list
 User@lists.neo4j.org
 https://lists.neo4j.org/mailman/listinfo/user
___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] Neo4j embedded database with monitoring tool

2011-08-09 Thread noppanit
Cheers. :)

--
View this message in context: 
http://neo4j-community-discussions.438527.n3.nabble.com/Neo4j-embedded-database-with-monitoring-tool-tp3236863p3238275.html
Sent from the Neo4j Community Discussions mailing list archive at Nabble.com.
___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] Neo4j embedded database with monitoring tool

2011-08-08 Thread Michael Hunger
This information (# of nodes and rels) is available using JMX which can be 
queried separately without accessing the graphdb.

You can provide similar custom monitoring by adding JMX MBeans to your app.

Then those can be viewed using jconsole or a similar tool.

Cheers

Michael

Am 08.08.2011 um 23:22 schrieb noppanit:

 I'm building an application with embedded database, but also I'm trying to
 build a monitoring tool where it will shows me how many relationships, nodes
 and categorise those nodes to represent in some kind of charts using google
 chart. My question would be in embedded database, it only allows one
 instance at a time, how could I implement a monitoring tool in the
 background to just query the data without disrupting the front-end?
 
 Best,
 T.
 
 --
 View this message in context: 
 http://neo4j-community-discussions.438527.n3.nabble.com/Neo4j-embedded-database-with-monitoring-tool-tp3236863p3236863.html
 Sent from the Neo4j Community Discussions mailing list archive at Nabble.com.
 ___
 Neo4j mailing list
 User@lists.neo4j.org
 https://lists.neo4j.org/mailman/listinfo/user

___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] Neo4j embedded database with monitoring tool

2011-08-08 Thread noppanit
Sorry, but I'm not familiar with JMX. Would that mean that I'm allowed to
connect to the database and query something and return that in JSON so
Google Chart can display that on the web which the front-end is still
running and being used by user? So, the back-end can display real-time data? 

--
View this message in context: 
http://neo4j-community-discussions.438527.n3.nabble.com/Neo4j-embedded-database-with-monitoring-tool-tp3236863p3236997.html
Sent from the Neo4j Community Discussions mailing list archive at Nabble.com.
___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] Neo4j embedded database with monitoring tool

2011-08-08 Thread Michael Hunger
JMX is a asynchronous monitoring mechanism employed by the jvm to visualize a 
plenthora of information.

Just start jconsole from your local jdk installation, and point it to any 
running virtual machine. On the last mbeans tab you see the custom mbeans 
registered by that app. If you point it at your Neo4j-Application you can see 
the mbeans registered by the kernel and the information provided by those 
(those are also listed in webadmin if you use the Neo4j-Server)

It is possible to consume jmx endpoints easily from a java-application which 
then might push that information as a webapp to end users rendered in whatever 
way you want.

HTH

Michael

Am 09.08.2011 um 00:12 schrieb noppanit:

 Sorry, but I'm not familiar with JMX. Would that mean that I'm allowed to
 connect to the database and query something and return that in JSON so
 Google Chart can display that on the web which the front-end is still
 running and being used by user? So, the back-end can display real-time data? 
 
 --
 View this message in context: 
 http://neo4j-community-discussions.438527.n3.nabble.com/Neo4j-embedded-database-with-monitoring-tool-tp3236863p3236997.html
 Sent from the Neo4j Community Discussions mailing list archive at Nabble.com.
 ___
 Neo4j mailing list
 User@lists.neo4j.org
 https://lists.neo4j.org/mailman/listinfo/user

___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user


Re: [Neo4j] Neo4j embedded database with monitoring tool

2011-08-08 Thread noppanit
Thanks a lot! :)

--
View this message in context: 
http://neo4j-community-discussions.438527.n3.nabble.com/Neo4j-embedded-database-with-monitoring-tool-tp3236863p3237064.html
Sent from the Neo4j Community Discussions mailing list archive at Nabble.com.
___
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user