-
Notifications
You must be signed in to change notification settings - Fork 160
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remaining documents #395
base: dubbo3
Are you sure you want to change the base?
Remaining documents #395
Conversation
Quality Gate passedIssues Measures |
@@ -1 +1,71 @@ | |||
# Choosing a protocol | |||
|
|||
In addition to the Dubbo protocol, Dubbo ships with support for the gRPC-web protocol. If your backend does not support the Dubbo protocol, you can still use Dubbo clients to interface with it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps the Triple protocol is more relevant to the context
@@ -1,2 +1,125 @@ | |||
# Generating code | |||
# todo | |||
|
|||
We mentioned earlier that the ELIZA service defines a Protocol Buffer schema. So what *is* that schema? It is really just a simple file that describes the service, its methods, and their argument and return types: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is This is an unnecessary format
} | ||
``` | ||
|
||
You can see the full version including comments and some additional RPCs [on the Buf Schema Registry](https://buf.build/connectrpc/eliza/file/main:connectrpc/eliza/v1/eliza.proto) (BSR). The `rpc` keyword stands for Remote Procedure Call — a method you can invoke remotely. The schema is the contract between server and client, and it precisely defines how data is exchanged down to the very details of serialization. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Modify link
|
||
In addition to the Dubbo protocol, Dubbo ships with support for the gRPC-web protocol. If your backend does not support the Dubbo protocol, you can still use Dubbo clients to interface with it. | ||
|
||
## Connect |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Triple
import { MethodKind } from "@bufbuild/protobuf"; | ||
|
||
export const ElizaService = { | ||
typeName: "buf.connect.demo.eliza.v1.ElizaService", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need to modify
}); | ||
}; | ||
|
||
const client = createPromiseClient(ElizaService, createConnectTransport({ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not createConnectTransport
|
||
```ts | ||
import { createPromiseClient } from "@apachedubbo/dubbo"; | ||
import { ElizaService } from "../gen/buf/connect/demo/eliza/v1/eliza_dubbo.js"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need to modify
|
||
```ts | ||
import { createCallbackClient } from "@apachedubbo/dubbo"; | ||
import { ElizaService } from "../gen/buf/connect/demo/eliza/v1/eliza_dubbo.js"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need to modify
}); | ||
``` | ||
|
||
The callback client is particularly useful if you want to migrate an existing code base from gRPC-web to Connect clients. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Connect -> connect
Pull the latest code, CI has been fixed |
No description provided.