summaryrefslogtreecommitdiffstats
path: root/ueb-listener
diff options
context:
space:
mode:
Diffstat (limited to 'ueb-listener')
-rw-r--r--ueb-listener/src/main/java/org/onap/ccsdk/sli/northbound/uebclient/SdncArtifactMap.java13
1 files changed, 1 insertions, 12 deletions
diff --git a/ueb-listener/src/main/java/org/onap/ccsdk/sli/northbound/uebclient/SdncArtifactMap.java b/ueb-listener/src/main/java/org/onap/ccsdk/sli/northbound/uebclient/SdncArtifactMap.java
index 4c08949c0..dd9437ce9 100644
--- a/ueb-listener/src/main/java/org/onap/ccsdk/sli/northbound/uebclient/SdncArtifactMap.java
+++ b/ueb-listener/src/main/java/org/onap/ccsdk/sli/northbound/uebclient/SdncArtifactMap.java
@@ -87,10 +87,7 @@ public class SdncArtifactMap {
if (mapFile.exists() && mapFile.canRead()) {
- BufferedReader rdr = null;
- try {
-
- rdr = new BufferedReader(new FileReader(mapFile));
+ try (BufferedReader rdr = new BufferedReader(new FileReader(mapFile))) {
for (String ln ; (ln = rdr.readLine()) != null ; ) {
String[] lnFields = ln.split(",");
@@ -107,14 +104,6 @@ public class SdncArtifactMap {
} catch (Exception e) {
LOG.error("Caught exception reading artifact map", e);
return;
- } finally {
- if (rdr != null) {
- try {
- rdr.close();
- } catch (IOException e) {
-
- }
- }
}
}
}