You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ignite.apache.org by arthi <Ar...@nielsen.com> on 2016/04/22 15:50:59 UTC

Compute Grid API in C++/Scala

Hi Team,

Is there a C++/Scala API for the compute grid? 

Thanks
Arthi



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Compute-Grid-API-in-C-Scala-tp4456.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Compute Grid API in C++/Scala

Posted by Igor Sapego <is...@gridgain.com>.
Hello Arthi,

There is no yet Compute API in C++ client, but we are planning to
add it soon.

Best Regards,
Igor

On Fri, Apr 22, 2016 at 4:50 PM, arthi <Ar...@nielsen.com>
wrote:

> Hi Team,
>
> Is there a C++/Scala API for the compute grid?
>
> Thanks
> Arthi
>
>
>
> --
> View this message in context:
> http://apache-ignite-users.70518.x6.nabble.com/Compute-Grid-API-in-C-Scala-tp4456.html
> Sent from the Apache Ignite Users mailing list archive at Nabble.com.
>

Re: Compute Grid API in C++/Scala

Posted by arthi <Ar...@nielsen.com>.
Hi Val,

we use java API to start the servers, and C++ API to start the client.
We have a custom config file for the setup. There are 6 nodes in the
cluster.

I have another issue elaborating this issue too - 
http://apache-ignite-users.70518.x6.nabble.com/Client-Connection-to-Ignite-takes-time-td4739.html

thanks for your help,
Arthi




--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Compute-Grid-API-in-C-Scala-tp4456p4754.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Compute Grid API in C++/Scala

Posted by vkulichenko <va...@gmail.com>.
Hi Arthi,

How do you start server nodes? Are they plain Java nodes or C++ nodes (like
shown in [1])? If the latter, you should be able to acquire local Ignite
instance using Ignition.get() method within C++ code. Will this work for
you?

[1]
https://apacheignite-cpp.readme.io/docs/getting-started-1#section-with-default-configuration

-Val



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Compute-Grid-API-in-C-Scala-tp4456p4751.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Compute Grid API in C++/Scala

Posted by arthi <Ar...@nielsen.com>.
hi Val,

the issue we have is, we need to create an ignite instance in each of the
compute job to run the data queries. Creating the instance takes 4-5 seconds
and the topology gets altered with more clients. 

We faced the same issue when we ran our application that triggers SQL
queries on the grid as a client. We need to support 500 + concurrent
clients, which means these client instances need to come alive, run queries
and shut down.

Is there a way to share the ignite instance so that all the clients use the
same instance?

We use C++ for the client. Something like the one described here -
http://apache-ignite-users.70518.x6.nabble.com/C-Client-Accessing-Ignite-Grid-as-Pointer-td3997.html

Thanks,
Arthi



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Compute-Grid-API-in-C-Scala-tp4456p4737.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Compute Grid API in C++/Scala

Posted by vkulichenko <va...@gmail.com>.
Arthi,

I'm not sure this actually makes sense. How are you going to use it within
the C++ code?

-Val



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Compute-Grid-API-in-C-Scala-tp4456p4734.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Compute Grid API in C++/Scala

Posted by arthi <Ar...@nielsen.com>.
One more questions...

I would need to run sql queries in the compute jobs. 
Is it possible to pass the ignite instance from the java caller to the c++
compute jobs using JNI?

Thanks,
Arthi



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Compute-Grid-API-in-C-Scala-tp4456p4729.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Compute Grid API in C++/Scala

Posted by arthi <Ar...@nielsen.com>.
Yes Val, that's the design we are hoping to implement.

Good to know that it should work.

Thank you,
Arthi



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Compute-Grid-API-in-C-Scala-tp4456p4724.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Compute Grid API in C++/Scala

Posted by vkulichenko <va...@gmail.com>.
Hi Arthi,

Let me clarify the approach:
- you're going to use Java IgniteCompute API to execute tasks;
- ComputeJob implementation will execute C++ code via JNI.

If the above is correct, it sounds absolutely fine to me, all the Compute
Grid features will be available.

-Val



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Compute-Grid-API-in-C-Scala-tp4456p4723.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Compute Grid API in C++/Scala

Posted by arthi <Ar...@nielsen.com>.
Thanks Val.

we have a c++ computing engine that currently works as an independent node
today. 
We need to reuse this engine, and deploy it as a closure / callable across
the cluster of nodes so that instances of this engine could work in parallel
for various inputs, and once they all complete, there should be a reducer
node that could join the results with certain rules and give out the
results.

This use case closely matches your compute grid capability with fork/join /
mapper/reducer. 

Since compute grid is not available in C++ today, we were thinking we we
could have java API wrapping the closures using JNA for now and have the
java compute grid do the rest. Are we thinking right? Will the load
balancing work with this design?

Please advice.

Thanks,
Arthi



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Compute-Grid-API-in-C-Scala-tp4456p4722.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Compute Grid API in C++/Scala

Posted by Vladimir Ozerov <vo...@gridgain.com>.
Hi Arthi,

I think C++ Compute API will be ready somewhere around 1.7 version. Exact
timeline is not know for now, but I think this is a matter of several
months.

Vladimir.

On Mon, Apr 25, 2016 at 8:47 AM, arthi <Ar...@nielsen.com>
wrote:

> Thanks Igor & Val.
>
> Is there a tentative timeline when the next release with C++ compute grid
> will come out?
>
> Thanks,
> Arthi
>
>
>
> --
> View this message in context:
> http://apache-ignite-users.70518.x6.nabble.com/Compute-Grid-API-in-C-Scala-tp4456p4487.html
> Sent from the Apache Ignite Users mailing list archive at Nabble.com.
>

Re: Compute Grid API in C++/Scala

Posted by arthi <Ar...@nielsen.com>.
Thanks Igor & Val. 

Is there a tentative timeline when the next release with C++ compute grid
will come out?

Thanks,
Arthi



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Compute-Grid-API-in-C-Scala-tp4456p4487.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: Compute Grid API in C++/Scala

Posted by vkulichenko <va...@gmail.com>.
Hi Arthi,

In Scala you can use Java API directly, they are fully compatible. C++
currently supports only Data Grid, but not the Compute Grid.

-Val



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/Compute-Grid-API-in-C-Scala-tp4456p4464.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.