You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@kafka.apache.org by "Guozhang Wang (JIRA)" <ji...@apache.org> on 2018/09/17 16:26:00 UTC

[jira] [Resolved] (KAFKA-7316) Use of filter method in KTable.scala may result in StackOverflowError

     [ https://issues.apache.org/jira/browse/KAFKA-7316?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Guozhang Wang resolved KAFKA-7316.
----------------------------------
    Resolution: Fixed

> Use of filter method in KTable.scala may result in StackOverflowError
> ---------------------------------------------------------------------
>
>                 Key: KAFKA-7316
>                 URL: https://issues.apache.org/jira/browse/KAFKA-7316
>             Project: Kafka
>          Issue Type: Bug
>          Components: streams
>    Affects Versions: 2.0.0
>            Reporter: Ted Yu
>            Priority: Major
>              Labels: scala
>             Fix For: 2.0.1, 2.1.0
>
>         Attachments: 7316.v4.txt
>
>
> In this thread:
> http://search-hadoop.com/m/Kafka/uyzND1dNbYKXzC4F1?subj=Issue+in+Kafka+2+0+0+
> Druhin reported seeing StackOverflowError when using filter method from KTable.scala
> This can be reproduced with the following change:
> {code}
> diff --git a/streams/streams-scala/src/test/scala/org/apache/kafka/streams/scala/StreamToTableJoinScalaIntegrationTestImplicitSerdes.scala b/streams/streams-scala/src/test/scala
> index 3d1bab5..e0a06f2 100644
> --- a/streams/streams-scala/src/test/scala/org/apache/kafka/streams/scala/StreamToTableJoinScalaIntegrationTestImplicitSerdes.scala
> +++ b/streams/streams-scala/src/test/scala/org/apache/kafka/streams/scala/StreamToTableJoinScalaIntegrationTestImplicitSerdes.scala
> @@ -58,6 +58,7 @@ class StreamToTableJoinScalaIntegrationTestImplicitSerdes extends StreamToTableJ
>      val userClicksStream: KStream[String, Long] = builder.stream(userClicksTopic)
>      val userRegionsTable: KTable[String, String] = builder.table(userRegionsTopic)
> +    userRegionsTable.filter { case (_, count) => true }
>      // Compute the total per region by summing the individual click counts per region.
>      val clicksPerRegion: KTable[String, Long] =
> {code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)