its been a while since i looked at that code but it seems like a good place
for you to tinker with is in the section that defines async writers:


// write for single request, streaming response
template <class Reply>
using AsyncStreamingWriter = grpc::ServerAsyncWriter<Reply>;
// Writer for request/response one-shots
template <class Reply>
using AsyncStandardWriter = grpc::ServerAsyncResponseWriter<Reply>;




On Thu, Jul 1, 2021 at 8:16 PM Jeff Steger <[email protected]> wrote:

> I implemented a grpc async streaming server that processes single requests
> (ie the streaming is not bidirectional). But you should be able to modify
> it so that it can process streaming requests. Here she is:
>
> https://github.com/lbj137/repo1
>
>
> On Thu, Jul 1, 2021 at 3:45 PM Christopher Pisz <[email protected]>
> wrote:
>
>> Wait wait...you implemented a GRPC asynch bidirectional streaming server
>> in C++?
>> I've been looking for 6 months for one that actually works and doesn't
>> block. Can I see? Can I see?
>>
>> On Friday, June 18, 2021 at 10:07:45 AM UTC-4 [email protected] wrote:
>>
>>> Hi,
>>>
>>> We have a use-case where there is one async streaming server sending
>>> messages to multiple clients in round-robin fashion. The data is not always
>>> available and need to wait for the producer to generate data before it can
>>> be sent out.
>>>
>>> We followed the suggestions provided in the below article to overcome
>>> the behavior of task being added to the front of the completion queue and
>>> using alarms to wait for the producer -
>>>
>>>
>>> https://www.gresearch.co.uk/article/lessons-learnt-from-writing-asynchronous-streaming-grpc-services-in-c/
>>>
>>> However, the approach is not elegant and adds the overhead of alarm
>>> tasks. Is this the suggested approach for async streaming or is there an
>>> alternative that we are missing?
>>>
>>> Thanks in advance for your response.
>>>
>>>
>>> --
>> 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/660bd0bb-0991-4322-a679-0c1e5f522727n%40googlegroups.com
>> <https://groups.google.com/d/msgid/grpc-io/660bd0bb-0991-4322-a679-0c1e5f522727n%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>
>

-- 
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/CAA-WHuneVHWeERdtKvOy49Z8atTLRRBd_CV82LDOu_vXUB-5iw%40mail.gmail.com.

Reply via email to