aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLee, Tian (tl5884) <tianl@amdocs.com>2017-09-13 14:35:18 +0100
committerLee, Tian (tl5884) <tianl@amdocs.com>2017-09-13 14:45:54 +0100
commit6df64160eb361459659d46343342df5d3703077f (patch)
tree8a82e2b5c2f081cded01ff77693a719e57340221
parent7d1a156fac0b2336d040615ad98044f2030866db (diff)
Fix NullPointerException caused by null log object
Only two of the three constructors in MRBaseClient class actually initialises the fLog object. When the one that doesn't is invoked, any invokations of the logger in the class and its sub-classes will result in a NullPointerException. Change-Id: I112e932f22679b190dc03d00dc8d7341f8a24aa4 Issue-Id: DMAAP-132 Signed-off-by: Lee, Tian (tl5884) <tianl@amdocs.com>
-rw-r--r--src/main/java/com/att/nsa/mr/client/impl/MRBaseClient.java2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/main/java/com/att/nsa/mr/client/impl/MRBaseClient.java b/src/main/java/com/att/nsa/mr/client/impl/MRBaseClient.java
index a9fd9bd..012e95e 100644
--- a/src/main/java/com/att/nsa/mr/client/impl/MRBaseClient.java
+++ b/src/main/java/com/att/nsa/mr/client/impl/MRBaseClient.java
@@ -59,6 +59,8 @@ public class MRBaseClient extends HttpClient implements MRClient
protected MRBaseClient ( Collection<String> hosts ) throws MalformedURLException
{
super ( ConnectionType.HTTP, hosts, MRConstants.kStdMRServicePort );
+
+ fLog = LoggerFactory.getLogger ( this.getClass().getName () );
}
protected MRBaseClient ( Collection<String> hosts, int stdSvcPort ) throws MalformedURLException {