aboutsummaryrefslogtreecommitdiffstats
path: root/sdnr/wt/websocketmanager/provider
diff options
context:
space:
mode:
Diffstat (limited to 'sdnr/wt/websocketmanager/provider')
-rw-r--r--sdnr/wt/websocketmanager/provider/pom.xml4
-rw-r--r--sdnr/wt/websocketmanager/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/websocketmanager/WebSocketManagerSocket.java6
2 files changed, 9 insertions, 1 deletions
diff --git a/sdnr/wt/websocketmanager/provider/pom.xml b/sdnr/wt/websocketmanager/provider/pom.xml
index b6a7110d8..b198b61ef 100644
--- a/sdnr/wt/websocketmanager/provider/pom.xml
+++ b/sdnr/wt/websocketmanager/provider/pom.xml
@@ -110,6 +110,10 @@
<scope>provided</scope>
</dependency>
<dependency>
+ <groupId>com.fasterxml.jackson.datatype</groupId>
+ <artifactId>jackson-datatype-jsr310</artifactId>
+ </dependency>
+ <dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-core</artifactId>
<scope>test</scope>
diff --git a/sdnr/wt/websocketmanager/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/websocketmanager/WebSocketManagerSocket.java b/sdnr/wt/websocketmanager/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/websocketmanager/WebSocketManagerSocket.java
index 95715be39..0b64d476a 100644
--- a/sdnr/wt/websocketmanager/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/websocketmanager/WebSocketManagerSocket.java
+++ b/sdnr/wt/websocketmanager/provider/src/main/java/org/onap/ccsdk/features/sdnr/wt/websocketmanager/WebSocketManagerSocket.java
@@ -32,6 +32,9 @@ import java.util.concurrent.TimeUnit;
import java.util.concurrent.TimeoutException;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
+
+import com.fasterxml.jackson.databind.ObjectMapper;
+import com.fasterxml.jackson.databind.SerializationFeature;
import org.eclipse.jetty.websocket.api.Session;
import org.eclipse.jetty.websocket.api.WebSocketAdapter;
import org.onap.ccsdk.features.sdnr.wt.websocketmanager.model.data.DOMNotificationOutput;
@@ -120,7 +123,7 @@ public class WebSocketManagerSocket extends WebSocketAdapter {
*/
private static final HashMap<String, WebSocketManagerSocket> clientList = new HashMap<>();
- private static final YangToolsMapper mapper = new YangToolsMapper();
+ private static final ObjectMapper mapper = new YangToolsMapper().disable(SerializationFeature.FAIL_ON_EMPTY_BEANS);
private final String myUniqueSessionId;
private Session session = null;
@@ -133,6 +136,7 @@ public class WebSocketManagerSocket extends WebSocketAdapter {
this.myUniqueSessionId = _genSessionId();
this.sendingSyncThread = new Thread(this.sendingRunner);
this.messageQueue = new ArrayBlockingQueue<>(QUEUE_SIZE);
+
}
@Override