You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@dubbo.apache.org by GitBox <gi...@apache.org> on 2022/12/05 09:18:22 UTC

[GitHub] [dubbo-js] songjiachao commented on a diff in pull request #324: megre dubbo-client invoker

songjiachao commented on code in PR #324:
URL: https://github.com/apache/dubbo-js/pull/324#discussion_r1039327505


##########
example/hello/hello-web/server.ts:
##########
@@ -0,0 +1,2 @@
+import { DubboClient } from '@apache/dubbo3-client'

Review Comment:
   consumer写的是:import { Dubbo } from 'dubbo3-client'
   server 这里写的是:import { DubboClient } from '@apache/dubbo3-client'
   
   是不是有一个不对呀



##########
example/hello/hello-web/consumer/index.ts:
##########
@@ -0,0 +1,27 @@
+import { Dubbo } from 'dubbo3-client'
+
+export interface IHelloService {
+  sayHello(
+    id:number,
+    name:string,
+    email:string,
+    password:string
+  ):Promise<string>
+
+  getUser(id:number):Promise<string>
+}
+
+export const HelloService = (b:Dubbo):IHelloService => {
+  b.proxyService({
+    name:'HelloService',
+    methods:{
+      sayHello( id:number, name:string,email:string, password:string){
+        return [id, name, email, password]

Review Comment:
   这里返回值类型是数组和上面定义的Promise<string>不对应吧
   



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org