diff options
author | 2021-03-19 18:18:10 +0000 | |
---|---|---|
committer | 2021-03-22 20:32:54 +0000 | |
commit | 04868c54c8139fcf6163541540879c6243ec06fb (patch) | |
tree | dec97b2618804e1ddca55c269ad727f5eb8fdc65 /models-pdp/src/test/resources | |
parent | cfb5faf035e743e88829ef90a99d6f0c501d37f8 (diff) |
Fix write failure on PDP statistics
Due to the precision of time stamps being saved to the nearest second,
a millisecond precision timestamp was being compared to a second
precision timestamp, causing the write to fail. This change fixes that.
A unit test is also added to test for this on the provider.
In addition, a USE-MARIADB flag is being introduced, which allows unit
tests to be run against a locally installed MariaDB instance so that the
unit tests can be verified against MariaDB locally rather than H2, the
default in Gerrit.
Issue-ID: POLICY-3146
Change-Id: I878f160956e89506743dc074679ee81ac1c48216
Signed-off-by: liamfallon <liam.fallon@est.tech>
(cherry picked from commit d6db5582b6705c11abbf8b507aa423aa00bcd7ae)
Diffstat (limited to 'models-pdp/src/test/resources')
-rw-r--r-- | models-pdp/src/test/resources/META-INF/persistence.xml | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/models-pdp/src/test/resources/META-INF/persistence.xml b/models-pdp/src/test/resources/META-INF/persistence.xml index 878998422..65380642a 100644 --- a/models-pdp/src/test/resources/META-INF/persistence.xml +++ b/models-pdp/src/test/resources/META-INF/persistence.xml @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8"?> <!-- ============LICENSE_START======================================================= - Copyright (C) 2019 Nordix Foundation. + Copyright (C) 2019, 2021 Nordix Foundation. Modifications Copyright (C) 2021 AT&T Intellectual Property. All rights reserved. ================================================================================ Licensed under the Apache License, Version 2.0 (the "License"); @@ -38,6 +38,7 @@ <class>org.onap.policy.models.tosca.simple.concepts.JpaToscaProperty</class> <properties> + <property name="eclipselink.target-database" value="MySQL" /> <property name="eclipselink.ddl-generation" value="drop-and-create-tables" /> <property name="eclipselink.ddl-generation.output-mode" value="database" /> <property name="eclipselink.logging.level" value="INFO" /> |