Skip to content
Snippets Groups Projects
Commit 5f9af4c2 authored by Sven-Ove Hänsel's avatar Sven-Ove Hänsel
Browse files

added something

parent bc738cac
Branches
Tags
No related merge requests found
......@@ -20,6 +20,7 @@ services:
command:
- "--config.file=/etc/prometheus/prometheus.yml"
- '--web.enable-admin-api'
- '--storage.tsdb.retention.time=1y'
volumes:
- ./monitoring/prometheus/config/prometheus.yml:/etc/prometheus/prometheus.yml
- ./monitoring/prometheus/data:/prometheus
......
No preview for this file type
!# bin/bash#!/bin/bash
# Define the base URL
BASE_URL="http://localhost:9090/api/v1/admin/tsdb/delete_series"
# Define the jobs
JOBS=("postgres" "cadvisor" "neo4j")
# Loop through each job and execute the curl command
for job in "${JOBS[@]}"; do
curl -u admin -X POST -g "${BASE_URL}?match[]={job=\"${job}\"}"
done
......@@ -211,3 +211,4 @@ CREATE TABLE edge_list(
edge_type varchar(1024)
);
-- CREATE ROLE root;
\ No newline at end of file
......@@ -177,13 +177,18 @@ def parse_json_to_sql_query(json,node_type):
queries.append(q2)
# edge into edge list
print("edge_values: ",edge_values)
if len(edge_values[1]) != 0:
q3 = create_edge_insert_query(edge_values)
queries.append(q3)
else:
print("no edges")
# print queries for debugging
j = 0
for q in queries:
j+=1
print(f"Insert Query {j}:", q)
return queries
def handle_message(m):
......@@ -206,10 +211,10 @@ def on_message(client, userdata, message):
'''
data = json.loads(message.payload.decode("utf-8"))
# print(f"Received message")# {data} from: ",message.topic)
# try:
try:
handle_message(data)
# except Exception as e:
# print(e)
except Exception as e:
print(e)
def on_connect(client, userdata, flags, return_code):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment