You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ignite.apache.org by DanieleBosetti <D....@cmcmarkets.com> on 2018/08/31 09:06:45 UTC

What is the precise definition of classes eligible for P2P-classloading?

Hi,

I have enabled p2p classloading, and this works well when submitting compute
code, eg. IgniteCallable-s.
On the other hand, it seems that p2p-classloading does NOT import data
classes, is that right?
(So, I think I will put data classes on the servers.)

Regarding classes that are indeed p2p-classloaded- how does that work
exactly?
I mean, does Ignite only p2p-load classes if they extend IgniteCallable (or
other ignite "lang" interfaces)? Or, what is the property that enables a
class to be eligible for p2p-loading?

Thanks,
(love the platform!)



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: What is the precise definition of classes eligible for P2P-classloading?

Posted by DanieleBosetti <D....@cmcmarkets.com>.
Hi Dmirty,
thanks for replying.

I just realized that the p2p-classloading will behave differently, if I
create a remote filter using these two alternatives:
      qry.setRemoteFilterFactory( new MyRemoteFilterFactory() );
      qry.setRemoteFilterFactory(FactoryBuilder.factoryOf(
MyEntryEventFilter.class ));

(the MyRemoteFilterFactory class depends on the MyEntryEventFilter class.)

In the first case, the server p2p-loads the MyEntryEventFilter class. In the
second case, it doesn't; and when registering, will have a
ClassNotFoundException on the server side.

I understand that is related to the fact that using the javax builder we
lose some dependency information?

(altough this makes sense, it is easy to get confused- at least for me!)




--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: What is the precise definition of classes eligible for P2P-classloading?

Posted by dkarachentsev <dk...@gridgain.com>.
Hi,

There are no such limitations on peer class loading, but it was designed and
works for compute jobs, remote filters or queries only. All unknown classes
from tasks or queries will be deployed in cluster with dependencies
according to deployment mode [1]. Actually with job Ignite sends deployment
that is used to deploy all required classes.

[1]
https://ignite.apache.org/releases/latest/javadoc/org/apache/ignite/configuration/DeploymentMode.html

Thanks!
-Dmitry



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/