From b93e84314397de40f6a3a6e553d7f45fc1bf71ee Mon Sep 17 00:00:00 2001 From: allegroai <> Date: Sat, 26 Oct 2019 01:01:09 +0300 Subject: [PATCH] Add schema files --- server/elastic/mappings/queue_metrics.json | 27 ++++++++++++++++++++++ server/elastic/mappings/worker_stats.json | 23 ++++++++++++++++++ 2 files changed, 50 insertions(+) create mode 100644 server/elastic/mappings/queue_metrics.json create mode 100644 server/elastic/mappings/worker_stats.json diff --git a/server/elastic/mappings/queue_metrics.json b/server/elastic/mappings/queue_metrics.json new file mode 100644 index 0000000..9f69251 --- /dev/null +++ b/server/elastic/mappings/queue_metrics.json @@ -0,0 +1,27 @@ +{ + "template": "queue_metrics_*", + "settings": { + "number_of_shards": 1 + }, + "mappings": { + "metrics": { + "_source": { + "enabled": true + }, + "properties": { + "timestamp": { + "type": "date" + }, + "queue": { + "type": "keyword" + }, + "average_waiting_time": { + "type": "float" + }, + "queue_length": { + "type": "integer" + } + } + } + } +} \ No newline at end of file diff --git a/server/elastic/mappings/worker_stats.json b/server/elastic/mappings/worker_stats.json new file mode 100644 index 0000000..3c2437c --- /dev/null +++ b/server/elastic/mappings/worker_stats.json @@ -0,0 +1,23 @@ +{ + "template": "worker_stats_*", + "settings": { + "number_of_shards": 1 + }, + "mappings": { + "stat": { + "_source": { + "enabled": true + }, + "properties": { + "timestamp": { "type": "date" }, + "worker": { "type": "keyword" }, + "category": { "type": "keyword" }, + "metric": { "type": "keyword" }, + "variant": { "type": "keyword" }, + "value": { "type": "float" }, + "unit": { "type": "keyword" }, + "task": { "type": "keyword" } + } + } + } +} \ No newline at end of file