You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[Question]
Hi, I've previously implemented pbgrpc.CentrifugoProxyServer with GRPC protobuf for (i) SubscribeUnidirectional and (ii) SubscribeBidirectional. However, recently I would want to consider migrating to ConnectRPC because:
most of our other API endpoints are using ConnectRPC
I would want to leverage on our internal authentication / authorization envoys on ConnectRPC, so that the streaming can be intercepted with proper auth control
I see that centrifugo/proxyproto connectrpc generated protobufs are available on https://buf.build/centrifugo/proxyproto/sdks, hence I was experimenting on it and migrated the streaming server to use ConnectRPC instead of GRPC. After re-deploying both centrifugo service and our streaming server, I just realised that only GRPC endpoints are supported. I would want to check if ConnectRPC proxy streaming will be supported soon? Or currently is there any way to implement this on ConnectRPC?
...
[Example]
After implementing our streaming server to use ConnectRPC with proper configuration to the connectrpc HTTP endpoints, the centrifugo service will have these errors:
{"level":"fatal","time":"2024-10-11T07:39:28Z","message":"error creating subscribe stream proxy stream_logs_pod only GRPC endpoints supported"}
Please let me know if any other details needed, thanks in advanced for your help!
The text was updated successfully, but these errors were encountered:
Centrifugo does not integrate with ConnectRPC now, we have Protobuf definitions in Buf registry only to provide an access to generated Protobuf structures from different languages without the need to generate them manually - which was requested recently by some Centrifugo user.
So you can expect any kind of issues with ConnectRPC at this point.
And while we have our own support for both HTTP/GRPC interfaces for most methods of Centrifugo server API and Centrifugo proxy API, SubscribeUnidirectional/SubscribeBidirectional only work over GRPC at this point.
At the same time, I'd really would like to integrate with ConnectRPC for Centrifugo server API and event proxy functionalities. We are actually very close to ConnectRPC protocol now - supporting native GRPC, but have custom HTTP which re-uses Protobuf schema (so we generally do what Buf ConnectRPC does, but we have our own implementation started before ConnectRPC existed and become popular).
I am not sure about all the gotchas in such integration at this point. Generally, Centrifugo should be very close to work with ConnectRPC, but:
we have custom Raw type which represents bytes or json.RawMessage in GRPC or HTTP contexts - this may be the complexity
for bidirectional streaming in HTTP case the connection between Centrifugo and the backend must be HTTP/2 - it may add some configuration overhead.
we do not use the same HTTP paths ConnectRPC uses - this does not seem a big deal to support both though
probably a mismatch/difficulty in how Centrifugo proxies original connection headers in proxy events
At some point I may take a look whether it's viable to integrate fully with ConnectRPC, any help will be appreciated in this.
Thanks for the prompt response and clarifications. I've understood about the constraints currently and will be using gRPC directly for the time being. Since I'm still pretty new to Centrifugo, I'll try to spend more time and understand more about Centrifugo first, and see what I can do regarding contributing to the integration of Centrifugo with ConnectRPC in the future.
[Question]
Hi, I've previously implemented pbgrpc.CentrifugoProxyServer with GRPC protobuf for (i) SubscribeUnidirectional and (ii) SubscribeBidirectional. However, recently I would want to consider migrating to ConnectRPC because:
I see that centrifugo/proxyproto connectrpc generated protobufs are available on https://buf.build/centrifugo/proxyproto/sdks, hence I was experimenting on it and migrated the streaming server to use ConnectRPC instead of GRPC. After re-deploying both centrifugo service and our streaming server, I just realised that only GRPC endpoints are supported. I would want to check if ConnectRPC proxy streaming will be supported soon? Or currently is there any way to implement this on ConnectRPC?
...
[Example]
After implementing our streaming server to use ConnectRPC with proper configuration to the connectrpc HTTP endpoints, the centrifugo service will have these errors:
Please let me know if any other details needed, thanks in advanced for your help!
The text was updated successfully, but these errors were encountered: