2011/12/6 Samuel Feng <okos...@gmail.com>

> Thanks Peter,
>
> I studied how the HA works in
> http://docs.neo4j.org/chunked/snapshot/ha-how.html. It mentioned that "If
> the new master is elected and performs changes before the old master
> recovers, there will two different versions of the data. The old master
> will not be able to attach itself to the cluster and will require
> maintenance (replace the wrong version of the data with the one running in
> the cluster".
>
> Say, I have two neo4j instances(A & B) running, When instance A crashed, B
> continues to work and has many writes on it. Then Server A is recovered but
> it can not attach itself to the cluster as the wrong data version. So I
> need to manually replace the instance A's data using B's.
>
> But the graph size is around 4G, I have to copy all the 4G data to server
> A? Or any other simple and fast ways?
>
> Sorry that page seems outdated. Most often a previous master can rejoin
the cluster as a slave when it starts up and recovers, and if it sees that
its data has "branched" from the new master it will grab a new copy
automatically from the new master. I'll rewrite it right away.

And about moving to HA mode... the main difference code-wise is that you do:

    new HighlyAvailableGraphDatabase(...)

instead of

    new EmbeddedGraphDatabase(...)

So you can run HA in embedded or server mode, which ever you like.

Regards,
>
> Samuel
>
> 2011/12/6 Peter Neubauer <peter.neuba...@neotechnology.com>
>
> > Samuel,
> > I would recommend HA for your usecase, since then the Neo4j cluster
> > will handling new neo4j instances appearing and copying data etc. Look
> > at http://docs.neo4j.org/chunked/snapshot/ha.html for setup docs.
> >
> > There seems to be some interest in RMI remoting to neo4j. However, we
> > think this is not the ultimate way to go in the long run since it is
> > Java-centric and still not fast and stable enough for want we want to
> > achieve. However, if the community finds it useful, I am all up for
> > someone stepping up and invest the last mile to make it good, maybe
> > put it on GIThub for easier collaboration, of course.
> >
> > Tobias original code is at
> > https://svn.neo4j.org/components/remote-graphdb/trunk/, and the API
> > should not have moved terribly out of sync, so I guess it is not a LOT
> > of work to at least get it working.
> >
> > Anyone?
> >
> > Cheers,
> >
> > /peter neubauer
> >
> > GTalk:      neubauer.peter
> > Skype       peter.neubauer
> > Phone       +46 704 106975
> > LinkedIn   http://www.linkedin.com/in/neubauer
> > Twitter      http://twitter.com/peterneubauer
> >
> > brew install neo4j && neo4j start
> > heroku addons:add neo4j
> >
> >
> >
> > On Tue, Dec 6, 2011 at 4:43 AM, Samuel Feng <okos...@gmail.com> wrote:
> > > Dear List,
> > >
> > > I'm using neo4j 1.5GA and using embeddedGraphDatabase to access the
> > graph.
> > > Now the graph size is around 4G.
> > >
> > > Now I would like to try HA mode and have several questions.
> > >
> > > 1) Can I access the graph in some kind of remote mode? So that I can
> use
> > > many tomcat servers to access the graph remotely and do not need to
> > change
> > > any code. I understand neo4j can run as a server, however, we can only
> > use
> > > REST api to accessing the neo4j server, this will cause many many code
> > > changes for me. Please correct me if I have any misunderstanding.
> > >
> > > Seems there is a neo4j-remote-graphdb component which uses RMI to
> access
> > a
> > > graph remotely. BUT in the wiki
> > > http://components.neo4j.org/neo4j-remote-graphdb/stable/, you
> mentioned
> > "The
> > > implementation is not speedy enough to be used as the main access
> channel
> > > to a Graph Database for actual applications."
> > >
> > > 2) If I use neo4j embedded in HA mode, say, I have two neo4j
> instances(A
> > &
> > > B) running, When instance A crashed, B continues to work and has many
> > > writes on it. Then Server A is recovered but it can not attach itself
> to
> > > the cluster as the wrong data version. So I need to manually replace
> the
> > > instance A's data using B's.
> > >
> > > But the graph size is around 4G, I have to copy all the 4G data to
> server
> > > A? Or any other simple and fast ways?
> > >
> > > Thanks and Regards,
> > >
> > > Samuel
> > > _______________________________________________
> > > Neo4j mailing list
> > > User@lists.neo4j.org
> > > https://lists.neo4j.org/mailman/listinfo/user
> > >
> > > --
> > > You received this message because you are subscribed to the Google
> > Groups "Neo4j User Discussions" group.
> > > To post to this group, send email to u...@neo4j.org.
> > > To unsubscribe from this group, send email to
> user+unsubscr...@neo4j.org
> > .
> > > For more options, visit this group at
> > http://groups.google.com/a/neo4j.org/group/user/?hl=en.
> > >
> > _______________________________________________
> > 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
>



-- 
Mattias Persson, [matt...@neotechnology.com]
Hacker, Neo Technology
www.neotechnology.com
_______________________________________________
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user

Reply via email to