RE: Continuous Queries with several remote filter on the same cache

2020-07-07 Thread Roman.Koriakov
Hi Denis,

What do you think about some improvements in @IgniteAsyncCallback regarding 
usability? What if we add a number of threads parameter in @IgniteAsyncCallback?

Best regards,
Roman

-Original Message-
From: Denis Magda  
Sent: Friday, June 26, 2020 7:38 PM
To: dev 
Subject: Re: Continuous Queries with several remote filter on the same cache

Roman,

The updates are ordered per partition. Let's take this example of an 
application updating several records:

put (k1, val1) => mapped to partition_10 => node_A put (k2, val2) => mapped to 
partition_5 => node_B put (k3, val3) => mapped to partition_10 => node_A

It's guaranteed that a continuous query listener will be notified about k1 and 
k3 updates in this order - k1 first and k3 after. As for the k2 update, it can 
arrive at any time (i.e., before k1, after k3 or in the middle).




-
Denis


On Fri, Jun 26, 2020 at 12:58 AM  wrote:

> Hi Denis,
>
> Thanks! Is there some guarantee about the order of the updates? Even 
> when we have multiple cache nodes.
>
> Best regards,
> Roman
>
> -Original Message-
> From: Denis Magda 
> Sent: Monday, June 8, 2020 10:20 PM
> To: dev 
> Subject: Re: Continuous Queries with several remote filter on the same 
> cache
>
> Roman,
>
> Please check the following methods:
> * CacheContiniousQueryHandler (the filter usage):
>
> https://github.com/apache/ignite/blob/6955ac291352dd67c1f84a006cda512e
> e54f38bb/modules/core/src/main/java/org/apache/ignite/internal/process
> ors/cache/query/continuous/CacheContinuousQueryHandler.java#L994
> * CacheContinuousQueryManager (the listener execution):
>
> https://github.com/apache/ignite/blob/master/modules/core/src/main/jav
> a/org/apache/ignite/internal/processors/cache/query/continuous/CacheCo
> ntinuousQueryManager.java#L376
>
> -
> Denis
>
>
> On Sun, Jun 7, 2020 at 12:19 AM  wrote:
>
> > Hi Denis,
> > A big thank you for the answer.
> > Could you please tell me where can I find this logic in the sources.
> > Which package should I look into?
> >
> > -Original Message-
> > From: Denis Magda 
> > Sent: Saturday, June 6, 2020 2:07 AM
> > To: dev 
> > Subject: Re: Continuous Queries with several remote filter on the 
> > same cache
> >
> > Hi Roman,
> >
> > Every continuous query is a unique entity that is processed by 
> > servers independently. With your example, the server node will 
> > execute all 20 filters for every cache insert/update operation. The 
> > server will notify through local listeners only those clients whose 
> > remote filters returned 'true'.
> >
> > -
> > Denis
> >
> >
> > On Thu, Jun 4, 2020 at 8:44 PM  wrote:
> >
> > > Hi Community,
> > >
> > > I ask this question here because I haven't found the answer in the 
> > > documentation.
> > >
> > > Could you please clarify how Continuous Queries work? What the 
> > > behavior of Continuous Queries if we have several clients with 
> > > different Remote Filters on the same cache? For example, if we have:
> > > one server node with cache and we have up to 20 client nodes each 
> > > of them will execute Continuous Query on the same cache but with 
> > > different Remote Filters. Will each client get the data according 
> > > to its remote filter? Or it is supposed to have only one Remote 
> > > Filter for all clients and every client should filter data in its 
> > > local event
> > listener?
> > > I would be grateful if you send some link which describes the 
> > > behavior of Continuous Queries more thoroughly.
> > > Best regards,
> > > Roman
> > >
> >
>


RE: Continuous Queries with several remote filter on the same cache

2020-06-26 Thread Roman.Koriakov
Hi Denis,

Thanks! Is there some guarantee about the order of the updates? Even when we 
have multiple cache nodes.

Best regards,
Roman

-Original Message-
From: Denis Magda  
Sent: Monday, June 8, 2020 10:20 PM
To: dev 
Subject: Re: Continuous Queries with several remote filter on the same cache

Roman,

Please check the following methods:
* CacheContiniousQueryHandler (the filter usage):
https://github.com/apache/ignite/blob/6955ac291352dd67c1f84a006cda512ee54f38bb/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/continuous/CacheContinuousQueryHandler.java#L994
* CacheContinuousQueryManager (the listener execution):
https://github.com/apache/ignite/blob/master/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/continuous/CacheContinuousQueryManager.java#L376

-
Denis


On Sun, Jun 7, 2020 at 12:19 AM  wrote:

> Hi Denis,
> A big thank you for the answer.
> Could you please tell me where can I find this logic in the sources. 
> Which package should I look into?
>
> -Original Message-
> From: Denis Magda 
> Sent: Saturday, June 6, 2020 2:07 AM
> To: dev 
> Subject: Re: Continuous Queries with several remote filter on the same 
> cache
>
> Hi Roman,
>
> Every continuous query is a unique entity that is processed by servers 
> independently. With your example, the server node will execute all 20 
> filters for every cache insert/update operation. The server will 
> notify through local listeners only those clients whose remote filters 
> returned 'true'.
>
> -
> Denis
>
>
> On Thu, Jun 4, 2020 at 8:44 PM  wrote:
>
> > Hi Community,
> >
> > I ask this question here because I haven't found the answer in the 
> > documentation.
> >
> > Could you please clarify how Continuous Queries work? What the 
> > behavior of Continuous Queries if we have several clients with 
> > different Remote Filters on the same cache? For example, if we have:
> > one server node with cache and we have up to 20 client nodes each of 
> > them will execute Continuous Query on the same cache but with 
> > different Remote Filters. Will each client get the data according to 
> > its remote filter? Or it is supposed to have only one Remote Filter 
> > for all clients and every client should filter data in its local 
> > event
> listener?
> > I would be grateful if you send some link which describes the 
> > behavior of Continuous Queries more thoroughly.
> > Best regards,
> > Roman
> >
>


RE: Continuous Queries with several remote filter on the same cache

2020-06-07 Thread Roman.Koriakov
Hi Denis,
A big thank you for the answer.
Could you please tell me where can I find this logic in the sources. Which 
package should I look into?

-Original Message-
From: Denis Magda  
Sent: Saturday, June 6, 2020 2:07 AM
To: dev 
Subject: Re: Continuous Queries with several remote filter on the same cache

Hi Roman,

Every continuous query is a unique entity that is processed by servers 
independently. With your example, the server node will execute all 20 filters 
for every cache insert/update operation. The server will notify through local 
listeners only those clients whose remote filters returned 'true'.

-
Denis


On Thu, Jun 4, 2020 at 8:44 PM  wrote:

> Hi Community,
>
> I ask this question here because I haven't found the answer in the 
> documentation.
>
> Could you please clarify how Continuous Queries work? What the 
> behavior of Continuous Queries if we have several clients with 
> different Remote Filters on the same cache? For example, if we have: 
> one server node with cache and we have up to 20 client nodes each of 
> them will execute Continuous Query on the same cache but with 
> different Remote Filters. Will each client get the data according to 
> its remote filter? Or it is supposed to have only one Remote Filter 
> for all clients and every client should filter data in its local event 
> listener?
> I would be grateful if you send some link which describes the behavior 
> of Continuous Queries more thoroughly.
> Best regards,
> Roman
>


Continuous Queries with several remote filter on the same cache

2020-06-04 Thread Roman.Koriakov
Hi Community,

I ask this question here because I haven't found the answer in the 
documentation.

Could you please clarify how Continuous Queries work? What the behavior of 
Continuous Queries if we have several clients with different Remote Filters on 
the same cache? For example, if we have: one server node with cache and we have 
up to 20 client nodes each of them will execute Continuous Query on the same 
cache but with different Remote Filters. Will each client get the data 
according to its remote filter? Or it is supposed to have only one Remote 
Filter for all clients and every client should filter data in its local event 
listener?
I would be grateful if you send some link which describes the behavior of 
Continuous Queries more thoroughly.
Best regards,
Roman


RE: When Cache Metrics are switched on (statisticsEnabled = true) the empty cache events arrive to the client nodes

2019-12-25 Thread Roman.Koriakov
Hi Ivan,
Does it mean that the problem is gone and I should close the JIRA IGNITE-12445 ?


-Original Message-
From: Ivan Pavlukhin  
Sent: Monday, December 16, 2019 11:05 PM
To: dev 
Subject: Re: When Cache Metrics are switched on (statisticsEnabled = true) the 
empty cache events arrive to the client nodes

I also checked the reproducer with current master. It seems that the problem is 
fixed there.

пн, 16 дек. 2019 г. в 19:36, Ilya Kasnacheev :
>
> Hello!
>
> Is there a chance you are using Zk?
>
> I believe it's https://issues.apache.org/jira/browse/IGNITE-6564
>
> Regards,
> --
> Ilya Kasnacheev
>
>
> пт, 13 дек. 2019 г. в 12:24, :
>
> > Hi Community,
> >
> > I’d like to ask you about the following behavior of Apache Ignite:
> >
> >
> > If we want to react on some PUT or READ cache operations first of 
> > all we need to turn on the appropriate cache events on the server 
> > node and catch those events on the client nodes using remote approach with 
> > two listeners.
> > It works well until we switch on statisticsEnabled on the server 
> > node, it will lead to the situation when we get empty CacheEvent objects.
> >
> > The example that demonstrates this issue is in the attachments. This 
> > example is consists of three nodes:  1 server node with cache and 2 
> > clients.  One client is filling the cache and the second one is 
> > listening PUT operations. When we turn on Cache Metrics on the server node:
> > cacheConfig.setStatisticsEnabled(true); in EventServerCache.java we 
> > get empty events (Sometimes CacheEvent objects with null fields. 
> > Sometimes there are no events at all)
> >
> > My suppose is there is some Exception in 
> > GridCacheEventManager.addEvent() when Cache Metrics is turned on.
> >
> > catch (Exception e) {
> >   if
> > (!cctx.cacheObjectContext().kernalContext().cacheObjects().isBinaryEnabled(cctx.config()))
> > throw e;  if (log.isDebugEnabled())
> >  log.debug("Failed to unmarshall cache object value for the 
> > event
> > notification: " + e);
> >
> >   if (!forceKeepBinary)
> > LT.warn(log, "Failed to unmarshall cache object value for the 
> > event notification " +
> >  "(all further notifications will keep binary object 
> > format).");
> >
> >   forceKeepBinary = true;
> >
> >   key0 = cctx.cacheObjectContext().unwrapBinaryIfNeeded(key, true, 
> > false);
> >
> >   val0 = cctx.cacheObjectContext().unwrapBinaryIfNeeded(newVal, 
> > true, false);
> >
> >   oldVal0 = cctx.cacheObjectContext().unwrapBinaryIfNeeded(oldVal, 
> > true, false);
> >
> > }
> >
> > Can public this point in JIRA?
> >
> > Best regards,
> >
> > T-Systems RUS
> > Point of Production
> > Roman Koriakov
> > Software Developer
> > Kirova 11, Voronezh, Russia
> > Tel: + 7 473 200 15 30
> > E-mail: 
> > roman.koria...@t-systems.com
> > http://www.t-systems.com
> >
> >
> >
> > -Original Message-
> > From: Ilya Kasnacheev 
> > Sent: Thursday, December 12, 2019 6:35 PM
> > To: dev 
> > Subject: Re: joining
> >
> >
> >
> > Hello!
> >
> >
> >
> > You will need to register on https://issues.apache.org/jira/ first.
> >
> >
> >
> > Please tell me when you do.
> >
> >
> >
> > Regards,
> >
> > --
> >
> > Ilya Kasnacheev
> >
> >
> >
> >
> >
> > чт, 12 дек. 2019 г. в 18:09,  > roman.koria...@t-systems.com>>:
> >
> >
> >
> > > Hi Ilya,
> >
> > >
> >
> > > it’d be nice if it were rkoriakov
> >
> > >
> >
> > >
> >
> > >
> >
> > > Best regards,
> >
> > >
> >
> > > T-Systems RUS
> >
> > > Point of Production
> >
> > > Roman Koriakov
> >
> > > Software Developer
> >
> > > Kirova 11, Voronezh, Russia
> >
> > > Tel: + 7 473 200 15 30
> >
> > > E-mail: 
> > > roman.koria...@t-systems.com >  > ms.com
> > >>
> >
> > > http://www.t-systems.com > http://www.t-systems.com%3chttp:/www.t-systems.ru/>>
> >
> > >
> >
> > >
> >
> > >
> >
> > > -Original Message-
> >
> > > From: Ilya Kasnacheev  > ilya.kasnach...@gmail.com>>
> >
> > > Sent: Thursday, December 12, 2019 5:25 PM
> >
> > > To: dev mailto:dev@ignite.apache.org>>
> >
> > > Subject: Re: joining
> >
> > >
> >
> > >
> >
> > >
> >
> > > Hello!
> >
> > >
> >
> > >
> >
> > >
> >
> > > I will need an Apache JIRA username to add you to contributors. 
> > > Can you
> >
> > > provide it?
> >
> > >
> >
> > >
> >
> > >
> >
> > > Regards,
> >
> > >
> >
> > > --
> >
> > >
> >
> > > Ilya Kasnacheev
> >
> > >
> >
> > >
> >
> > >
> >
> > >
> >
> > >
> >
> > > чт, 12 дек. 2019 г. в 17:20,  >
> > > roman.koria...@t-systems.com>>:
> >
> > >
> >
> > >
> >
> > >
> >
> > > > Hi everyone,
> >
> > >
> >
> > > > I'd like to participate in this  project!
> >
> > >
> >
> > > >
> >
> > >
> >
> > > > Best regards,
> >
> > >
> >
> > > >
> >
> > >
> >
> > > > T-Systems RUS
> >
> > >
> >
> > > > Point of Production
> >
> > 

When Cache Metrics are switched on (statisticsEnabled = true) the empty cache events arrive to the client nodes

2019-12-13 Thread Roman.Koriakov
Hi Community,

I’d like to ask you about the following behavior of Apache Ignite:


If we want to react on some PUT or READ cache operations first of all we need 
to turn on the appropriate cache events on the server node and catch those 
events on the client nodes using remote approach with two listeners. It works 
well until we switch on statisticsEnabled on the server node, it will lead to 
the situation when we get empty CacheEvent objects.

The example that demonstrates this issue is in the attachments. This example is 
consists of three nodes:  1 server node with cache and 2 clients.  One client 
is filling the cache and the second one is listening PUT operations. When we 
turn on Cache Metrics on the server node: 
cacheConfig.setStatisticsEnabled(true); in EventServerCache.java we get empty 
events (Sometimes CacheEvent objects with null fields. Sometimes there are no 
events at all)

My suppose is there is some Exception in GridCacheEventManager.addEvent() when 
Cache Metrics is turned on.

catch (Exception e) {
  if 
(!cctx.cacheObjectContext().kernalContext().cacheObjects().isBinaryEnabled(cctx.config()))
throw e;  if (log.isDebugEnabled())
 log.debug("Failed to unmarshall cache object value for the event 
notification: " + e);

  if (!forceKeepBinary)
LT.warn(log, "Failed to unmarshall cache object value for the event 
notification " +
 "(all further notifications will keep binary object format).");

  forceKeepBinary = true;

  key0 = cctx.cacheObjectContext().unwrapBinaryIfNeeded(key, true, false);

  val0 = cctx.cacheObjectContext().unwrapBinaryIfNeeded(newVal, true, false);

  oldVal0 = cctx.cacheObjectContext().unwrapBinaryIfNeeded(oldVal, true, false);

}

Can public this point in JIRA?

Best regards,

T-Systems RUS
Point of Production
Roman Koriakov
Software Developer
Kirova 11, Voronezh, Russia
Tel: + 7 473 200 15 30
E-mail: roman.koria...@t-systems.com
http://www.t-systems.com



-Original Message-
From: Ilya Kasnacheev 
Sent: Thursday, December 12, 2019 6:35 PM
To: dev 
Subject: Re: joining



Hello!



You will need to register on https://issues.apache.org/jira/ first.



Please tell me when you do.



Regards,

--

Ilya Kasnacheev





чт, 12 дек. 2019 г. в 18:09, 
mailto:roman.koria...@t-systems.com>>:



> Hi Ilya,

>

> it’d be nice if it were rkoriakov

>

>

>

> Best regards,

>

> T-Systems RUS

> Point of Production

> Roman Koriakov

> Software Developer

> Kirova 11, Voronezh, Russia

> Tel: + 7 473 200 15 30

> E-mail: 
> roman.koria...@t-systems.com>

> http://www.t-systems.com>

>

>

>

> -Original Message-

> From: Ilya Kasnacheev 
> mailto:ilya.kasnach...@gmail.com>>

> Sent: Thursday, December 12, 2019 5:25 PM

> To: dev mailto:dev@ignite.apache.org>>

> Subject: Re: joining

>

>

>

> Hello!

>

>

>

> I will need an Apache JIRA username to add you to contributors. Can you

> provide it?

>

>

>

> Regards,

>

> --

>

> Ilya Kasnacheev

>

>

>

>

>

> чт, 12 дек. 2019 г. в 17:20,  roman.koria...@t-systems.com>>:

>

>

>

> > Hi everyone,

>

> > I'd like to participate in this  project!

>

> >

>

> > Best regards,

>

> >

>

> > T-Systems RUS

>

> > Point of Production

>

> > Roman Koriakov

>

> > Software Developer

>

> > Kirova 11, Voronezh, Russia

>

> > Tel: + 7 473 200 15 30

>

> > E-mail: 
> > roman.koria...@t-systems.com

>  >>

>

> > http://www.t-systems.com

> http://www.t-systems.com%3chttp:/www.t-systems.ru/>>

>

> >

>

> >

>


RE: joining

2019-12-12 Thread Roman.Koriakov
Hi Ilya,

it’d be nice if it were rkoriakov



Best regards,

T-Systems RUS
Point of Production
Roman Koriakov
Software Developer
Kirova 11, Voronezh, Russia
Tel: + 7 473 200 15 30
E-mail: roman.koria...@t-systems.com
http://www.t-systems.com



-Original Message-
From: Ilya Kasnacheev 
Sent: Thursday, December 12, 2019 5:25 PM
To: dev 
Subject: Re: joining



Hello!



I will need an Apache JIRA username to add you to contributors. Can you provide 
it?



Regards,

--

Ilya Kasnacheev





чт, 12 дек. 2019 г. в 17:20, 
mailto:roman.koria...@t-systems.com>>:



> Hi everyone,

> I'd like to participate in this  project!

>

> Best regards,

>

> T-Systems RUS

> Point of Production

> Roman Koriakov

> Software Developer

> Kirova 11, Voronezh, Russia

> Tel: + 7 473 200 15 30

> E-mail: 
> roman.koria...@t-systems.com>

> http://www.t-systems.com>

>

>


joining

2019-12-12 Thread Roman.Koriakov
Hi everyone,
I'd like to participate in this  project!

Best regards,

T-Systems RUS
Point of Production
Roman Koriakov
Software Developer
Kirova 11, Voronezh, Russia
Tel: + 7 473 200 15 30
E-mail: roman.koria...@t-systems.com
http://www.t-systems.com