[ https://issues.apache.org/jira/browse/KAFKA-1146?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13834116#comment-13834116 ]
Joel Koshy commented on KAFKA-1146: ----------------------------------- We could just print something like "%s kafka stream".format(clientId) - there's very little information that the KafkaStream class exposes. However, this is more to protect against iterating over the full stream on a toString call. toString on KafkaStream does not really make sense - so even a message to that effect should be fine. > toString() on KafkaStream gets stuck indefinitely > ------------------------------------------------- > > Key: KAFKA-1146 > URL: https://issues.apache.org/jira/browse/KAFKA-1146 > Project: Kafka > Issue Type: Bug > Components: consumer > Affects Versions: 0.8 > Reporter: Arup Malakar > Assignee: Neha Narkhede > Priority: Trivial > Fix For: 0.8.1 > > > There is no toString implementation for KafkaStream, so if a user tries to > print the stream it falls back to default toString implementation which tries > to iterate over the collection and gets stuck indefinitely as it awaits > messages. KafkaStream could instead override the toString and return a > verbose description of the stream with topic name etc. > println("Current stream: " + stream) // This call never returns -- This message was sent by Atlassian JIRA (v6.1#6144)