kata_agent: print request details

It helps tracking each request that is sent and we can match with the
one printed by kata-agent on the guest side to find out any stack
requests in the middle.

Fixes: #494

Signed-off-by: Peng Tao <bergwolf@gmail.com>
This commit is contained in:
Peng Tao 2018-07-18 00:45:21 +08:00
parent 77cbea5a42
commit 5d6da3517a

View File

@ -1269,6 +1269,8 @@ func (k *kataAgent) sendReq(request interface{}) (interface{}, error) {
if msgName == "" || handler == nil {
return nil, errors.New("Invalid request type")
}
message := request.(proto.Message)
k.Logger().WithField("name", msgName).WithField("req", message.String()).Debug("sending request")
return handler(context.Background(), request)
}