kafka-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From guozh...@apache.org
Subject kafka git commit: MINOR: Improve exception message that gets thrown for non-existent group
Date Mon, 09 Nov 2015 21:41:58 GMT
Repository: kafka
Updated Branches:
  refs/heads/trunk a87b97822 -> 3ebb4ee1b


MINOR: Improve exception message that gets thrown for non-existent group

Author: Ashish Singh <asingh@cloudera.com>

Reviewers: Guozhang Wang

Closes #471 from SinghAsDev/ExceptionMessage


Project: http://git-wip-us.apache.org/repos/asf/kafka/repo
Commit: http://git-wip-us.apache.org/repos/asf/kafka/commit/3ebb4ee1
Tree: http://git-wip-us.apache.org/repos/asf/kafka/tree/3ebb4ee1
Diff: http://git-wip-us.apache.org/repos/asf/kafka/diff/3ebb4ee1

Branch: refs/heads/trunk
Commit: 3ebb4ee1b0803b755eaefc3286fe107868b7b085
Parents: a87b978
Author: Ashish Singh <asingh@cloudera.com>
Authored: Mon Nov 9 13:47:55 2015 -0800
Committer: Guozhang Wang <wangguoz@gmail.com>
Committed: Mon Nov 9 13:47:55 2015 -0800

----------------------------------------------------------------------
 core/src/main/scala/kafka/admin/AdminClient.scala | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/kafka/blob/3ebb4ee1/core/src/main/scala/kafka/admin/AdminClient.scala
----------------------------------------------------------------------
diff --git a/core/src/main/scala/kafka/admin/AdminClient.scala b/core/src/main/scala/kafka/admin/AdminClient.scala
index 4618127..28f3cda 100644
--- a/core/src/main/scala/kafka/admin/AdminClient.scala
+++ b/core/src/main/scala/kafka/admin/AdminClient.scala
@@ -156,7 +156,7 @@ class AdminClient(val time: Time,
   def describeConsumerGroup(groupId: String): List[ConsumerSummary] = {
     val group = describeGroup(groupId)
     if (group.protocolType != ConsumerProtocol.PROTOCOL_TYPE)
-      throw new IllegalArgumentException(s"${group} is not a valid GroupSummary")
+      throw new IllegalArgumentException(s"Group ${groupId} is not a valid kafka consumer
group but belongs to ${if (!group.protocolType.isEmpty) group.protocolType else "not exist"}")
 
     group.members.map {
       case member =>


Mime
View raw message