support of HTTP proxy to connect to DMAAP

support of HTTP proxy to connect to DMAAP

Issue-ID: SDNC-1454
Signed-off-by: Ravi Pendurty <ravi.pendurty@highstreet-technologies.com>
Change-Id: I850cbb2d26e65acfd5e75191998c930aefda366a
Signed-off-by: Ravi Pendurty <ravi.pendurty@highstreet-technologies.com>
diff --git a/sdnr/wt/mountpoint-registrar/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/mountpointregistrar/impl/DMaaPVESMsgConsumerMain.java b/sdnr/wt/mountpoint-registrar/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/mountpointregistrar/impl/DMaaPVESMsgConsumerMain.java
index 3503aed..f8ee7a4 100644
--- a/sdnr/wt/mountpoint-registrar/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/mountpointregistrar/impl/DMaaPVESMsgConsumerMain.java
+++ b/sdnr/wt/mountpoint-registrar/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/mountpointregistrar/impl/DMaaPVESMsgConsumerMain.java
@@ -28,147 +28,158 @@
 
 public class DMaaPVESMsgConsumerMain implements Runnable {
 
-    private static final Logger LOG = LoggerFactory.getLogger(DMaaPVESMsgConsumerMain.class);
-    private static final String _PNFREG_CLASS =
-            "org.onap.ccsdk.features.sdnr.wt.mountpointregistrar.impl.DMaaPPNFRegVESMsgConsumer";
-    private static final String _FAULT_CLASS =
-            "org.onap.ccsdk.features.sdnr.wt.mountpointregistrar.impl.DMaaPFaultVESMsgConsumer";
-    private static final String _PNFREG_DOMAIN = "pnfRegistration";
-    private static final String _FAULT_DOMAIN = "fault";
+	private static final Logger LOG = LoggerFactory.getLogger(DMaaPVESMsgConsumerMain.class);
+	private static final String _PNFREG_CLASS = "org.onap.ccsdk.features.sdnr.wt.mountpointregistrar.impl.DMaaPPNFRegVESMsgConsumer";
+	private static final String _FAULT_CLASS = "org.onap.ccsdk.features.sdnr.wt.mountpointregistrar.impl.DMaaPFaultVESMsgConsumer";
+	private static final String _PNFREG_DOMAIN = "pnfRegistration";
+	private static final String _FAULT_DOMAIN = "fault";
 
-    boolean threadsRunning = false;
-    List<DMaaPVESMsgConsumer> consumers = new LinkedList<>();
-    private PNFRegistrationConfig pnfRegistrationConfig;
-    private FaultConfig faultConfig;
-    private GeneralConfig generalConfig;
+	boolean threadsRunning = false;
+	List<DMaaPVESMsgConsumer> consumers = new LinkedList<>();
+	private PNFRegistrationConfig pnfRegistrationConfig;
+	private FaultConfig faultConfig;
+	private GeneralConfig generalConfig;
 
-    public DMaaPVESMsgConsumerMain(Map<String, Configuration> configMap, GeneralConfig generalConfig) {
-        this.generalConfig = generalConfig;
-        configMap.forEach((k, v) -> initialize(k, v));
-    }
+	public DMaaPVESMsgConsumerMain(Map<String, Configuration> configMap, GeneralConfig generalConfig) {
+		this.generalConfig = generalConfig;
+		configMap.forEach((k, v) -> initialize(k, v));
+	}
 
-    public void initialize(String domain, Configuration domainConfig) {
-        LOG.debug("In initialize method : Domain = {} and domainConfig = {}", domain, domainConfig);
-        String consumerClass = null;
-        Properties consumerProperties = new Properties();
-        if (domain.equalsIgnoreCase(_PNFREG_DOMAIN)) {
-            this.pnfRegistrationConfig = (PNFRegistrationConfig) domainConfig;
+	public void initialize(String domain, Configuration domainConfig) {
+		LOG.debug("In initialize method : Domain = {} and domainConfig = {}", domain, domainConfig);
+		String consumerClass = null;
+		Properties consumerProperties = new Properties();
+		if (domain.equalsIgnoreCase(_PNFREG_DOMAIN)) {
+			this.pnfRegistrationConfig = (PNFRegistrationConfig) domainConfig;
 
-            consumerClass = _PNFREG_CLASS;
-            LOG.debug("Consumer class = {}",consumerClass);
+			consumerClass = _PNFREG_CLASS;
+			LOG.debug("Consumer class = {}", consumerClass);
 
-            consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_TRANSPORTTYPE,
-                    pnfRegistrationConfig.getTransportType());
-            consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_HOST_PORT,
-                    pnfRegistrationConfig.getHostPort());
-            consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_CONTENTTYPE,
-                    pnfRegistrationConfig.getContenttype());
-            consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_GROUP,
-                    pnfRegistrationConfig.getConsumerGroup());
-            consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_ID,
-                    pnfRegistrationConfig.getConsumerId());
-            consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_TOPIC, pnfRegistrationConfig.getTopic());
-            consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_TIMEOUT,
-                    pnfRegistrationConfig.getTimeout());
-            consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_LIMIT, pnfRegistrationConfig.getLimit());
-            consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_FETCHPAUSE,
-                    pnfRegistrationConfig.getFetchPause());
-            consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_PROTOCOL,
-                    pnfRegistrationConfig.getProtocol());
-            consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_USERNAME,
-                    pnfRegistrationConfig.getUsername());
-            consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_PASSWORD,
-                    pnfRegistrationConfig.getPassword());
-            consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_CLIENT_READTIMEOUT,
-                    pnfRegistrationConfig.getClientReadTimeout());
-            consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_CLIENT_CONNECTTIMEOUT,
-                    pnfRegistrationConfig.getClientConnectTimeout());
-            threadsRunning = createConsumer(_PNFREG_DOMAIN, consumerProperties);
-        } else if (domain.equalsIgnoreCase(_FAULT_DOMAIN)) {
-            this.faultConfig = (FaultConfig) domainConfig;
-            consumerClass = _FAULT_CLASS;
-            LOG.debug("Consumer class = {}", consumerClass);
-            consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_TRANSPORTTYPE, faultConfig.getTransportType());
-            consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_HOST_PORT, faultConfig.getHostPort());
-            consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_CONTENTTYPE, faultConfig.getContenttype());
-            consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_GROUP, faultConfig.getConsumerGroup());
-            consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_ID, faultConfig.getConsumerId());
-            consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_TOPIC, faultConfig.getTopic());
-            consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_TIMEOUT, faultConfig.getTimeout());
-            consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_LIMIT, faultConfig.getLimit());
-            consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_FETCHPAUSE, faultConfig.getFetchPause());
-            consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_PROTOCOL, faultConfig.getProtocol());
-            consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_USERNAME, faultConfig.getUsername());
-            consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_PASSWORD, faultConfig.getPassword());
-            consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_CLIENT_READTIMEOUT,
-                    faultConfig.getClientReadTimeout());
-            consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_CLIENT_CONNECTTIMEOUT,
-                    faultConfig.getClientConnectTimeout());
-            threadsRunning = createConsumer(_FAULT_DOMAIN, consumerProperties);
-        }
-    }
+			consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_TRANSPORTTYPE,
+					pnfRegistrationConfig.getTransportType());
+			consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_HOST_PORT,
+					pnfRegistrationConfig.getHostPort());
+			consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_CONTENTTYPE,
+					pnfRegistrationConfig.getContenttype());
+			consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_GROUP,
+					pnfRegistrationConfig.getConsumerGroup());
+			consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_ID,
+					pnfRegistrationConfig.getConsumerId());
+			consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_TOPIC, pnfRegistrationConfig.getTopic());
+			consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_TIMEOUT,
+					pnfRegistrationConfig.getTimeout());
+			consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_LIMIT, pnfRegistrationConfig.getLimit());
+			consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_FETCHPAUSE,
+					pnfRegistrationConfig.getFetchPause());
+			consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_PROTOCOL,
+					pnfRegistrationConfig.getProtocol());
+			consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_USERNAME,
+					pnfRegistrationConfig.getUsername());
+			consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_PASSWORD,
+					pnfRegistrationConfig.getPassword());
+			consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_CLIENT_READTIMEOUT,
+					pnfRegistrationConfig.getClientReadTimeout());
+			consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_CLIENT_CONNECTTIMEOUT,
+					pnfRegistrationConfig.getClientConnectTimeout());
+			consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_URI,
+					pnfRegistrationConfig.getHTTPProxyURI());
+			consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_AUTH_USER,
+					pnfRegistrationConfig.getHTTPProxyUsername());
+			consumerProperties.put(PNFRegistrationConfig.PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_AUTH_PASSWORD,
+					pnfRegistrationConfig.getHTTPProxyPassword());
 
-    private boolean updateThreadState(List<DMaaPVESMsgConsumer> consumers) {
-        boolean threadsRunning = false;
-        for (DMaaPVESMsgConsumer consumer : consumers) {
-            if (consumer.isRunning()) {
-                threadsRunning = true;
-            }
-        }
-        return threadsRunning;
-    }
+			threadsRunning = createConsumer(_PNFREG_DOMAIN, consumerProperties);
+		} else if (domain.equalsIgnoreCase(_FAULT_DOMAIN)) {
+			this.faultConfig = (FaultConfig) domainConfig;
+			consumerClass = _FAULT_CLASS;
+			LOG.debug("Consumer class = {}", consumerClass);
+			consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_TRANSPORTTYPE, faultConfig.getTransportType());
+			consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_HOST_PORT, faultConfig.getHostPort());
+			consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_CONTENTTYPE, faultConfig.getContenttype());
+			consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_GROUP, faultConfig.getConsumerGroup());
+			consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_ID, faultConfig.getConsumerId());
+			consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_TOPIC, faultConfig.getTopic());
+			consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_TIMEOUT, faultConfig.getTimeout());
+			consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_LIMIT, faultConfig.getLimit());
+			consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_FETCHPAUSE, faultConfig.getFetchPause());
+			consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_PROTOCOL, faultConfig.getProtocol());
+			consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_USERNAME, faultConfig.getUsername());
+			consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_PASSWORD, faultConfig.getPassword());
+			consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_CLIENT_READTIMEOUT,
+					faultConfig.getClientReadTimeout());
+			consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_CLIENT_CONNECTTIMEOUT,
+					faultConfig.getClientConnectTimeout());
+			consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_URI,
+					faultConfig.getHTTPProxyURI());
+			consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_AUTH_USER,
+					faultConfig.getHTTPProxyUsername());
+			consumerProperties.put(FaultConfig.PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_AUTH_PASSWORD,
+					faultConfig.getHTTPProxyPassword());
+			threadsRunning = createConsumer(_FAULT_DOMAIN, consumerProperties);
+		}
+	}
 
-    public boolean createConsumer(String consumerType, Properties properties) {
-        DMaaPVESMsgConsumerImpl consumer = null;
+	private boolean updateThreadState(List<DMaaPVESMsgConsumer> consumers) {
+		boolean threadsRunning = false;
+		for (DMaaPVESMsgConsumer consumer : consumers) {
+			if (consumer.isRunning()) {
+				threadsRunning = true;
+			}
+		}
+		return threadsRunning;
+	}
 
-        if (consumerType.equalsIgnoreCase(_PNFREG_DOMAIN))
-            consumer = new DMaaPPNFRegVESMsgConsumer(generalConfig);
-        else if (consumerType.equalsIgnoreCase(_FAULT_DOMAIN))
-            consumer = new DMaaPFaultVESMsgConsumer(generalConfig);
+	public boolean createConsumer(String consumerType, Properties properties) {
+		DMaaPVESMsgConsumerImpl consumer = null;
 
-        handleConsumer(consumer, properties, consumers);
-        return !consumers.isEmpty();
-    }
+		if (consumerType.equalsIgnoreCase(_PNFREG_DOMAIN))
+			consumer = new DMaaPPNFRegVESMsgConsumer(generalConfig);
+		else if (consumerType.equalsIgnoreCase(_FAULT_DOMAIN))
+			consumer = new DMaaPFaultVESMsgConsumer(generalConfig);
 
-    private boolean handleConsumer(DMaaPVESMsgConsumer consumer, Properties properties,
-            List<DMaaPVESMsgConsumer> consumers) {
-        if (consumer != null) {
-            consumer.init(properties);
+		handleConsumer(consumer, properties, consumers);
+		return !consumers.isEmpty();
+	}
 
-            if (consumer.isReady()) {
-                Thread consumerThread = new Thread(consumer);
-                consumerThread.start();
-                consumers.add(consumer);
+	private boolean handleConsumer(DMaaPVESMsgConsumer consumer, Properties properties,
+			List<DMaaPVESMsgConsumer> consumers) {
+		if (consumer != null) {
+			consumer.init(properties);
 
-                LOG.info("Started consumer thread ({} : {})", consumer.getClass().getSimpleName(), properties);
-                return true;
-            } else {
-                LOG.debug("Consumer {} is not ready", consumer.getClass().getSimpleName());
-            }
-        }
-        return false;
-    }
+			if (consumer.isReady()) {
+				Thread consumerThread = new Thread(consumer);
+				consumerThread.start();
+				consumers.add(consumer);
 
-    @Override
-    public void run() {
-        while (threadsRunning) {
-            threadsRunning = updateThreadState(consumers);
-            if (!threadsRunning) {
-                break;
-            }
+				LOG.info("Started consumer thread ({} : {})", consumer.getClass().getSimpleName(), properties);
+				return true;
+			} else {
+				LOG.debug("Consumer {} is not ready", consumer.getClass().getSimpleName());
+			}
+		}
+		return false;
+	}
 
-            try {
-                Thread.sleep(10000);
-            } catch (InterruptedException e) {
-                LOG.error(e.getLocalizedMessage(), e);
-            }
-        }
+	@Override
+	public void run() {
+		while (threadsRunning) {
+			threadsRunning = updateThreadState(consumers);
+			if (!threadsRunning) {
+				break;
+			}
 
-        LOG.info("No listener threads running - exiting");
-    }
+			try {
+				Thread.sleep(10000);
+			} catch (InterruptedException e) {
+				LOG.error(e.getLocalizedMessage(), e);
+			}
+		}
 
-    public List<DMaaPVESMsgConsumer> getConsumers() {
-        return consumers;
-    }
+		LOG.info("No listener threads running - exiting");
+	}
+
+	public List<DMaaPVESMsgConsumer> getConsumers() {
+		return consumers;
+	}
 
 }
diff --git a/sdnr/wt/mountpoint-registrar/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/mountpointregistrar/impl/FaultConfig.java b/sdnr/wt/mountpoint-registrar/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/mountpointregistrar/impl/FaultConfig.java
index dfdb1c0..ddf5c54 100644
--- a/sdnr/wt/mountpoint-registrar/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/mountpointregistrar/impl/FaultConfig.java
+++ b/sdnr/wt/mountpoint-registrar/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/mountpointregistrar/impl/FaultConfig.java
@@ -65,6 +65,15 @@
     public static final String PROPERTY_KEY_CONSUMER_CLIENT_CONNECTTIMEOUT = "jersey.config.client.connectTimeout";
     private static final String DEFAULT_VALUE_CONSUMER_CLIENT_CONNECTTIMEOUT = "25000";
 
+    public static final String PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_AUTH_USER = "jersey.config.client.proxy.username";
+    private static final String DEFAULT_VALUE_CONSUMER_CLIENT_HTTPPROXY_AUTH_USER = "${HTTP_PROXY_USERNAME}";
+    
+    public static final String PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_AUTH_PASSWORD = "jersey.config.client.proxy.password";
+    private static final String DEFAULT_VALUE_CONSUMER_CLIENT_HTTPPROXY_AUTH_PASSWORD = "${HTTP_PROXY_PASSWORD}";
+    
+    public static final String PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_URI = "jersey.config.client.proxy.uri";
+    private static final String DEFAULT_VALUE_CONSUMER_CLIENT_HTTPPROXY_URI = "${HTTP_PROXY_URI}";
+    
     private final ConfigurationFileRepresentation configuration;
 
     public FaultConfig(ConfigurationFileRepresentation configuration) {
@@ -108,6 +117,12 @@
                 DEFAULT_VALUE_CONSUMER_CLIENT_READTIMEOUT);
         configuration.setPropertyIfNotAvailable(SECTION_MARKER, PROPERTY_KEY_CONSUMER_CLIENT_CONNECTTIMEOUT,
                 DEFAULT_VALUE_CONSUMER_CLIENT_CONNECTTIMEOUT);
+        configuration.setPropertyIfNotAvailable(SECTION_MARKER, PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_AUTH_USER,
+        		DEFAULT_VALUE_CONSUMER_CLIENT_HTTPPROXY_AUTH_USER);
+        configuration.setPropertyIfNotAvailable(SECTION_MARKER, PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_AUTH_PASSWORD,
+        		DEFAULT_VALUE_CONSUMER_CLIENT_HTTPPROXY_AUTH_PASSWORD);
+        configuration.setPropertyIfNotAvailable(SECTION_MARKER, PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_URI,
+        		DEFAULT_VALUE_CONSUMER_CLIENT_HTTPPROXY_URI);
 
     }
 
@@ -167,5 +182,16 @@
         return configuration.getProperty(SECTION_MARKER, PROPERTY_KEY_CONSUMER_CLIENT_CONNECTTIMEOUT);
     }
 
-
+    public String getHTTPProxyURI() {
+        return configuration.getProperty(SECTION_MARKER, PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_URI);
+    }
+    
+    public String getHTTPProxyUsername() {
+        return configuration.getProperty(SECTION_MARKER, PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_AUTH_USER);
+    }
+    
+    public String getHTTPProxyPassword() {
+        return configuration.getProperty(SECTION_MARKER, PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_AUTH_PASSWORD);
+    }
+    
 }
diff --git a/sdnr/wt/mountpoint-registrar/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/mountpointregistrar/impl/PNFRegistrationConfig.java b/sdnr/wt/mountpoint-registrar/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/mountpointregistrar/impl/PNFRegistrationConfig.java
index 636df41..2a934b7 100644
--- a/sdnr/wt/mountpoint-registrar/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/mountpointregistrar/impl/PNFRegistrationConfig.java
+++ b/sdnr/wt/mountpoint-registrar/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/mountpointregistrar/impl/PNFRegistrationConfig.java
@@ -62,10 +62,19 @@
 
     public static final String PROPERTY_KEY_CONSUMER_CLIENT_READTIMEOUT = "jersey.config.client.readTimeout";
     private static final String DEFAULT_VALUE_CONSUMER_CLIENT_READTIMEOUT = "25000";
-
+    
     public static final String PROPERTY_KEY_CONSUMER_CLIENT_CONNECTTIMEOUT = "jersey.config.client.connectTimeout";
     private static final String DEFAULT_VALUE_CONSUMER_CLIENT_CONNECTTIMEOUT = "25000";
-
+    
+    public static final String PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_AUTH_USER = "jersey.config.client.proxy.username";
+    private static final String DEFAULT_VALUE_CONSUMER_CLIENT_HTTPPROXY_AUTH_USER = "${HTTP_PROXY_USERNAME}";
+    
+    public static final String PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_AUTH_PASSWORD = "jersey.config.client.proxy.password";
+    private static final String DEFAULT_VALUE_CONSUMER_CLIENT_HTTPPROXY_AUTH_PASSWORD = "${HTTP_PROXY_PASSWORD}";
+    
+    public static final String PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_URI = "jersey.config.client.proxy.uri";
+    private static final String DEFAULT_VALUE_CONSUMER_CLIENT_HTTPPROXY_URI = "${HTTP_PROXY_URI}";
+    
     private final ConfigurationFileRepresentation configuration;
 
     public PNFRegistrationConfig(ConfigurationFileRepresentation configuration) {
@@ -109,6 +118,12 @@
                 DEFAULT_VALUE_CONSUMER_CLIENT_READTIMEOUT);
         configuration.setPropertyIfNotAvailable(SECTION_MARKER, PROPERTY_KEY_CONSUMER_CLIENT_CONNECTTIMEOUT,
                 DEFAULT_VALUE_CONSUMER_CLIENT_CONNECTTIMEOUT);
+        configuration.setPropertyIfNotAvailable(SECTION_MARKER, PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_AUTH_USER,
+        		DEFAULT_VALUE_CONSUMER_CLIENT_HTTPPROXY_AUTH_USER);
+        configuration.setPropertyIfNotAvailable(SECTION_MARKER, PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_AUTH_PASSWORD,
+        		DEFAULT_VALUE_CONSUMER_CLIENT_HTTPPROXY_AUTH_PASSWORD);
+        configuration.setPropertyIfNotAvailable(SECTION_MARKER, PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_URI,
+        		DEFAULT_VALUE_CONSUMER_CLIENT_HTTPPROXY_URI);
     }
 
     public String getHostPort() {
@@ -166,4 +181,17 @@
     public String getClientConnectTimeout() {
         return configuration.getProperty(SECTION_MARKER, PROPERTY_KEY_CONSUMER_CLIENT_CONNECTTIMEOUT);
     }
+    
+    public String getHTTPProxyURI() {
+        return configuration.getProperty(SECTION_MARKER, PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_URI);
+    }
+    
+    public String getHTTPProxyUsername() {
+        return configuration.getProperty(SECTION_MARKER, PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_AUTH_USER);
+    }
+    
+    public String getHTTPProxyPassword() {
+        return configuration.getProperty(SECTION_MARKER, PROPERTY_KEY_CONSUMER_CLIENT_HTTPPROXY_AUTH_PASSWORD);
+    }
+    
 }
diff --git a/sdnr/wt/mountpoint-registrar/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/mountpointregistrar/test/PNFRegistrationConfigTest.java b/sdnr/wt/mountpoint-registrar/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/mountpointregistrar/test/PNFRegistrationConfigTest.java
index 87a70d7..d3f4a13 100644
--- a/sdnr/wt/mountpoint-registrar/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/mountpointregistrar/test/PNFRegistrationConfigTest.java
+++ b/sdnr/wt/mountpoint-registrar/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/mountpointregistrar/test/PNFRegistrationConfigTest.java
@@ -46,6 +46,9 @@
             + "fetchPause=5000\n"
             + "jersey.config.client.readTimeout=25000\n"
             + "jersey.config.client.connectTimeout=25000\n"
+            + "jersey.config.client.proxy.uri=http://http-proxy\n"
+            + "jersey.config.client.proxy.username=proxy-user\n"
+            + "jersey.config.client.proxy.password=proxy-password\n"
             + "";
     // @formatter:on
     private ConfigurationFileRepresentation cfg;
@@ -72,6 +75,9 @@
             assertEquals("password", pnfCfg.getPassword());
             assertEquals("25000", pnfCfg.getClientReadTimeout());
             assertEquals("25000", pnfCfg.getClientConnectTimeout());
+            assertEquals("http://http-proxy", pnfCfg.getHTTPProxyURI());
+            assertEquals("proxy-user", pnfCfg.getHTTPProxyUsername());
+            assertEquals("proxy-password", pnfCfg.getHTTPProxyPassword());
 
         } catch (IOException e) {
             e.printStackTrace();
diff --git a/sdnr/wt/mountpoint-registrar/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/mountpointregistrar/test/TestFaultConfig.java b/sdnr/wt/mountpoint-registrar/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/mountpointregistrar/test/TestFaultConfig.java
index f44bebc..422d249 100644
--- a/sdnr/wt/mountpoint-registrar/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/mountpointregistrar/test/TestFaultConfig.java
+++ b/sdnr/wt/mountpoint-registrar/provider/src/test/java/org/onap/ccsdk/features/sdnr/wt/mountpointregistrar/test/TestFaultConfig.java
@@ -46,6 +46,9 @@
             + "fetchPause=5000\n"
             + "jersey.config.client.readTimeout=25000\n"
             + "jersey.config.client.connectTimeout=25000\n"
+            + "jersey.config.client.proxy.uri=http://http-proxy\n"
+            + "jersey.config.client.proxy.username=proxy-user\n"
+            + "jersey.config.client.proxy.password=proxy-password\n"
             + "\n"
             + "";
     // @formatter:on
@@ -73,6 +76,9 @@
             assertEquals("password", faultCfg.getPassword());
             assertEquals("25000", faultCfg.getClientReadTimeout());
             assertEquals("25000", faultCfg.getClientConnectTimeout());
+            assertEquals("http://http-proxy", faultCfg.getHTTPProxyURI());
+            assertEquals("proxy-user", faultCfg.getHTTPProxyUsername());
+            assertEquals("proxy-password", faultCfg.getHTTPProxyPassword());
 
         } catch (IOException e) {
             e.printStackTrace();