diff options
Diffstat (limited to 'vid-app-common/src/main')
-rw-r--r-- | vid-app-common/src/main/java/org/onap/vid/scheduler/SchedulerRestInterface.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/vid-app-common/src/main/java/org/onap/vid/scheduler/SchedulerRestInterface.java b/vid-app-common/src/main/java/org/onap/vid/scheduler/SchedulerRestInterface.java index 7878c2fb8..001a8ae6d 100644 --- a/vid-app-common/src/main/java/org/onap/vid/scheduler/SchedulerRestInterface.java +++ b/vid-app-common/src/main/java/org/onap/vid/scheduler/SchedulerRestInterface.java @@ -98,12 +98,13 @@ public class SchedulerRestInterface implements SchedulerRestInterfaceIfc { status = response.getStatus(); restObject.setStatusCode(status); rawData = response.getBody(); + restObject.setRaw(rawData); if (status == 200) { if (t instanceof String) { restObject.set((T)rawData); } else { - restObject.set(JACKSON_OBJECT_MAPPER.readValue(rawData, new TypeReference<T>() {})); + restObject.set(JACKSON_OBJECT_MAPPER.readValue(rawData, (Class<T>)t.getClass())); } logger.debug(EELFLoggerDelegate.debugLogger, "<== " + methodName + SUCCESSFUL_API_MESSAGE); logger.info(EELFLoggerDelegate.errorLogger, "<== " + methodName + SUCCESSFUL_API_MESSAGE); |