Closed akoserwal closed 1 week ago
http client is not supported yet. #1958 #2896
HTTP has not yet thought of a good abstraction to implement one-way and two-way stream
That's true. Is it possible to handle the stream case like: grpc-gatewat https://grpc-ecosystem.github.io/grpc-gateway/docs/mapping/httpbody_messages/ ?
That's true. Is it possible to handle the stream case like: grpc-gatewat https://grpc-ecosystem.github.io/grpc-gateway/docs/mapping/httpbody_messages/ ?
I need some time to study it
Example project to showcase adding an HTTP handler for the gRPC stream endpoint: https://github.com/akoserwal/stream-ex-kratos/blob/main/internal/server/http.go#L40 @shenqidebaozi
@akoserwal Let me take a look
What happened:
Running kratos proto client api/helloworld/demo.proto
doesn't generate only _grpc.pb.go
_http.pb.go
What you expected to happen:
generate HTTP and grpc client
How to reproduce it (as minimally and precisely as possible):
Add
stream
responseAnything else we need to know?:
Environment:
kratos -v
): kratos version v2.7.3go version
): go version go1.22.3cat /etc/os-release
): darwin/arm64