From 0150a629d2f15f3fcaf6a8ed584f64512201b25d Mon Sep 17 00:00:00 2001 From: liamfallon Date: Wed, 17 Feb 2021 17:19:41 +0000 Subject: Convert Date to Instant in stats Issue-ID: POLICY-3069 Change-Id: Ib30782485652ec693d2dbea79514183c7cfbb0c4 Signed-off-by: liamfallon --- .../onap/policy/apex/services/onappf/handler/PdpMessageHandler.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'services/services-onappf') diff --git a/services/services-onappf/src/main/java/org/onap/policy/apex/services/onappf/handler/PdpMessageHandler.java b/services/services-onappf/src/main/java/org/onap/policy/apex/services/onappf/handler/PdpMessageHandler.java index c16f11c9c..4044a4903 100644 --- a/services/services-onappf/src/main/java/org/onap/policy/apex/services/onappf/handler/PdpMessageHandler.java +++ b/services/services-onappf/src/main/java/org/onap/policy/apex/services/onappf/handler/PdpMessageHandler.java @@ -20,8 +20,8 @@ package org.onap.policy.apex.services.onappf.handler; +import java.time.Instant; import java.util.ArrayList; -import java.util.Date; import java.util.List; import lombok.NonNull; import org.onap.policy.apex.model.enginemodel.concepts.AxEngineModel; @@ -130,7 +130,7 @@ public class PdpMessageHandler { private PdpStatistics getStatistics(final PdpStatus pdpStatusContext, final ApexEngineHandler apexEngineHandler) { PdpStatistics pdpStatistics = new PdpStatistics(); pdpStatistics.setPdpInstanceId(pdpStatusContext.getName()); - pdpStatistics.setTimeStamp(new Date()); + pdpStatistics.setTimeStamp(Instant.now()); pdpStatistics.setPdpGroupName(pdpStatusContext.getPdpGroup()); pdpStatistics.setPdpSubGroupName(pdpStatusContext.getPdpSubgroup()); if (apexEngineHandler != null) { -- cgit 1.2.3-korg