monasca-analytics/config/markov_source_config.banana

58 lines
958 B
Plaintext

##############################
# Markov source config example
# (cloud-like data model)
#
src = CloudMarkovChainSource(sleep=0.01, min_event_per_burst=500)
src.transitions.web_service = {
"run=>slow": {
"0": 0.001,
"8": 0.02,
"12": 0.07,
"14": 0.07,
"22": 0.03,
"24": 0.00
},
"slow=>run": {
"0": 0.99,
"8": 0.7,
"12": 0.1,
"14": 0.1,
"22": 0.8,
"24": 0.9
},
"stop=>run": 0.7
}
src.transitions.host = {
"on=>off": 0.005,
"off=>on": 0.5
}
src.transitions.switch = {
"on=>off": 0.01,
"off=>on": 0.7
}
src.triggers.support = {
"get_called" : {
"0": 0.1,
"8": 0.2,
"12": 0.8,
"14": 0.8,
"22": 0.5,
"24": 0.0
}
}
ing1 = CloudIngestor()
ling = LiNGAM(threshold=0.5)
voter = PickIndexVoter(0)
sink = KafkaSink(host="localhost", port=9092, topic="transformed_alerts")
ldp = CloudCausalityLDP()
# Connections
src -> [ing1 -> ling, ldp]
ling -> voter -> ldp -> sink