You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ignite.apache.org by pgarg <pg...@gridgain.com> on 2015/05/09 20:27:14 UTC

Using existing server in a compute grid

/asked by hamid moazed/

I have an application, a server which partially acts as a datastore. I run
many instances of this server and wish do implement a distributed query.

First, I have gotten it to work by: having a small standalone program that
uses Ignite to distribute a query using a webmethod that connects to
localhost in each machine and does a query. If I set PeerClassLoadingEnabled
to true in my code that works fine, but I don't know what jars I need to
copy to where to get it to work on the remote nodes. The remote nodes run a
very small program that simply does an Ignite.start(cfg); I did read in the
docs that I need to put all required jars in lib/ directory, where should
this lib directory be? In the classpath?

The second problem I have is I would like to integrate Ignite with my
server, meaning to have Ignite distribute the query call within the same JVM
as my server, and I want to be able to call methods in my server directly
instead of through a web method call. When I try I get a Caused by:
java.lang.NoSuchMethodException:
com.foo.bar.Server.$deserializeLambda$(java.lang.invoke.SerializedLambda)
Any help would be greatly appreciated.

----- 
/This post is migrated from now discontinued Apache Ignite forum at 
http://apacheignite.readme.io/v1.0/discuss/



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Using-existing-server-in-a-compute-grid-tp229.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Using existing server in a compute grid

Posted by pgarg <pg...@gridgain.com>.
/commented by hamid moazed/

Just wanted to add, PARTITIONED is probably a better cache mode for my use
case.

----- 
/This post is migrated from now discontinued Apache Ignite forum at 
http://apacheignite.readme.io/v1.0/discuss/



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Using-existing-server-in-a-compute-grid-tp229p231.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Using existing server in a compute grid

Posted by pgarg <pg...@gridgain.com>.
/commented by hamid moazed/

I figured it out. In each of my servers I start an Ignition node with
REPLICATED cache mode, then I use IgniteCompute to send the query to all the
server nodes, each of which puts its own local results in an IgniteSet. The
set as a whole is then visible from the master node with all the results.
The exceptions I was suffering from stemmed from the fact that class
containing the closure method had fields which Ignite (rightfully) would try
to serialize. I can still use those classes, inside the methods, i just
cannot have them as fields. I had not realized this.

----- 
/This post is migrated from now discontinued Apache Ignite forum at 
http://apacheignite.readme.io/v1.0/discuss/



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Using-existing-server-in-a-compute-grid-tp229p230.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.