You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dubbo.apache.org by gi...@apache.org on 2023/05/11 10:52:49 UTC

[dubbo-website] branch cn-site updated: deploy: e754b00edeee1c3b19efd7dd0b55b69b38331fa6

This is an automated email from the ASF dual-hosted git repository.

github-bot pushed a commit to branch cn-site
in repository https://gitbox.apache.org/repos/asf/dubbo-website.git


The following commit(s) were added to refs/heads/cn-site by this push:
     new 93b559d2b8 deploy: e754b00edeee1c3b19efd7dd0b55b69b38331fa6
93b559d2b8 is described below

commit 93b559d2b83fd04f5f7a534a45104655cb845db0
Author: AlbumenJ <Al...@users.noreply.github.com>
AuthorDate: Thu May 11 10:52:43 2023 +0000

    deploy: e754b00edeee1c3b19efd7dd0b55b69b38331fa6
---
 sitemap.xml                                        |  2 +-
 zh-cn/overview/reference/protocols/http/index.html | 49 ++++++++++++++++++----
 zh-cn/overview/reference/protocols/index.xml       | 47 +++++++++++++++++----
 zh-cn/sitemap.xml                                  |  2 +-
 4 files changed, 82 insertions(+), 18 deletions(-)

diff --git a/sitemap.xml b/sitemap.xml
index 0967acae21..bd5126f76b 100644
--- a/sitemap.xml
+++ b/sitemap.xml
@@ -1 +1 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?><sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"><sitemap><loc>https://cn.dubbo.apache.org/zh-cn/sitemap.xml</loc><lastmod>2023-05-10T11:59:30+08:00</lastmod></sitemap><sitemap><loc>https://cn.dubbo.apache.org/en/sitemap.xml</loc><lastmod>2023-05-10T11:59:30+08:00</lastmod></sitemap></sitemapindex>
\ No newline at end of file
+<?xml version="1.0" encoding="utf-8" standalone="yes"?><sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"><sitemap><loc>https://cn.dubbo.apache.org/zh-cn/sitemap.xml</loc><lastmod>2023-05-11T18:47:51+08:00</lastmod></sitemap><sitemap><loc>https://cn.dubbo.apache.org/en/sitemap.xml</loc><lastmod>2023-05-10T11:59:30+08:00</lastmod></sitemap></sitemapindex>
\ No newline at end of file
diff --git a/zh-cn/overview/reference/protocols/http/index.html b/zh-cn/overview/reference/protocols/http/index.html
index 348844b4bc..1c09bd2573 100644
--- a/zh-cn/overview/reference/protocols/http/index.html
+++ b/zh-cn/overview/reference/protocols/http/index.html
@@ -1,4 +1,4 @@
-<!doctype html><html lang=zh-cn class=no-js><head><meta name=ROBOTS content="INDEX, FOLLOW"><link rel=canonical href=https://cn.dubbo.apache.org/zh-cn/overview/reference/protocols/http/><script>var _hmt=_hmt||[];(function(){var e,t=document.createElement("script");t.src="https://hm.baidu.com/hm.js?3b78f49ba47181e4d998a66b689446e9",e=document.getElementsByTagName("script")[0],e.parentNode.insertBefore(t,e)})()</script><meta charset=utf-8><meta name=viewport content="width=device-width,ini [...]
+<!doctype html><html lang=zh-cn class=no-js><head><meta name=ROBOTS content="INDEX, FOLLOW"><link rel=canonical href=https://cn.dubbo.apache.org/zh-cn/overview/reference/protocols/http/><script>var _hmt=_hmt||[];(function(){var e,t=document.createElement("script");t.src="https://hm.baidu.com/hm.js?3b78f49ba47181e4d998a66b689446e9",e=document.getElementsByTagName("script")[0],e.parentNode.insertBefore(t,e)})()</script><meta charset=utf-8><meta name=viewport content="width=device-width,ini [...]
 <script>var doNotTrack=!1;if(!doNotTrack){window.dataLayer=window.dataLayer||[];function gtag(){dataLayer.push(arguments)}gtag("js",new Date),gtag("config","G-NM6FFMT51J",{anonymize_ip:!1})}</script><link rel=preload href=/scss/main.min.7fa6d3c7f521df6fedf4e016ce03c86424bbf48f7b0d070a25f450054a7fcfeb.css as=style><link href=/scss/main.min.7fa6d3c7f521df6fedf4e016ce03c86424bbf48f7b0d070a25f450054a7fcfeb.css rel=stylesheet integrity><script src=/js/jquery-3.5.1.min.js integrity="sha256-9/a [...]
 <link rel=stylesheet href=https://cdn.jsdelivr.net/npm/@docsearch/css@3><meta name=theme-color content="#326ce5"><link rel=stylesheet href=/css/feature-states.css><meta name=description content="HTTP Json 协议规范"><meta property="og:description" content="HTTP Json 协议规范"><meta name=twitter:description content="HTTP Json 协议规范"><meta property="og:url" content="https://cn.dubbo.apache.org/zh-cn/overview/reference/protocols/http/"><meta property="og:title" content="HTTP 协议规范"><meta name=twitter: [...]
 <link href=/css/community.css rel=stylesheet><link href=/css/contactus.css rel=stylesheet><link href=/css/language.css rel=stylesheet><script src=/js/script.js></script></head><body class="td-page td-documentation"><header><nav class="js-navbar-scroll navbar navbar-expand navbar-dark flex-column flex-md-row td-navbar" data-auto-burger=primary><a class=navbar-brand href=/zh-cn/><span class=navbar-logo></span><span class="text-uppercase font-weight-bold">Apache Dubbo</span></a><div class=" [...]
@@ -668,15 +668,16 @@
 <label for=m-zh-cnoverviewreferenceprotocols-check><a href=/zh-cn/overview/reference/protocols/ class="align-left pl-0 td-sidebar-link td-sidebar-link__section" id=m-zh-cnoverviewreferenceprotocols><span>协议规范</span></a></label><ul class="ul-3 foldable"><li class="td-sidebar-nav__section-title td-sidebar-nav__section without-child" id=m-zh-cnoverviewreferenceprotocolstriple-li><input type=checkbox id=m-zh-cnoverviewreferenceprotocolstriple-check>
 <label for=m-zh-cnoverviewreferenceprotocolstriple-check><a href=/zh-cn/overview/reference/protocols/triple/ title="Triple 协议设计理念与规范" class="align-left pl-0 td-sidebar-link td-sidebar-link__page" id=m-zh-cnoverviewreferenceprotocolstriple><span>Triple 协议规范</span></a></label></li><li class="td-sidebar-nav__section-title td-sidebar-nav__section without-child" id=m-zh-cnoverviewreferenceprotocolstcp-li><input type=checkbox id=m-zh-cnoverviewreferenceprotocolstcp-check>
 <label for=m-zh-cnoverviewreferenceprotocolstcp-check><a href=/zh-cn/overview/reference/protocols/tcp/ class="align-left pl-0 td-sidebar-link td-sidebar-link__page" id=m-zh-cnoverviewreferenceprotocolstcp><span>Dubbo2 协议规范</span></a></label></li><li class="td-sidebar-nav__section-title td-sidebar-nav__section without-child" id=m-zh-cnoverviewreferenceprotocolshttp-li><input type=checkbox id=m-zh-cnoverviewreferenceprotocolshttp-check>
-<label for=m-zh-cnoverviewreferenceprotocolshttp-check><a href=/zh-cn/overview/reference/protocols/http/ class="align-left pl-0 td-sidebar-link td-sidebar-link__page" id=m-zh-cnoverviewreferenceprotocolshttp><span>HTTP 协议规范</span></a></label></li></ul></li></ul></li></ul></li></ul></nav></div></div><main class="col-12 col-md-9 col-xl-8 pl-md-5" role=main><nav aria-label=breadcrumb class=td-breadcrumbs><ol class=breadcrumb><li class=breadcrumb-item><a href=https://cn.dubbo.apache.org/zh-c [...]
-且是必传header,如果使用dubbo http的RestClient这两个header将会默认通过attachment传递
-为区别于其他的header,attachment将会增加#rest#前缀,因此通过其他形式的http client调用
-dubbo http服务需要传递 #rest#version 和 #rest#group 两个header</p><div class=highlight><pre tabindex=0 style=color:#93a1a1;background-color:#002b36;-moz-tab-size:4;-o-tab-size:4;tab-size:4><code class=language-fallback data-lang=fallback><span style=display:flex><span>POST /test/path  HTTP/1.1
+<label for=m-zh-cnoverviewreferenceprotocolshttp-check><a href=/zh-cn/overview/reference/protocols/http/ class="align-left pl-0 td-sidebar-link td-sidebar-link__page" id=m-zh-cnoverviewreferenceprotocolshttp><span>HTTP 协议规范</span></a></label></li></ul></li></ul></li></ul></li></ul></nav></div></div><main class="col-12 col-md-9 col-xl-8 pl-md-5" role=main><nav aria-label=breadcrumb class=td-breadcrumbs><ol class=breadcrumb><li class=breadcrumb-item><a href=https://cn.dubbo.apache.org/zh-c [...]
+如果provider一端没有声明group和version,http请求时就不需要传递这连个header,反之必须要传递目标
+服务的group和version, 如果使用dubbo http的RestClient这两个header将会默认通过attachment传递
+为区别于其他的header,attachment将会增加rest-service-前缀,因此通过其他形式的http client调用
+dubbo http服务需要传递 rest-service-version 和 rest-service-group 两个header</p><div class=highlight><pre tabindex=0 style=color:#93a1a1;background-color:#002b36;-moz-tab-size:4;-o-tab-size:4;tab-size:4><code class=language-fallback data-lang=fallback><span style=display:flex><span>POST /test/path  HTTP/1.1
 </span></span><span style=display:flex><span>Host: localhost:8080
 </span></span><span style=display:flex><span>Content-type: application/json
 </span></span><span style=display:flex><span>Accept: text/html
-</span></span><span style=display:flex><span>#rest#version: 1.0.0
-</span></span><span style=display:flex><span>#rest#group: dubbo
+</span></span><span style=display:flex><span>rest-service-version: 1.0.0
+</span></span><span style=display:flex><span>rest-service-group: dubbo
 </span></span><span style=display:flex><span>
 </span></span><span style=display:flex><span>{&#34;name&#34;:&#34;dubbo&#34;,&#34;age&#34;:10,&#34;address&#34;:&#34;hangzhou&#34;}
 </span></span></code></pre></div><ul><li>Response</li></ul><div class=highlight><pre tabindex=0 style=color:#93a1a1;background-color:#002b36;-moz-tab-size:4;-o-tab-size:4;tab-size:4><code class=language-fallback data-lang=fallback><span style=display:flex><span>HTTP/1.1 200
@@ -1066,7 +1067,37 @@ JaxRs注解使用的时候我们要求service 类上必须使用@Path注解,
 </span></span><span style=display:flex><span>        String http <span style=color:#719e07>=</span> httpService<span style=color:#719e07>.</span>http<span style=color:#719e07>(</span><span style=color:#2aa198>&#34;Others Java Architecture Invoke Dubbo Rest&#34;</span><span style=color:#719e07>);</span>
 </span></span><span style=display:flex><span>        System<span style=color:#719e07>.</span>out<span style=color:#719e07>.</span>println<span style=color:#719e07>(</span>http<span style=color:#719e07>);</span>
 </span></span><span style=display:flex><span>    <span style=color:#719e07>}</span>
-</span></span></code></pre></div><ul><li><p>跨语言调用</p></li><li><p>多协议发布</p><ul><li>dubbo 协议的代码使用http 进行数据请求测试</li><li>服务协议迁移</li></ul></li></ul><div class=highlight><pre tabindex=0 style=color:#93a1a1;background-color:#002b36;-moz-tab-size:4;-o-tab-size:4;tab-size:4><code class=language-java data-lang=java><span style=display:flex><span><span style=color:#268bd2>@DubboService</span><span style=color:#719e07>(</span>interfaceClass <span style=color:#719e07>=</span> HttpService<span style=c [...]
+</span></span></code></pre></div><ul><li><p>跨语言调用</p><p>python</p><div class=highlight><pre tabindex=0 style=color:#93a1a1;background-color:#002b36;-moz-tab-size:4;-o-tab-size:4;tab-size:4><code class=language-fallback data-lang=fallback><span style=display:flex><span>import requests
+</span></span><span style=display:flex><span> url = &#39;http://localhost:8888/services/curl&#39;
+</span></span><span style=display:flex><span> headers = {
+</span></span><span style=display:flex><span> &#39;rest-service-group&#39;: &#39;test&#39;,
+</span></span><span style=display:flex><span> &#39;rest-service-version&#39;: &#39;1.0.0&#39;
+</span></span><span style=display:flex><span> }
+</span></span><span style=display:flex><span>response = requests.get(url, headers=headers)
+</span></span></code></pre></div><p>go</p><div class=highlight><pre tabindex=0 style=color:#93a1a1;background-color:#002b36;-moz-tab-size:4;-o-tab-size:4;tab-size:4><code class=language-fallback data-lang=fallback><span style=display:flex><span>  import (
+</span></span><span style=display:flex><span>  &#34;fmt&#34;
+</span></span><span style=display:flex><span>  &#34;net/http&#34;
+</span></span><span style=display:flex><span>   )
+</span></span><span style=display:flex><span>
+</span></span><span style=display:flex><span>  func main() {
+</span></span><span style=display:flex><span>  url := &#34;http://localhost:8888/services/curl&#34;
+</span></span><span style=display:flex><span>  req, err := http.NewRequest(&#34;GET&#34;, url, nil)
+</span></span><span style=display:flex><span>  if err != nil {
+</span></span><span style=display:flex><span>  fmt.Println(&#34;Error creating request:&#34;, err)
+</span></span><span style=display:flex><span>  return
+</span></span><span style=display:flex><span>  }
+</span></span><span style=display:flex><span>
+</span></span><span style=display:flex><span>  req.Header.Set(&#34;rest-service-group&#34;, &#34;test&#34;)
+</span></span><span style=display:flex><span>  req.Header.Set(&#34;rest-service-version&#34;, &#34;1.0.0&#34;)
+</span></span><span style=display:flex><span>  client := &amp;http.Client{}
+</span></span><span style=display:flex><span>  resp, err := client.Do(req)
+</span></span><span style=display:flex><span>  if err != nil {
+</span></span><span style=display:flex><span>      fmt.Println(&#34;Error sending request:&#34;, err)
+</span></span><span style=display:flex><span>      return
+</span></span><span style=display:flex><span>  }
+</span></span><span style=display:flex><span>
+</span></span><span style=display:flex><span>  defer resp.Body.Close()
+</span></span></code></pre></div></li><li><p>多协议发布</p><ul><li>dubbo 协议的代码使用http 进行数据请求测试</li><li>服务协议迁移</li></ul></li></ul><div class=highlight><pre tabindex=0 style=color:#93a1a1;background-color:#002b36;-moz-tab-size:4;-o-tab-size:4;tab-size:4><code class=language-java data-lang=java><span style=display:flex><span><span style=color:#268bd2>@DubboService</span><span style=color:#719e07>(</span>interfaceClass <span style=color:#719e07>=</span> HttpService<span style=color:#719e07>.</span [...]
 </span></span><span style=display:flex><span><span style=color:#268bd2>public</span> <span style=color:#268bd2>class</span> <span style=color:#268bd2>HttpServiceImpl</span> <span style=color:#268bd2>implements</span> HttpService <span style=color:#719e07>{</span>
 </span></span><span style=display:flex><span>
 </span></span><span style=display:flex><span>
@@ -1146,7 +1177,7 @@ JaxRs注解使用的时候我们要求service 类上必须使用@Path注解,
 </span></span><span style=display:flex><span><span style=color:#719e07>}</span>
 </span></span></code></pre></div><h2 id=32-与-30-http-实现对比>3.2 与 3.0 HTTP 实现对比</h2><p>因为 Dubbo Java 3.2 内部移除了原本 Resteasy 的实现,因此在对 Resteasy 内置的 Response,extend,ExceptionMapper 支持上将会有所变化
 ExceptionMapper 转换成了org.apache.dubbo.rpc.protocol.rest.exception.mapper.ExceptionHandler,Response后面也会做适配处理</p><table><thead><tr><th>版本</th><th>JaxRs</th><th>j2ee</th><th>web容器(tomcat/jetty)</th><th>spring web</th><th>http client(okhttp/httpclient/jdk URLConnnection )</th></tr></thead><tbody><tr><td>3.0</td><td>依赖与resteasy的client和server</td><td>遵循j2ee规范</td><td>依赖常见web容器</td><td>不依赖</td><td>不依赖</td></tr><tr><td>3.2</td><td>不依赖(仅需要JaxRs注解包)</td><td>不遵循</td><td>netty实现的http服务器</td><td>仅依赖sp [...]
-<button class="btn btn-primary mb-4 feedback--no">否</button></div><script>const yes=document.querySelector(".feedback--yes"),no=document.querySelector(".feedback--no");document.querySelectorAll(".feedback--link").forEach(e=>{e.href=e.href+window.location.pathname});const sendFeedback=e=>{gtag||console.log("!gtag"),gtag("event","click",{event_category:"Helpful",event_label:window.location.pathname,value:e})},disableButtons=()=>{yes.disabled=!0,yes.classList.add("feedback--button__disabled [...]
+<button class="btn btn-primary mb-4 feedback--no">否</button></div><script>const yes=document.querySelector(".feedback--yes"),no=document.querySelector(".feedback--no");document.querySelectorAll(".feedback--link").forEach(e=>{e.href=e.href+window.location.pathname});const sendFeedback=e=>{gtag||console.log("!gtag"),gtag("event","click",{event_category:"Helpful",event_label:window.location.pathname,value:e})},disableButtons=()=>{yes.disabled=!0,yes.classList.add("feedback--button__disabled [...]
 <a href="https://github.com/apache/dubbo-website/new/master/content/zh-cn/overview/reference/protocols/http.md?filename=change-me.md&amp;value=---%0Atitle%3A+%22Long+Page+Title%22%0AlinkTitle%3A+%22Short+Nav+Title%22%0Aweight%3A+100%0Adescription%3A+%3E-%0A+++++Page+description+for+heading+and+indexes.%0A---%0A%0A%23%23+Heading%0A%0AEdit+this+template+to+create+your+new+page.%0A%0A%2A+Give+it+a+good+name%2C+ending+in+%60.md%60+-+e.g.+%60getting-started.md%60%0A%2A+Edit+the+%22front+matte [...]
 <a href="https://github.com/apache/dubbo-website/issues/new?title=HTTP%20%e5%8d%8f%e8%ae%ae%e8%a7%84%e8%8c%83" target=_blank><i class="fab fa-github fa-fw"></i> 登记问题</a>
 <a href=https://github.com/apache/dubbo/issues/new target=_blank><i class="fas fa-tasks fa-fw"></i> 提交项目问题</a></div><nav id=TableOfContents><ul><li><a href=#什么是-dubbo-http>什么是 Dubbo Http</a></li><li><a href=#为什么选择dubbo-http>为什么选择Dubbo Http</a></li><li><a href=#协议规范>协议规范</a></li><li><a href=#快速入门>快速入门</a></li><li><a href=#使用场景>使用场景</a></li><li><a href=#32-与-30-http-实现对比>3.2 与 3.0 HTTP 实现对比</a></li></ul></nav></div></div></div></div><footer class="bg-dark py-5 row d-print-none footer-margi [...]
diff --git a/zh-cn/overview/reference/protocols/index.xml b/zh-cn/overview/reference/protocols/index.xml
index b660c975f9..bf9b487bd5 100644
--- a/zh-cn/overview/reference/protocols/index.xml
+++ b/zh-cn/overview/reference/protocols/index.xml
@@ -171,16 +171,17 @@
 &lt;ul>
 &lt;li>Request&lt;/li>
 &lt;/ul>
-&lt;p>相对于原生的http协议dubbo http 请求增加version和group两个header用于确定服务的唯一
-且是必传header,如果使用dubbo http的RestClient这两个header将会默认通过attachment传递
-为区别于其他的header,attachment将会增加#rest#前缀,因此通过其他形式的http client调用
-dubbo http服务需要传递 #rest#version 和 #rest#group 两个header&lt;/p>
+&lt;p>相对于原生的http协议dubbo http 请求增加version和group两个header用于确定服务的唯一,
+如果provider一端没有声明group和version,http请求时就不需要传递这连个header,反之必须要传递目标
+服务的group和version, 如果使用dubbo http的RestClient这两个header将会默认通过attachment传递
+为区别于其他的header,attachment将会增加rest-service-前缀,因此通过其他形式的http client调用
+dubbo http服务需要传递 rest-service-version 和 rest-service-group 两个header&lt;/p>
 &lt;div class="highlight">&lt;pre tabindex="0" style="color:#93a1a1;background-color:#002b36;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">&lt;code class="language-fallback" data-lang="fallback">&lt;span style="display:flex;">&lt;span>POST /test/path HTTP/1.1
 &lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>Host: localhost:8080
 &lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>Content-type: application/json
 &lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>Accept: text/html
-&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>#rest#version: 1.0.0
-&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>#rest#group: dubbo
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>rest-service-version: 1.0.0
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>rest-service-group: dubbo
 &lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>
 &lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>{&amp;#34;name&amp;#34;:&amp;#34;dubbo&amp;#34;,&amp;#34;age&amp;#34;:10,&amp;#34;address&amp;#34;:&amp;#34;hangzhou&amp;#34;}
 &lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;ul>
@@ -606,7 +607,39 @@ JaxRs注解使用的时候我们要求service 类上必须使用@Path注解,
 &lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;ul>
 &lt;li>
 &lt;p>跨语言调用&lt;/p>
-&lt;/li>
+&lt;p>python&lt;/p>
+&lt;div class="highlight">&lt;pre tabindex="0" style="color:#93a1a1;background-color:#002b36;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">&lt;code class="language-fallback" data-lang="fallback">&lt;span style="display:flex;">&lt;span>import requests
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> url = &amp;#39;http://localhost:8888/services/curl&amp;#39;
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> headers = {
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> &amp;#39;rest-service-group&amp;#39;: &amp;#39;test&amp;#39;,
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> &amp;#39;rest-service-version&amp;#39;: &amp;#39;1.0.0&amp;#39;
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> }
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>response = requests.get(url, headers=headers)
+&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;p>go&lt;/p>
+&lt;div class="highlight">&lt;pre tabindex="0" style="color:#93a1a1;background-color:#002b36;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">&lt;code class="language-fallback" data-lang="fallback">&lt;span style="display:flex;">&lt;span> import (
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> &amp;#34;fmt&amp;#34;
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> &amp;#34;net/http&amp;#34;
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> )
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> func main() {
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> url := &amp;#34;http://localhost:8888/services/curl&amp;#34;
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> req, err := http.NewRequest(&amp;#34;GET&amp;#34;, url, nil)
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> if err != nil {
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> fmt.Println(&amp;#34;Error creating request:&amp;#34;, err)
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> return
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> }
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> req.Header.Set(&amp;#34;rest-service-group&amp;#34;, &amp;#34;test&amp;#34;)
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> req.Header.Set(&amp;#34;rest-service-version&amp;#34;, &amp;#34;1.0.0&amp;#34;)
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> client := &amp;amp;http.Client{}
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> resp, err := client.Do(req)
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> if err != nil {
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> fmt.Println(&amp;#34;Error sending request:&amp;#34;, err)
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> return
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> }
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>
+&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span> defer resp.Body.Close()
+&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;/li>
 &lt;li>
 &lt;p>多协议发布&lt;/p>
 &lt;ul>
diff --git a/zh-cn/sitemap.xml b/zh-cn/sitemap.xml
index 664a6a9e93..bd0a162a8d 100644
--- a/zh-cn/sitemap.xml
+++ b/zh-cn/sitemap.xml
@@ -1 +1 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?><urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:xhtml="http://www.w3.org/1999/xhtml"><url><loc>https://cn.dubbo.apache.org/zh-cn/blog/2023/01/16/%E9%98%BF%E9%87%8C%E5%B7%B4%E5%B7%B4%E5%8D%87%E7%BA%A7-dubbo3-%E5%85%A8%E9%9D%A2%E5%8F%96%E4%BB%A3-hsf2/</loc><lastmod>2023-02-22T15:03:22+08:00</lastmod><changefreq>monthly</changefreq><priority>0.5</priority></url><url><loc>https://cn.dubbo.apache.org/zh-cn/overview/mannu [...]
\ No newline at end of file
+<?xml version="1.0" encoding="utf-8" standalone="yes"?><urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:xhtml="http://www.w3.org/1999/xhtml"><url><loc>https://cn.dubbo.apache.org/zh-cn/blog/2023/01/16/%E9%98%BF%E9%87%8C%E5%B7%B4%E5%B7%B4%E5%8D%87%E7%BA%A7-dubbo3-%E5%85%A8%E9%9D%A2%E5%8F%96%E4%BB%A3-hsf2/</loc><lastmod>2023-02-22T15:03:22+08:00</lastmod><changefreq>monthly</changefreq><priority>0.5</priority></url><url><loc>https://cn.dubbo.apache.org/zh-cn/overview/mannu [...]
\ No newline at end of file