Consul 1.9測試版發佈:新增拓撲圖和改進的Kubernetes集成

{"type":"doc","content":[{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"Hashicorp發佈"},{"type":"link","attrs":{"href":"https:\/\/www.hashicorp.com\/blog\/announcing-hashicorp-consul-1-9","title":"","type":null},"content":[{"type":"text","text":"Consul 1.9測試版"}]},{"type":"text","text":",爲其服務網格平臺添加了新特性。這個版本包括對意圖模型的增強,以支持Layer 7構造、新的驗證配置可視化,以及Kubernetes自定義資源。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"隨着"},{"type":"link","attrs":{"href":"https:\/\/www.consul.io\/docs\/connect\/intentions","title":"","type":null},"content":[{"type":"text","text":"應用程序感知意圖"}]},{"type":"text","text":"的引入,現在可以制定支持L7交互的策略,包括支持基於HTTP請求頭和URL路徑來判斷是否允許服務間通信。在以前的版本中,意圖只支持L4交互,現在可以將L4和L7混合成一個意圖聲明:"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"codeblock","attrs":{"lang":"plain"},"content":[{"type":"text","text":"Kind = \"service-intentions\"\nName = \"api\"\nSources = [\n {\n Name = \"hackathon-project\"\n Action = \"deny\"\n },\n {\n Name = \"web\"\n Action = \"allow\"\n },\n {\n Name = \"nightly-reconciler\"\n Permissions = [\n {\n Action = \"allow\"\n HTTP {\n PathExact = \"\/v1\/reconcile-data\"\n Methods = [\"POST\"]\n }\n }\n ]\n }\n]\n"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"上面的"},{"type":"link","attrs":{"href":"https:\/\/www.consul.io\/docs\/agent\/config-entries\/service-intentions#interaction-with-other-config-entries","title":"","type":null},"content":[{"type":"text","text":"示例"}]},{"type":"text","text":"定義了“api”的公共目標意圖。第一個意圖拒絕來自“hackathon-project”的連接,同時允許來自“web”的連接。對於“nightly-reconciler”,只允許使用POST方法從指定路徑發送的HTTP流量。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"傳統上,Consul的調試和故障排除需要依賴錯誤日誌、命令行輸出和發送遙測到外部系統。Consul缺乏一種簡單的方法來可視化服務網格拓撲,從而簡化故障排除。這個版本添加了一個新的"},{"type":"link","attrs":{"href":"https:\/\/www.hashicorp.com\/blog\/service-mesh-visualization-in-hashicorp-consul-1-9","title":"","type":null},"content":[{"type":"text","text":"Topology選項卡"}]},{"type":"text","text":",用於展示拓撲關係圖以及關鍵的服務網格指標,如請求、錯誤率和時間。"},{"type":"link","attrs":{"href":"https:\/\/learn.hashicorp.com\/collections\/consul\/day-2-operations","title":"","type":null},"content":[{"type":"text","text":"維護和監控操作指南"}]},{"type":"text","text":"提供了更多的細節和最佳實踐。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"在拓撲圖中可以看到網格內服務之間的交互。兩個服務之間的明確拒絕將顯示爲帶x的紅線。我們可以通過拓撲圖將拒絕調整爲允許。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"image","attrs":{"src":"https:\/\/static001.infoq.cn\/resource\/image\/b1\/17\/b1c7acc4b6919dcea081e4b0427b8a17.png","alt":null,"title":"","style":[{"key":"width","value":"75%"},{"key":"bordertype","value":"none"}],"href":"","fromPaste":false,"pastePass":false}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"Consul UI的新拓撲選項卡顯示被拒絕的連接(感謝:"},{"type":"link","attrs":{"href":"https:\/\/www.hashicorp.com\/blog\/service-mesh-visualization-in-hashicorp-consul-1-9","title":"","type":null},"content":[{"type":"text","text":"Hashicorp"}]},{"type":"text","text":")"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"爲了改善kubernets優先的體驗,該版本將引入對自定義資源定義的支持,可通過kubernets風格的對象來簡化Consul的配置。現在可以通過CRD管理服務配置。在發佈時,以下的"},{"type":"link","attrs":{"href":"https:\/\/learn.hashicorp.com\/tutorials\/consul\/kubernetes-custom-resource-definitions","title":"","type":null},"content":[{"type":"text","text":"配置項"}]},{"type":"text","text":"可以作爲CRD:"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"bulletedlist","content":[{"type":"listitem","attrs":{"listStyle":null},"content":[{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"proxy-defaults——控制代理配置;"}]}]},{"type":"listitem","attrs":{"listStyle":null},"content":[{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"service-defaults——爲給定服務的所有實例配置默認值;"}]}]},{"type":"listitem","attrs":{"listStyle":null},"content":[{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"service-resolver——匹配帶有特定Connect上游請求的服務實例;"}]}]},{"type":"listitem","attrs":{"listStyle":null},"content":[{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"service-router——定義向何處發送L7流量(基於HTTP路由);"}]}]},{"type":"listitem","attrs":{"listStyle":null},"content":[{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"service-splitter——定義如何基於百分比劃分HTTP路由請求;"}]}]},{"type":"listitem","attrs":{"listStyle":null},"content":[{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"service-intentions——定義服務與服務之間的交互限制。"}]}]}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"作爲與Kubernetes集成的一個額外改進,Consul現在可以通過它的"},{"type":"link","attrs":{"href":"https:\/\/kubernetes.io\/docs\/tasks\/configure-pod-container\/configure-liveness-readiness-startup-probes\/","title":"","type":null},"content":[{"type":"text","text":"就緒狀態探針"}]},{"type":"text","text":"來檢測Kubernetes的健康狀態。這樣就可以根據"},{"type":"link","attrs":{"href":"https:\/\/www.consul.io\/docs\/agent\/checks","title":"","type":null},"content":[{"type":"text","text":"Consul的運行狀況檢查"}]},{"type":"text","text":"和原生Kubernetes的運行狀況檢查來決定流量應該流向哪裏。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"流的引入提高了Consul大規模部署時的CPU和網絡帶寬使用率。在"},{"type":"link","attrs":{"href":"https:\/\/www.consul.io\/api-docs\/features\/blocking","title":"","type":null},"content":[{"type":"text","text":"阻塞查詢"}]},{"type":"text","text":"的更新通知方面做出了重大的架構改進。服務"},{"type":"link","attrs":{"href":"https:\/\/www.consul.io\/api-docs\/health#list-nodes-for-service","title":"","type":null},"content":[{"type":"text","text":"健康檢查HTTP端點"}]},{"type":"text","text":"提供了流功能,可以通過配置標誌和緩存的URL參數來啓用。未來的版本將有更多的端點提供流功能。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"Consul 1.9現已發佈測試版。Hashicorp不保證向前兼容,因此建議將其安裝在允許發生故障的集羣中。更多的發佈細節可以查看"},{"type":"link","attrs":{"href":"https:\/\/github.com\/hashicorp\/consul\/blob\/master\/CHANGELOG.md#190-beta1-october-12-2020","title":"","type":null},"content":[{"type":"text","text":"變更日誌"}]},{"type":"text","text":"。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","marks":[{"type":"strong"}],"text":"原文鏈接"},{"type":"text","text":":"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"link","attrs":{"href":"https:\/\/www.infoq.com\/news\/2020\/11\/consul-1-9-beta\/","title":"","type":null},"content":[{"type":"text","text":"HashiCorp Enhances Consul with Topology Maps and Improved Kubernetes Integrations"}]}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}}]}
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章