Log CNI_ARGS and CNI_NETNS in kuryr-cni
Currently we only print "Calling Kuryr Daemon." in our kuryr-cni plugin binary. This isn't really helpful: crio[1963]: 2020/03/03 20:53:49 Calling Kuryr Daemon. crio[1963]: 2020/03/03 20:53:53 Calling Kuryr Daemon. crio[1963]: 2020/03/03 20:53:53 Calling Kuryr Daemon. crio[1963]: 2020/03/03 20:53:53 Calling Kuryr Daemon. crio[1963]: 2020/03/03 20:53:54 Calling Kuryr Daemon. crio[1963]: 2020/03/03 20:53:54 Calling Kuryr Daemon. crio[1963]: 2020/03/03 20:53:54 Calling Kuryr Daemon. (…) This commit enhances that logging to include values of CNI_ARGS and CNI_NETNS, which should allow us to identify which request is being handled. Change-Id: Ie66e4972cc109990d0f4fc077fa9031ac67db7ff Related-Bug: 1854928
This commit is contained in:
parent
ded6b6debc
commit
da1e0aa2ee
@ -55,7 +55,7 @@ func transformData(args *skel.CmdArgs, command string) (KuryrDaemonData, error)
|
||||
}
|
||||
|
||||
func makeDaemonRequest(data KuryrDaemonData, expectedCode int) ([]byte, error) {
|
||||
log.Print("Calling Kuryr Daemon.")
|
||||
log.Printf("Calling kuryr-daemon with %s request (CNI_ARGS=%s, CNI_NETNS=%s).", data.Command, data.Args, data.Netns)
|
||||
|
||||
b, err := json.Marshal(data)
|
||||
if err != nil {
|
||||
|
Loading…
Reference in New Issue
Block a user