Commit b868505b authored by Andrey Vertiprahov's avatar Andrey Vertiprahov
Browse files

Merge branch 'cherry-pick-7d42073c' into 'release-22.1'

release-22.1:Backport!6391

See merge request !6392
parents 2ca5821e bf82a6fa
......@@ -26,7 +26,7 @@ def set_segment_redundancy(alarm):
mo = alarm.managed_object
seg = mo.segment
if seg.is_redundant and not seg.lost_redundancy:
u = mo.data.uplinks
u = mo.uplinks
if len(u) > 1:
logger.info("[%s] Redundancy lost for %s", alarm.id, seg.name)
seg.set_lost_redundancy(True)
......@@ -43,7 +43,7 @@ def check_segment_redundancy(alarm):
seg = mo.segment
if not seg.is_redundant or not seg.lost_redundancy:
return
u = mo.data.uplinks
u = mo.uplinks
if len(u) < 2:
return
seg_objects = list(seg.managed_objects.values_list("id", flat=True))
......
......@@ -1123,7 +1123,7 @@ class CorrelatorService(TornadoService):
if self.is_distributed:
# Set lock until the end of dispose
mo = alarm.managed_object
self.topo_rca_lock = RCALock(mo.data.rca_neighbors + [mo.id])
self.topo_rca_lock = RCALock(mo.rca_neighbors + [mo.id])
await self.topo_rca_lock.acquire()
# Get neighboring alarms
neighbor_alarms = get_neighboring_alarms(alarm)
......
......@@ -240,7 +240,7 @@ class ManagedObjectDataStream(DataStream):
# Populate
r["interfaces"] = [
ManagedObjectDataStream._get_interface(
i, subs[i["_id"]], links[i["_id"]], ifcache, set(mo.data.uplinks), services
i, subs[i["_id"]], links[i["_id"]], ifcache, set(mo.uplinks), services
)
for i in interfaces
]
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment