Hi everyone! I'm looking to implement a long-living server stream with gRPC that clients can subscribe to.
Context: there is a group of users with users and a lead user, when the lead starts and action
performAction()
which is a unary RPC. I want to notify the other users with information about that action. I would expect those members to be subscribed to another long-living RPC that facilitates sending that information.
Do you have any examples of how can achieve that in Kotlin? I was looking into something like:
https://dev.bitolog.com/grpc-long-lived-streaming/https://sultanov.dev/blog/grpc-long-lived-streaming-using-observer-pattern/
But those implementations are written in Go and Java, and I'm struggling to find examples in Kotlin
🆘 1
😶 2
t
Tjerk Wolterink
01/27/2023, 8:28 AM
Just implement grpc. Not need todo anything special to make it long lived. Just use a grpc channel. Should work