Hi all,

when I'm using Wait with the options

   Target Signal Count = 1
   Releasable FlowFileCount = 0

and Notfiy with the option

   Signal Counter  Delta = 1 (SCD)

the described in docs "open-close-gate" logic works fine.


But what I need is a way of "open-close-gate" logic for a specified "batch size", with 
the meaning of "as many as possible/there, but not more as the max. batch size".

So I've tried the above with

   Releasable FlowFileCount = 50


Works also fine, at first:

Tried with
  a GenerateFlowFile with a "Batch Size" of e.g. 137, followd by a wait. Run 
Once.
  a 2nd GenerateFlowFile with a "Batch Size" of 1, followed by a Notify, Signal 
Counter  Delta = 1. Run three times.

Wait releases 50/50/37 flowfiles, as expected.

My "Chaos" starts exactly now, because of the now "13 releasable flowfiles":
- If I simply start new batch, Wait releases 13 flowfiles, at once, as they're already 
"gate-opened", fine.

But as for my real requirement I would need a "brand-new" batch, 50 flowfiles 
again releasable, not only 13, I've tried a Notify with a

  Signal Counter  Delta = 0

expecting to get the map cache counter reseted, as described in docs.

What I'm getting instead is the Wait bulletining "java.lang.IllegalArgumentException: 
fromIndex(0) > to Index(-87)", in a row...
Stopped everything.
Looked "inside" counter with a FetchDistributedMapCache, which shows me the 
Counter Json with
  counts.default = 2 (as expected, after the Notify "0")
  counts.consumed = -2
  counts.releasableCount: 13

For me this looks like the Notify with Signal Counter  Delta = 0 does NOT reset 
the releasableCount also.

Is this the way it should be, or a bug?


Second question:
If in the above scnenario the Wait is active and running, with several settings for Run Schedule 
and Run Duration tried, the Counter is always "locked". Means that no idea why a 
FetchDistributedMapCache returns a "not-found". As soon the Wait is stopped, the 
FetchDistributedMapCache returns the counter's Json.

Is this "lock" also as it should be?

I'm confused :)



Regards,
Michael

Reply via email to