golang micro client 报错500 {"id":"go.micro.client","code":408,"detail":"call timeout: context deadline exceeded","status":"Request Timeout"}
go micro web端连接services时,第一次访问提示500(broken pipe),排查发现客户端请求services时返回
{"id":"go.micro.client","code":408,"detail":"call timeout: context deadline exceeded","status":"Request Timeout"}
修改micro client超时时间后没再出现过这种情况,待跟踪
具体修改:
#service增加CallOption并设置超时时间
var opss client.CallOption = func(o *client.CallOptions) {
o.RequestTimeout = time.Second *
o.DialTimeout = time.Second *
} func (VipService) GetTotalCash() (*vip.CashResponse, error) {
return VipSrv.GetTotalCash(context.TODO(), &vip.CashRequest{}, opss)
}
golang micro client 报错500 {"id":"go.micro.client","code":408,"detail":"call timeout: context deadline exceeded","status":"Request Timeout"}的更多相关文章
- source /etc/profile报错-bash: id:command is not found
由于误操作导致 source /etc/profile 报错 -bash: id:command is not found 此时,linux下很多命令到不能能用,包括vi ls 等... 可以使用 e ...
- 关于centos7字体缺失导致项目验证码丢失报错500问题
这个问题是这样的,迁移架构的时候项目验证码刷不出来, 页面报错500, 就像下面那样. tomcat报错是数组越界, 看下面 最诡异的是, 开发那边再三确定代码里面没有问题, 于是我试了一下把war包 ...
- golang解析json报错:invalid character '\x00' after top-level value
golang解析json报错:invalid character '\x00' after top-level value 手动复制字符串:{"files":["c:/t ...
- 打开nginx配置的站点报错500
打开站点报错500的原因 有很多,这里只说明一点:nginx 的fastcgi.conf配置引起的问题 环境说明 1 站点目录结构 wwwroot website public application ...
- python连接oracle数据库报错"DatabaseError: DPI-1047: 64-bit Oracle Client library cannot be loaded: "解决方案
操作系统,python3.5, oracle_11, 均为64位:plsql 正常连接. 也顺利安装了cx_oracle 6.3,但是python进行连接的时候就会报错"DatabaseEr ...
- spring boot中连接数据库报错500(mybatis)
spring boot中连接数据库报错500(mybatis) pom.xml中的依赖 <!-- 集成mybatis--> <dependency> <groupId&g ...
- DevC++ 报错[Error] Id returned 1 exit status
DevC++ 报错[Error] Id returned 1 exit status 起因 学校机房的计算机总是二次编译总是报错 报错提示 [Error] Id returned 1 exit sta ...
- eclipse 中离线安装activiti插件,报错“An error occurred while collecting items to be installed session context was:(...”
eclipse 中离线安装activiti插件,报错“An error occurred while collecting items to be installed session context ...
- 【报错】spring整合activeMQ,pom.xml文件缺架包,启动报错:Caused by: java.lang.ClassNotFoundException: org.apache.xbean.spring.context.v2.XBeanNamespaceHandler
spring版本:4.3.13 ActiveMq版本:5.15 ======================================================== spring整合act ...
随机推荐
- js实现五子棋人机对战源码
indexhtml <!DOCTYPE html> <html lang="en"> <head> <meta charset=" ...
- Linux中管理员用户与普通用户之间的切换
使用su进行用户切换 管理员用户切换至普通用户: su [用户名] 使用su命令从高级别用户切换至低级别用户无需输入密码 普通用户切换至管理员用户: 普通用户切换至管理员用户使用 su - 使用l ...
- 在centos 6.3系统下安装java、tomcat环境的方法与步骤(方法经过验证,可安装成功)
一.安装java1. 下载java二进制安装包 wget --no-cookies --no-check-certificate --header "Cookie: gpw_e24=http ...
- POJ2182Lost Cows
Lost Cows Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 11946 Accepted: 7690 Descri ...
- js实现使用递归来计算1~任意数字的和
function getSum(n){ if(n==1){ return 1; } return n+getSum(n-1); } var res = getSum(100); console.log ...
- vue里调用moment.js
1.首先安装moment npm install moment --save 2.在main.js里引入 import moment from 'moment'//导入文件 Vue.prot ...
- NLTK的探索
import nltk import random from nltk.corpus import movie_reviews documents = [(list(movie_reviews.wor ...
- django 验证码(django-simple-captcha)
django 验证码(django-simple-captcha) django-simple-captcha 官方文档(含基于modelForm的用法) https://django-simple ...
- Katalon系列二十一:用例中语句失败处理
假如有一个用例:1.登陆2.下单3.对历史单评价4.退出 情况一:当第1步执行失败时,我们希望用例不再执行,因为再执行也没有意义了,反而浪费时间:情况二:当第2步执行失败时,我们希望能略过第2步操作, ...
- 移动web的基础知识
一.像素 px:CSS pixels逻辑像素,浏览器使用的抽象单位 dp,pt:设备无关像素 (物理像素) dpr:设备像素缩放比 计算公式: 1px = (dpr)*(dpr)*dp 二.viewp ...