kafka-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From j...@apache.org
Subject [kafka] branch trunk updated: MINOR: AdminClient consumer group domain objects should have public constructors (#5063)
Date Tue, 22 May 2018 18:23:58 GMT
This is an automated email from the ASF dual-hosted git repository.

jgus pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/kafka.git


The following commit(s) were added to refs/heads/trunk by this push:
     new 5be47a2  MINOR: AdminClient consumer group domain objects should have public constructors
(#5063)
5be47a2 is described below

commit 5be47a2f269ad5356a19c353c1e53e20bf9c140c
Author: Jason Gustafson <jason@confluent.io>
AuthorDate: Tue May 22 11:23:47 2018 -0700

    MINOR: AdminClient consumer group domain objects should have public constructors (#5063)
    
    These constructors should be public to allow users to write test cases using them. We
follow a similar pattern for the other domain objects that we expose in `AdminClient` (e.g.
`TopicDescription`).
    
    Reviewers: Ismael Juma <ismael@juma.me.uk>
---
 .../apache/kafka/clients/admin/ConsumerGroupDescription.java | 12 ++++++------
 .../org/apache/kafka/clients/admin/MemberAssignment.java     |  2 +-
 .../org/apache/kafka/clients/admin/MemberDescription.java    |  2 +-
 3 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/clients/src/main/java/org/apache/kafka/clients/admin/ConsumerGroupDescription.java
b/clients/src/main/java/org/apache/kafka/clients/admin/ConsumerGroupDescription.java
index bc3857d..933d66c 100644
--- a/clients/src/main/java/org/apache/kafka/clients/admin/ConsumerGroupDescription.java
+++ b/clients/src/main/java/org/apache/kafka/clients/admin/ConsumerGroupDescription.java
@@ -37,12 +37,12 @@ public class ConsumerGroupDescription {
     private final ConsumerGroupState state;
     private final Node coordinator;
 
-    ConsumerGroupDescription(String groupId,
-            boolean isSimpleConsumerGroup,
-            Collection<MemberDescription> members,
-            String partitionAssignor,
-            ConsumerGroupState state,
-            Node coordinator) {
+    public ConsumerGroupDescription(String groupId,
+                                    boolean isSimpleConsumerGroup,
+                                    Collection<MemberDescription> members,
+                                    String partitionAssignor,
+                                    ConsumerGroupState state,
+                                    Node coordinator) {
         this.groupId = groupId == null ? "" : groupId;
         this.isSimpleConsumerGroup = isSimpleConsumerGroup;
         this.members = members == null ? Collections.<MemberDescription>emptyList()
:
diff --git a/clients/src/main/java/org/apache/kafka/clients/admin/MemberAssignment.java b/clients/src/main/java/org/apache/kafka/clients/admin/MemberAssignment.java
index 6c180ad..8765c17 100644
--- a/clients/src/main/java/org/apache/kafka/clients/admin/MemberAssignment.java
+++ b/clients/src/main/java/org/apache/kafka/clients/admin/MemberAssignment.java
@@ -34,7 +34,7 @@ public class MemberAssignment {
      *
      * @param topicPartitions List of topic partitions
      */
-    MemberAssignment(Set<TopicPartition> topicPartitions) {
+    public MemberAssignment(Set<TopicPartition> topicPartitions) {
         this.topicPartitions = topicPartitions == null ? Collections.<TopicPartition>emptySet()
:
             Collections.unmodifiableSet(new HashSet<>(topicPartitions));
     }
diff --git a/clients/src/main/java/org/apache/kafka/clients/admin/MemberDescription.java b/clients/src/main/java/org/apache/kafka/clients/admin/MemberDescription.java
index 895abad..a8865be 100644
--- a/clients/src/main/java/org/apache/kafka/clients/admin/MemberDescription.java
+++ b/clients/src/main/java/org/apache/kafka/clients/admin/MemberDescription.java
@@ -31,7 +31,7 @@ public class MemberDescription {
     private final String host;
     private final MemberAssignment assignment;
 
-    MemberDescription(String memberId, String clientId, String host, MemberAssignment assignment)
{
+    public MemberDescription(String memberId, String clientId, String host, MemberAssignment
assignment) {
         this.memberId = memberId == null ? "" : memberId;
         this.clientId = clientId == null ? "" : clientId;
         this.host = host == null ? "" : host;

-- 
To stop receiving notification emails like this one, please contact
jgus@apache.org.

Mime
View raw message