예제 #1
0
def get_flow_traces(tr):
    rows = cassandra.execute(
        """SELECT flowtraceid FROM midonetflowtracing.flows
           WHERE tracerequestid = %s""",
        [UUID(tr)],
    )
    return [str(r.flowtraceid) for r in rows]
예제 #2
0
def get_hosts(tr, flowtraceid):
    rows = cassandra.execute(
        """SELECT host FROM midonetflowtracing.flow_events
           WHERE tracerequestid = %s AND flowtraceid = %s""",
        [UUID(tr), UUID(flowtraceid)])
    hosts = set()
    for r in rows:
        hosts.add(r.host)
    return hosts
예제 #3
0
def get_hosts(tr, flowtraceid):
    rows = cassandra.execute(
        """SELECT host FROM midonetflowtracing.flow_events
           WHERE tracerequestid = %s AND flowtraceid = %s""",
        [UUID(tr), UUID(flowtraceid)])
    hosts = set()
    for r in rows:
        hosts.add(r.host)
    return hosts
예제 #4
0
def get_flow_traces(tr):
    rows = cassandra.execute(
        """SELECT flowtraceid FROM midonetflowtracing.flows
           WHERE tracerequestid = %s""", [UUID(tr)])
    return [str(r.flowtraceid) for r in rows]