Hey Steven,
First of all, apologies for a late response.
I reckon you're building gRPC from github then. If so, please ignore the 
last message.
To set a TOS value you can provide a custom dialer in the dial options 
using WithDIaler(). Now how you use this dialer to create a net.Conn object 
is entirely your discretion. At this point it's more about what golang than 
gRPC. The following link might help with setting socket options on the 
fd(both before and after calling Connect):  
http://stackoverflow.com/questions/40544096/how-to-set-socket-option-ip-tos-for-http-client-in-go-language

Best,
Mak

On Tuesday, March 7, 2017 at 8:19:41 PM UTC-8, Steven Jiang wrote:
>
> Client is also written in GO.  I can't access this DialConfig 
> https://cs.corp.google.com/piper///depot/google3/net/grpc/go/client.go?l=44. 
>  We are using GO 1.6.2 (grpcgo 1.0).  Do you mean it's not supported in GO 
> 1.6.2?
>
> Thanks
> Steven
>
> On Tuesday, March 7, 2017 at 4:10:39 PM UTC-8, [email protected] wrote:
>>
>> Which language is your client in?
>> We support setting GTOS values in google3. 
>> For golang this can be done via DialConfig 
>> https://cs.corp.google.com/piper///depot/google3/net/grpc/go/client.go?l=44
>>
>> On Friday, March 3, 2017 at 11:43:15 AM UTC-8, Steven Jiang wrote:
>>>
>>> Hi,
>>> I'd like to set TOS bits for a grpc client stream.  The stream is 
>>> created by calling grpc.Dial.  grpc.Dial calls net.DialTCP  -> dialTCP -> 
>>> internetSocket -> socket.  I don't find any chance to set TOS between fd 
>>> creation and fd.dial which calls connect().  I tried calling 
>>> SetsockoptInt to change TOS after socket get connected, but this change 
>>> was ignored by the socket.  TOS value remains 0 in the ip header. 
>>>
>>> Could anyone tell me how to set TOS bits for a grpc client stream? Is it 
>>> supported now?
>>>
>>>
>>> Thanks
>>> Steven
>>>
>>

-- 
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 post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/grpc-io.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/grpc-io/ce52b65f-c387-47ed-8ac5-b8fa2c7f7821%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to