aboutsummaryrefslogtreecommitdiffstats
path: root/models-base
diff options
context:
space:
mode:
Diffstat (limited to 'models-base')
-rw-r--r--models-base/src/main/java/org/onap/policy/models/base/PfReferenceTimestampKey.java4
-rw-r--r--models-base/src/main/java/org/onap/policy/models/base/PfTimestampKey.java2
2 files changed, 4 insertions, 2 deletions
diff --git a/models-base/src/main/java/org/onap/policy/models/base/PfReferenceTimestampKey.java b/models-base/src/main/java/org/onap/policy/models/base/PfReferenceTimestampKey.java
index 1a29c8b01..8be1126af 100644
--- a/models-base/src/main/java/org/onap/policy/models/base/PfReferenceTimestampKey.java
+++ b/models-base/src/main/java/org/onap/policy/models/base/PfReferenceTimestampKey.java
@@ -50,7 +50,7 @@ public class PfReferenceTimestampKey extends PfKey {
private static final String TIMESTAMP_TOKEN = "timeStamp";
- @Column(name = TIMESTAMP_TOKEN)
+ @Column(name = TIMESTAMP_TOKEN, precision = 3)
@Temporal(TemporalType.TIMESTAMP)
@NotNull
private Date timeStamp;
@@ -214,6 +214,7 @@ public class PfReferenceTimestampKey extends PfKey {
*
* @return the pfReferenceTimestamp key
*/
+ @Override
public PfReferenceTimestampKey getKey() {
return this;
}
@@ -222,6 +223,7 @@ public class PfReferenceTimestampKey extends PfKey {
* Get the key as a string.
* @return pfReferenceTimestamp key.
*/
+ @Override
public String getId() {
return getReferenceKey().getId() + ':' + getTimeStamp().getTime();
}
diff --git a/models-base/src/main/java/org/onap/policy/models/base/PfTimestampKey.java b/models-base/src/main/java/org/onap/policy/models/base/PfTimestampKey.java
index 6e2271846..1f5dc654a 100644
--- a/models-base/src/main/java/org/onap/policy/models/base/PfTimestampKey.java
+++ b/models-base/src/main/java/org/onap/policy/models/base/PfTimestampKey.java
@@ -51,7 +51,7 @@ public class PfTimestampKey extends PfKeyImpl {
@Pattern(regexp = VERSION_REGEXP)
private String version;
- @Column(name = TIMESTAMP_TOKEN)
+ @Column(name = TIMESTAMP_TOKEN, precision = 3)
@Temporal(TemporalType.TIMESTAMP)
@NonNull
private Date timeStamp;