This is an automated email from the ASF dual-hosted git repository.
oxsean pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/dubbo-website.git
The following commit(s) were added to refs/heads/master by this push:
new ebbcf9ef430 Update tripe-rest-manual.md (#3117)
ebbcf9ef430 is described below
commit ebbcf9ef4304721303e280181382558c1e43b38a
Author: stellar <[email protected]>
AuthorDate: Thu May 15 17:34:18 2025 +0800
Update tripe-rest-manual.md (#3117)
fix wrong method
---
.../mannual/java-sdk/reference-manual/protocol/tripe-rest-manual.md | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git
a/content/zh-cn/overview/mannual/java-sdk/reference-manual/protocol/tripe-rest-manual.md
b/content/zh-cn/overview/mannual/java-sdk/reference-manual/protocol/tripe-rest-manual.md
index db1bca0760a..a00af8f62a1 100644
---
a/content/zh-cn/overview/mannual/java-sdk/reference-manual/protocol/tripe-rest-manual.md
+++
b/content/zh-cn/overview/mannual/java-sdk/reference-manual/protocol/tripe-rest-manual.md
@@ -316,10 +316,10 @@ DEBUG .d.r.h.AbstractServerHttpChannelObserver : [DUBBO]
Http response headers
```java
// Dubbo http req/resp
HttpRequest request =
RpcContext.getServiceContext().getRequest(HttpRequest.class);
-HttpResponse response =
RpcContext.getServiceContext().getRequest(HttpResponse.class);
+HttpResponse response =
RpcContext.getServiceContext().getResponse(HttpResponse.class);
// Servlet http req/resp
HttpServletRequest request =
RpcContext.getServiceContext().getRequest(HttpServletRequest.class);
-HttpServletResponse response =
RpcContext.getServiceContext().getRequest(HttpServletResponse.class);
+HttpServletResponse response =
RpcContext.getServiceContext().getResponse(HttpServletResponse.class);
```
拿到request之后,通过 attribute
@@ -449,7 +449,7 @@ toPayload();
- 获取 HttpResponse 后自定义,实例代码:
```java
-HttpResponse response =
RpcContext.getServiceContext().getRequest(HttpResponse.class);
+HttpResponse response =
RpcContext.getServiceContext().getResponse(HttpResponse.class);
response.