kx time out 10s add log
This commit is contained in:
parent
2f6b22db59
commit
0c7571cb7b
|
|
@ -75,7 +75,9 @@ func (v *VoucherBiz) useLog(ctx context.Context, order *bo.OrderBo, req *bo.Wech
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return v.wxToBBUse(ctx, order, req)
|
_ = v.wxToBBUse(ctx, order, req)
|
||||||
|
|
||||||
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func (v *VoucherBiz) used(ctx context.Context, order *bo.OrderBo) error {
|
func (v *VoucherBiz) used(ctx context.Context, order *bo.OrderBo) error {
|
||||||
|
|
|
||||||
|
|
@ -49,12 +49,12 @@ func (this *KxMixRepoImpl) Request(ctx context.Context, req *kog.Notice) error {
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
//fmt.Printf("请求kx,url:%s,reqBody:%s", url, string(body))
|
|
||||||
|
|
||||||
|
start := time.Now()
|
||||||
_, bodyBytes, err := request.POST(ctx, url, body, this.options)
|
_, bodyBytes, err := request.POST(ctx, url, body, this.options)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Errorf("请求kx,url:%s,reqBody:%s,respBody:%s,err:%v", url, string(body), string(bodyBytes), err)
|
log.Errorf("请求kx发生错误,耗时:%s,url:%s,reqBody:%s,respBody:%s,err:%v", time.Now().Sub(start).String(), url, string(body), string(bodyBytes), err)
|
||||||
return nil
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
return nil
|
return nil
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue