Code changes for dmaap-client upgrade

Issue-ID: POLICY-1996
Change-Id: Id8a3acf9406c6acada4c3ffee679f2baf819cded
Signed-off-by: Jim Hahn <jrh3@att.com>
diff --git a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/BusConsumer.java b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/BusConsumer.java
index 0f31bf7..233434f 100644
--- a/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/BusConsumer.java
+++ b/policy-endpoints/src/main/java/org/onap/policy/common/endpoints/event/comm/bus/internal/BusConsumer.java
@@ -35,6 +35,7 @@
 import org.apache.commons.lang3.StringUtils;
 import org.onap.dmaap.mr.client.MRClientFactory;
 import org.onap.dmaap.mr.client.impl.MRConsumerImpl;
+import org.onap.dmaap.mr.client.impl.MRConsumerImpl.MRConsumerImplBuilder;
 import org.onap.dmaap.mr.client.response.MRConsumerResponse;
 import org.onap.dmaap.mr.test.clients.ProtocolTypeConstants;
 import org.onap.policy.common.endpoints.properties.PolicyEndPointProperties;
@@ -302,10 +303,16 @@
                 throw new IllegalArgumentException("No topic for DMaaP");
             }
 
-            this.consumer = new MRConsumerImpl(busTopicParams.getServers(), busTopicParams.getTopic(),
-                    busTopicParams.getConsumerGroup(), busTopicParams.getConsumerInstance(),
-                    busTopicParams.getFetchTimeout(), busTopicParams.getFetchLimit(), null,
-                    busTopicParams.getApiKey(), busTopicParams.getApiSecret());
+            this.consumer = new MRConsumerImplBuilder()
+                            .setHostPart(busTopicParams.getServers())
+                            .setTopic(busTopicParams.getTopic())
+                            .setConsumerGroup(busTopicParams.getConsumerGroup())
+                            .setConsumerId(busTopicParams.getConsumerInstance())
+                            .setTimeoutMs(busTopicParams.getFetchTimeout())
+                            .setLimit(busTopicParams.getFetchLimit())
+                            .setApiKey(busTopicParams.getApiKey())
+                            .setApiSecret(busTopicParams.getApiSecret())
+                            .createMRConsumerImpl();
 
             this.consumer.setUsername(busTopicParams.getUserName());
             this.consumer.setPassword(busTopicParams.getPassword());