INNER CODE UNIT · Python
GlobalKPI
DataDog/KubeHound · scripts/dashboard-demo/main.py:166
class GlobalKPI(KPI):
DISPLAY_TITLE = "Global stats"
KH_QUERY_MIN_HOPS = "kh.V().minHopsToCritical()"
KH_QUERY_EXTERNAL_COUNTS = "kh.V().count()"
KH_QUERY_DETAILS= ''
KH_QUERY_DETAILS_KEYS = []
KH_QUERY_EXTERNAL_CRITICAL_PATH = '''kh.V().
count().
aggregate("t").
V().
hasCriticalPath().
count().
as("e").
math("100 * e/t").by().by(unfold())'''
DESCRIPTION = ""
def get_main(self):
kh_query_attacks_stats = 'g.E().groupCount().by(label)'