Hi,

I am glad I could help.

Note that indeed using Mesos/Marathon, I can easily launch & scale 
Ignite nodes on my cluster. It is my understanding that Ignite nodes 
will automatically rebalance the data among nodes upon scaling, is that 
right ?

If so, both solutions provide an easy and robust environment to scale in 
memory databases & grid data computing.

I'll analyze further the 3 cache modes 
(http://apacheignite.gridgain.org/docs/cache-modes), and the ability to 
set backup nodes 
(http://atlassian.gridgain.com/wiki/display/AI10/Cache+Distribution+Models)
to see how it impacts both performance and overhead memory cost on a 
cluster.

Bests,
Laurent-Philippe


Le 2016-04-15 14:53, Vladimir Ozerov [via Apache Ignite Developers] a 
écrit :
> Hi,
> Thank you for such deep and thorough analysis. I think we definitely
> reflect your findings in our documentation.
> 
> Nick,
> Provided that you worked on Mesos integration, could you please see,
> how we
> can integrate this into our docs?
> 
> Vladimir.
> 
> On Fri, Apr 15, 2016 at 1:42 AM, lpalbou <[hidden email] [1]>
> wrote:
> 
>> Hi everyone,
>> 
>> I have been testing recently Mesos and Apache Ignite. Some problems
> were
>> not
>> documented and I sometimes had to look at some java sources.
>> 
>> So this is a very small guide to help you launch Ignite nodes from
> Mesos
>> and
>> access these nodes with Java.
>> 
>> A) First, to install Mesos, I would advise to consult this tutorial
> which
>> is
>> easy to follow:
>> 
>> 
> https://www.digitalocean.com/community/tutorials/how-to-configure-a-production-ready-mesosphere-cluster-on-ubuntu-14-04
> [2]
>> 
>> B) Then, to create a Mesos framework/application to launch your
> Ignite
>> nodes, you can refer to this tutorial:
>> http://apacheignite.gridgain.org/docs/mesos-deployment [3]
>> 
>> For those having a "Got unexpected response code 404" exception in
> /stderr/
>> of a Mesos node sandbox after launching the application through
>> curl/marathon (step 3 of tutorial B) ), it basically says it can't
> download
>> the ignite-mesos.jar. I had this problem and edited the
> marathon.json (or
>> whatever the name you choose) to change the IGNITE_VERSION parameter
> 
>> previously set to 1.0.5. I first changed it to "latest" and
> everything was
>> ok until I triedto access these nodes with Java (see after). For
> now, set
>> IGNITE_VERSION to "1.5.9".
>> 
>> By now, your Ignite nodes should now launch correctly on Mesos and
> you
>> should see something similar to tutorial B) steps 5-7.
>> 
>> Now let's try to access those Ignite nodes launched by Mesos with a
> small
>> Java application. At first, it did not work at all. If you try
> something
>> like bin/ignite.sh, it will create a new cluster independant of the
> one
>> created by Mesos. So you have to setup the proper configuration. And
> there,
>> I did not find any tutorial or information on Google. So here is
> what I
>> did:
>> 
>> 1) ssh to a Mesos node running ignite
>> 2) ps -aux | grep ignite (to see the parameters used for launching
> these
>> ignite nodes)
>> 3) the spring configuration file by default was
> "ignite-default-config.xml"
>> 4) reproduce this configuration inside the java application with the
> 
>> IgniteConfiguration class (see below)
>> 5) it was not working. Looking at the Java exception, I discovered
> my java
>> app was using a different version of Ignite than Mesos (?!). Indeed,
> 
>> although the latest stable version of Ignite is 1.5.0 on the
> download page
>> (https://ignite.apache.org/download.cgi#binaries [4]), when using
> "latest" for
>> the field IGNITE_VERSION in the marathon.json file, it actually
> downloaded
>> and launched the version 1.5.9 (FWY, set IGNITE_VERSION to "1.5.9"
> to avoid
>> such mistake). I retrieve those jar from the Mesos slave nodes (look
> in
>> /tmp/mesos/slaves/.../latest/) and use them as libraries in my Java
> app
>> 5) but it was still not working !? "Failed to connect to any address
> from
>> IP
>> finder (will retry to join topology every 2 secs)". To make a long
> story
>> short, you have to provide to your IpFinder some IP addresses of
> your Mesos
>> slave nodes... and it worked !
>> 
>> 
>> *Here is a very small Java code to help you connect to your Mesos
> Ignite
>> nodes:*
>> 
>> Collection<String> addr = new ArrayList();
>> addr.add("X.X.X.X"); // replace this by IP addresses of ignite nodes
> 
>> addr.add("X.X.X.X"); // replace this by IP addresses of ignite nodes
> 
>> 
>> TcpDiscoveryVmIpFinder tcpvm = new TcpDiscoveryVmIpFinder();
>> tcpvm.setAddresses(addr);
>> 
>> TcpDiscoverySpi dspi = new TcpDiscoverySpi();
>> dspi.setIpFinder(tcpvm);
>> dspi.setJoinTimeout(60000);
>> 
>> IgniteConfiguration cfg = new IgniteConfiguration();
>> cfg.setDiscoverySpi(dspi);
>> cfg.setClientMode(true);
>> 
>> Ignite ignite = Ignition.start(cfg);
>> 
>> 
>> I hope this will be of some use to some of you.
>> Bests,
>> LPA
>> 
>> 
>> 
>> --
>> View this message in context:
>> 
> http://apache-ignite-developers.2346864.n4.nabble.com/Small-how-to-for-Mesos-Ignite-Java-tp8467.html
> [5]
>> Sent from the Apache Ignite Developers mailing list archive at
> Nabble.com.
>> 
> 
> -------------------------
> 
> If you reply to this email, your message will be added to the
> discussion below:
> http://apache-ignite-developers.2346864.n4.nabble.com/Small-how-to-for-Mesos-Ignite-Java-tp8467p8481.html
> [6]
>  To unsubscribe from Small how to for Mesos + Ignite + Java, click
> here [7].
>  NAML [8]
> 
> Links:
> ------
> [1] 
> http://webmail.wisims.org/user/SendEmail.jtp?type=node&node=8481&i=0
> [2]
> https://www.digitalocean.com/community/tutorials/how-to-configure-a-production-ready-mesosphere-cluster-on-ubuntu-14-04
> [3] http://apacheignite.gridgain.org/docs/mesos-deployment
> [4] https://ignite.apache.org/download.cgi#binaries
> [5]
> http://apache-ignite-developers.2346864.n4.nabble.com/Small-how-to-for-Mesos-Ignite-Java-tp8467.html
> [6]
> http://apache-ignite-developers.2346864.n4.nabble.com/Small-how-to-for-Mesos-Ignite-Java-tp8467p8481.html
> [7]
> http://apache-ignite-developers.2346864.n4.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&amp;node=8467&amp;code=bGF1cmVudC5hbGJvdUBnZW5vZ25vc2Uub3JnfDg0Njd8MjE3MzcwNjkx
> [8]
> http://apache-ignite-developers.2346864.n4.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&amp;id=instant_html%21nabble%3Aemail.naml&amp;base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&amp;breadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml




--
View this message in context: 
http://apache-ignite-developers.2346864.n4.nabble.com/Small-how-to-for-Mesos-Ignite-Java-tp8467p8489.html
Sent from the Apache Ignite Developers mailing list archive at Nabble.com.

Reply via email to