Adds aiocallback in aioread of msgkafka 25/6725/3
authorBenjamin Diaz <bdiaz@whitestack.com>
Thu, 18 Oct 2018 20:55:12 +0000 (17:55 -0300)
committerBenjamin Diaz <bdiaz@whitestack.com>
Mon, 22 Oct 2018 16:49:15 +0000 (13:49 -0300)
commit48b78e112662d927cad376d739e43fb94f108ff3
tree804396d419a0554dc534c91c04ad7dd4ddb3e6bf
parent76a6056e2ec3bc5d7d7ead6423d721b0e4bd7475
Adds aiocallback in aioread of msgkafka

aioread can now receive an async function as param,
which will be awaited during the consumer msg loop.
This allows of taking full advantage of asyncio.

Also it now passes de kwargs to the callback, instead
of the args. Without this, all params of aioread had to be
passed positionally if you wanted to give additional args
to the callback.

Signed-off-by: Benjamin Diaz <bdiaz@whitestack.com>
Change-Id: I2502c0f2f76643660da1ff24eafa62af2450eacb
osm_common/__init__.py
osm_common/msgbase.py
osm_common/msgkafka.py