summaryrefslogtreecommitdiffstats
path: root/cadi/core/src/main
diff options
context:
space:
mode:
authorInstrumental <jonathan.gathman@att.com>2019-06-26 07:05:51 -0500
committerInstrumental <jonathan.gathman@att.com>2019-06-26 07:05:59 -0500
commitba989d05eca8d2a98c51ed9d38c4c3345db23349 (patch)
treeef269eb99c9578559e9b7811c9540c4b04713fef /cadi/core/src/main
parente84b431dab21d38cd39119970b7d1fd82efa99f2 (diff)
Changes from Onsite Tests
Issue-ID: AAF-857 Change-Id: I3fbed32ff5b2bb8f05f4f932c8dc2f4012c8b429 Signed-off-by: Instrumental <jonathan.gathman@att.com>
Diffstat (limited to 'cadi/core/src/main')
-rw-r--r--cadi/core/src/main/java/org/onap/aaf/cadi/PropAccess.java8
-rw-r--r--cadi/core/src/main/java/org/onap/aaf/cadi/config/Config.java2
2 files changed, 7 insertions, 3 deletions
diff --git a/cadi/core/src/main/java/org/onap/aaf/cadi/PropAccess.java b/cadi/core/src/main/java/org/onap/aaf/cadi/PropAccess.java
index d6b8d56d..4737880e 100644
--- a/cadi/core/src/main/java/org/onap/aaf/cadi/PropAccess.java
+++ b/cadi/core/src/main/java/org/onap/aaf/cadi/PropAccess.java
@@ -42,7 +42,7 @@ import org.onap.aaf.cadi.util.Split;
public class PropAccess implements Access {
// Sonar says cannot be static... it's ok. not too many PropAccesses created.
- private final SimpleDateFormat iso8601 = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSSZ");
+ private final static SimpleDateFormat iso8601 = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSSZ");
public static final Level DEFAULT = Level.AUDIT;
@@ -101,7 +101,7 @@ public class PropAccess implements Access {
init(nprops);
}
- protected void init(Properties p) {
+ protected synchronized void init(Properties p) {
// Make sure these two are set before any changes in Logging
name = "cadi";
level=DEFAULT.maskOf();
@@ -262,6 +262,10 @@ public class PropAccess implements Access {
return buildMsg(name,iso8601,level,elements);
}
+ public static StringBuilder buildMsg(final String name, Level level, Object[] elements) {
+ return buildMsg(name,iso8601,level,elements);
+ }
+
public static StringBuilder buildMsg(final String name, final DateFormat sdf, Level level, Object[] elements) {
final StringBuilder sb;
int end = elements.length;
diff --git a/cadi/core/src/main/java/org/onap/aaf/cadi/config/Config.java b/cadi/core/src/main/java/org/onap/aaf/cadi/config/Config.java
index 38afa629..f74f194b 100644
--- a/cadi/core/src/main/java/org/onap/aaf/cadi/config/Config.java
+++ b/cadi/core/src/main/java/org/onap/aaf/cadi/config/Config.java
@@ -878,7 +878,7 @@ public class Config {
Method meth = lcls.getMethod("create",Access.class,String.class);
locator = (Locator<URI>)meth.invoke(null,access,url);
} catch (Exception e) {
- access.log(Level.TRACE, "(Not fatal) Cannot load by create(String)", e);
+ access.log(Level.NONE, "(Not fatal) Cannot load by create(String)", e);
}
if (locator==null) {
URI locatorURI = new URI(url);