papi: introduce read_blocking 50/24850/2
authorVratko Polak <[email protected]>
Tue, 10 Sep 2019 11:35:11 +0000 (13:35 +0200)
committerDave Barach <[email protected]>
Tue, 18 Feb 2020 13:28:43 +0000 (13:28 +0000)
commit1c45b85dff2a0e8c60541cfa5371090fb9502e18
tree82549539939e49c2dff2271c95626f29b0877262
parent72ab26ca8f1f4d28c41b39f994ac82f60552f41a
papi: introduce read_blocking

Previously, self.transport.q got the messages
(at least for socket transport), stored in the encoded (packed) form.
In order to avoid accessing internals for async reads,
a new method is introduced, to perform
blocking reads of decoded (unpacked) messages.

The method is also used in _call_vpp(),
so sync and async reads are kept compatible.

Type: feature

Change-Id: Id49792dfa57c00b1a14a198031c5398d09a9ba20
Signed-off-by: Vratko Polak <[email protected]>
(cherry picked from commit 0938547eaaf5440de28877fa4f873c21bcb8cfbf)
src/vpp-api/python/vpp_papi/vpp_papi.py