当前位置:网站首页>In-depth understanding of timeout settings for Istio traffic management
In-depth understanding of timeout settings for Istio traffic management
2022-08-05 10:17:00 【InfoQ】
环境准备
httpbinkubectl apply -f samples/httpbin/httpbin.yamlsleepkubectl apply -f samples/sleep/sleep.yaml httpbinsleep设置超时时间
sleephttpbinexport SLEEP_POD=$(kubectl get pods -l app=sleep -o 'jsonpath={.items[0].metadata.name}')
kubectl exec "$SLEEP_POD" -c sleep -- time curl -o /dev/null -sS -w "%{http_code}\n" http://httpbin.org/delay/5200
real 0m 5.69s
user 0m 0.00s
sys 0m 0.00shttpbinkubectl apply -f - <<EOF
apiVersion: networking.istio.io/v1alpha3
kind: VirtualService
metadata:
name: httpbin
spec:
hosts:
- httpbin
http:
- route:
- destination:
host: httpbin
timeout: 3s
EOF504
real 0m 3.01s
user 0m 0.00s
sys 0m 0.00shttpbin查看Envoy日志
sleepkubectl logs -l app=sleep -c istio-proxysleephttpbin{
"authority": "httpbin:8000",
"bytes_received": 0,
"bytes_sent": 24,
"connection_termination_details": null,
"downstream_local_address": "172.24.146.239:8000",
"downstream_remote_address": "172.24.158.25:40384",
"duration": 3001,
"method": "GET",
"path": "/delay/5",
"protocol": "HTTP/1.1",
"request_id": "5ef38816-7f49-48c8-9627-2416e1716293",
"requested_server_name": null,
"response_code": 504,
"response_code_details": "upstream_response_timeout",
"response_flags": "UT",
"route_name": null,
"start_time": "2022-07-01T09:40:13.882Z",
"upstream_cluster": "outbound|8000||httpbin.onemore.svc.cluster.local",
"upstream_host": "172.24.158.96:80",
"upstream_local_address": "172.24.158.25:32846",
"upstream_service_time": null,
"upstream_transport_failure_reason": null,
"user_agent": "curl/7.81.0-DEV",
"x_forwarded_for": null
}response_flagsUTsleephttpbinhttpbinkubectl logs -l app=httpbin -c istio-proxyhttpbinsleep{
"authority": "httpbin:8000",
"bytes_received": 0,
"bytes_sent": 0,
"connection_termination_details": null,
"downstream_local_address": "172.24.158.96:80",
"downstream_remote_address": "172.24.158.25:32846",
"duration": 2997,
"method": "GET",
"path": "/delay/5",
"protocol": "HTTP/1.1",
"request_id": "5ef38816-7f49-48c8-9627-2416e1716293",
"requested_server_name": "outbound_.8000_._.httpbin.onemore.svc.cluster.local",
"response_code": 0,
"response_code_details": "downstream_remote_disconnect",
"response_flags": "DC",
"route_name": "default",
"start_time": "2022-07-01T09:40:13.885Z",
"upstream_cluster": "inbound|80||",
"upstream_host": "172.24.158.96:80",
"upstream_local_address": "127.0.0.6:35701",
"upstream_service_time": null,
"upstream_transport_failure_reason": null,
"user_agent": "curl/7.81.0-DEV",
"x_forwarded_for": null
}response_flagsDCsleep深入分析
httpbin
httpbin
httpbinsleep清理
kubectl delete virtualservice httpbin
kubectl delete -f samples/httpbin/httpbin.yaml
kubectl delete -f samples/sleep/sleep.yaml 边栏推荐
- 牛刀小试基本语法,Go lang1.18入门精炼教程,由白丁入鸿儒,go lang基本语法和变量的使用EP02
- Jenkins manual (2) - software configuration
- [Office] Collection of Microsoft Office download addresses (offline installation and download of Microsoft's official original version)
- Development common manual link sharing
- 微服务 技术栈
- SQL外连接之交集、并集、差集查询
- Qiu Jun, CEO of Eggplant Technology: Focus on users and make products that users really need
- Advanced usage of C language
- 用户考试分数大于单科科目平均分的查询
- 气象数据数据处理实例——matlab字符串切割匹配与R语言日期匹配(数据拼接)
猜你喜欢

The founder of the DFINITY Foundation talks about the ups and downs of the bear market, and where should DeFi projects go?

产品太多了,如何实现一次登录多产品互通?

偏向锁/轻量锁/重级锁锁锁更健康,上锁解锁到底是怎么完成实现的

STM32+ULN2003驱动28BYJ4步进电机(根据圈数正转、反转)

dotnet OpenXML 解析 PPT 图表 面积图入门

数据中台建设(十):数据安全管理

STM32+ULN2003 drives 28BYJ4 stepper motor (forward and reverse according to the number of turns)

NowCoderTOP35-40——持续更新ing

我们的Web3创业项目,黄了

气象数据数据处理实例——matlab字符串切割匹配与R语言日期匹配(数据拼接)
随机推荐
Voice-based social software development - making the most of its value
电竞、便捷、高效、安全,盘点OriginOS功能的关键词
uniapp 连接ibeacon
还在找网盘资源吗?快点收藏如下几个值得收藏的网盘资源搜索神器吧!
什么是CRM决策分析管理?
我们的Web3创业项目,黄了
仿SBUS与串口数据固定转换
第四章:redis 数组结构的set和一些通用命令「建议收藏」
The founder of the DFINITY Foundation talks about the ups and downs of the bear market, and where should DeFi projects go?
Oracle temporary table space role
leetcode: 529. 扫雷游戏
MySQL transactions
STM32+ULN2003 drives 28BYJ4 stepper motor (forward and reverse according to the number of turns)
2022华数杯数学建模思路分析交流
First Decentralized Heist?Loss of nearly 200 million US dollars: analysis of the attack on the cross-chain bridge Nomad
QSS 选择器
dotnet OpenXML parsing PPT charts Getting started with area charts
Getting started with Polkadot parachain development, this article is enough
Qiu Jun, CEO of Eggplant Technology: Focus on users and make products that users really need
SMB + SMB2: Accessing shares return an error after prolonged idle period