-
Notifications
You must be signed in to change notification settings - Fork 818
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
Feature Proposal: UnknownMethodHandler for KitexThrift/KitexProtobuf requests #1321
Labels
help wanted
Extra attention is needed
Comments
@Zzhiter Do note that there's no way to force the client to use the same idl as the server. Say the svr has only one method |
@Zzhiter With this feature, a normal server shall be able to not only handle requests to its known methods, but also handle requests to unknown methods as the generic server way. |
3 tasks
lokistars
added a commit
to lokistars/kitex
that referenced
this issue
Aug 19, 2024
3 tasks
lokistars
added a commit
to lokistars/kitex
that referenced
this issue
Aug 19, 2024
lokistars
added a commit
to lokistars/kitex
that referenced
this issue
Aug 19, 2024
lokistars
added a commit
to lokistars/kitex
that referenced
this issue
Aug 19, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
A normal Kitex server is based on the IDL generated code, responsible for decoding requests into the go struct for the method handler. If a request with a method name not defined in its IDL is sent to this server, it will simply complain "unknown method" and refuse to process it.
Kitex also provides the "binary generic server" way, which takes in a request payload as a binary slice and sends it to the generic method handler, regardless of the method requested.
The problem is, these two types of server can not both exist within one server.
In this proposal, we sugguest an
UnknownMethodHandler
mechanism for a normal Kitex server to deal with requests with unknown methods.If you are interested in implementing this feature, please reply with your lark id, and kindly prepare for a detailed tech plan.
Note: this might not be easy for a new Kitex contributor.
The text was updated successfully, but these errors were encountered: