Timer of GroupedWithin does not seem to be working. In this example, I am 
not getting any messages even after expiry of duration (10 seconds) even 
though 7 items are available in Kafka. If I produce 3 more items, then I am 
getting the entire desired batch (10 items). Please see the snippet below.


akka & akka streams Version = "2.4.19"

akka-stream-kafka Version = "0.17"


Am I missing anything? Thank you.


val consumerSettings: ConsumerSettings[Array[Byte], String] = 
ConsumerSettings(ActorSystemContainer.system, new ByteArrayDeserializer, new 
StringDeserializer)
  .withBootstrapServers(rsbProps.serverUrl)
  .withGroupId(rsbProps.groupId)
  .withProperty(ConsumerConfig.AUTO_OFFSET_RESET_CONFIG, "earliest")

Consumer.committableSource(consumerSettings, Subscriptions.topics("topic-1"))
  .groupedWithin(10, 10.seconds)
  .mapAsync(1) { group =>
    val msgs =  group.toList.map(_.record.value())
    saveToDB(msgs )
  }
  .map(group => group.foldLeft(CommittableOffsetBatch.empty) { (batch, elem) => 
  batch.updated(elem.committableOffset) 
  })
  .mapAsync(3)(_.commitScaladsl()) 

-- 
>>>>>>>>>>      Read the docs: http://akka.io/docs/
>>>>>>>>>>      Check the FAQ: 
>>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html
>>>>>>>>>>      Search the archives: https://groups.google.com/group/akka-user
--- 
You received this message because you are subscribed to the Google Groups "Akka 
User List" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to akka-user+unsubscr...@googlegroups.com.
To post to this group, send email to akka-user@googlegroups.com.
Visit this group at https://groups.google.com/group/akka-user.
For more options, visit https://groups.google.com/d/optout.

Reply via email to