MCPcopy Create free account
hub / github.com/RedisGraph/RedisGraph / run_concurrent

Function run_concurrent

tests/flow/test_concurrent_query.py:40–52  ·  view source on GitHub ↗
(queries, f)

Source from the content-addressed store, hash-verified

38 return False
39
40def run_concurrent(queries, f):
41 pool = Pool(nodes=CLIENT_COUNT)
42 manager = pathos_multiprocess.Manager()
43
44 barrier = manager.Barrier(CLIENT_COUNT)
45 barriers = [barrier] * CLIENT_COUNT
46
47 # invoke queries
48 results = pool.map(f, queries, barriers)
49
50 pool.clear()
51
52 return results
53
54class testConcurrentQueryFlow(FlowTestsBase):
55 def __init__(self):

Calls 1

clearMethod · 0.45

Tested by

no test coverage detected