RPC Type: Server Streaming. Explanation: Client will do registration request to server for Notification, And server will send notification in streaming response as and when notification data is available. So Notification data might be available at random intervals, When data is available we can call Write(), but when data not available what to do? I got an idea of using Alarm in this case, when data is not available to write, then put the task back to CQ using Alarm.Set. So its working fine as expected. But the problem here is, when Server is shutdown, all outstanding RPC calls in CQ returns with ok as false, hence cleared corresponding resources are deallocated. but Alarm will return false when alarm is cancelled, or true when alarm is expired. Then how will application knows that server is shutdown and hence the streaming RPC needs to be gracefully closed by server?
Problem: When Server shutdown happens, application is indefinitely blocking in shutdown itself, since Stream RPC has not been closed yet? -- You received this message because you are subscribed to the Google Groups "grpc.io" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/grpc-io/e98b2cd9-5e6a-4512-9f34-10bc77c948b9o%40googlegroups.com.
