samza-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Shekar Tippur <ctip...@gmail.com>
Subject Re: Samza and sliding window
Date Thu, 02 Jul 2015 23:36:43 GMT
Yi,

Looks like it is working now. There was a redundant line in the config.

I am able to initialize kv store and add values.
In the window code, I am unable to retrieve them and mark them as 0.

Here is my window code:

public void window(MessageCollector collector,

      TaskCoordinator coordinator) {

  //store.delete(appName);

  collector.send(new OutgoingMessageEnvelope(OUTPUT_STREAM, eventsSeen));

  KeyValueIterator<String, String> i = store.all();

  while(i.hasNext()){

   Entry <String, String> next = i.next();

   log.info("Trying to remove Key", next.getKey());

   //i.remove();



  }

  eventsSeen = 0;

  i.close();



  }


How do I retrieve the key and is there a way to remove it? i.remove throws
an exception.


- Shekar

On Wed, Jul 1, 2015 at 7:25 PM, Shekar Tippur <ctippur@gmail.com> wrote:

> Yi,
>
> Here is my config file:
> http://pastebin.com/Kf3C9E0h
>
> - S
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message