summaryrefslogtreecommitdiffstats
path: root/cps-ncmp-service/src/test/resources
diff options
context:
space:
mode:
authorhalil.cakal <halil.cakal@est.tech>2023-08-31 11:45:47 +0100
committerhalil.cakal <halil.cakal@est.tech>2023-09-04 11:54:40 +0100
commitc4485f7218fb9b2b4b7c113294ae2902979f5b5e (patch)
tree242038cf5386e75b9a6bd19aac20d1d56a011827 /cps-ncmp-service/src/test/resources
parent17d14293823ec280e646071988be211184d1f7ce (diff)
Dmi plugin watchdog cheking aliveness
- Add capability of GET request into DmiRestClient - Add watchdog job to check aliveness of dmi plugins - DmiPluginStatus enum as UP or DOWN - Add unit tests for the new function in dmi rest client - Add unit tests for dmi watchdog Issue-ID: CPS-1856 Change-Id: Ic38a96f0485a0bfe1b6af5bb2f57f6119d8fa563 Signed-off-by: halil.cakal <halil.cakal@est.tech>
Diffstat (limited to 'cps-ncmp-service/src/test/resources')
-rw-r--r--cps-ncmp-service/src/test/resources/application.yml3
-rw-r--r--cps-ncmp-service/src/test/resources/dmiPluginHealthCheckResponse.json27
2 files changed, 30 insertions, 0 deletions
diff --git a/cps-ncmp-service/src/test/resources/application.yml b/cps-ncmp-service/src/test/resources/application.yml
index 6e7577b1a..a4bb4e812 100644
--- a/cps-ncmp-service/src/test/resources/application.yml
+++ b/cps-ncmp-service/src/test/resources/application.yml
@@ -42,6 +42,9 @@ ncmp:
enabled: true
api:
base-path: dmi
+ timers:
+ trust-level:
+ dmi-availability-watchdog-ms: 30000
modules-sync-watchdog:
async-executor:
diff --git a/cps-ncmp-service/src/test/resources/dmiPluginHealthCheckResponse.json b/cps-ncmp-service/src/test/resources/dmiPluginHealthCheckResponse.json
new file mode 100644
index 000000000..753222005
--- /dev/null
+++ b/cps-ncmp-service/src/test/resources/dmiPluginHealthCheckResponse.json
@@ -0,0 +1,27 @@
+{
+ "status": "UP",
+ "components": {
+ "diskSpace": {
+ "status": "UP",
+ "details": {
+ "total": 269490393088,
+ "free": 228467286016,
+ "threshold": 10485760,
+ "exists": true
+ }
+ },
+ "livenessState": {
+ "status": "UP"
+ },
+ "ping": {
+ "status": "UP"
+ },
+ "readinessState": {
+ "status": "UP"
+ }
+ },
+ "groups": [
+ "liveness",
+ "readiness"
+ ]
+} \ No newline at end of file