[grpc-io] Re: gRPCLB in gRPC Java 1.14

2018-10-17 Thread 'blazej.mro...@gmail.com' via grpc.io

On Tuesday, 31 July 2018 20:30:41 UTC+2, Carl Mastrangelo wrote:

> There will be upcoming documentation on the exact way to configure this, 
> but this is being announced here for interested parties to try it out and 
> answer any questions.
>
(...) and there currently isn't a load reporter.  I am considering showing 
> how to make a simple one, but there isn't an off the shelf version for use 
> yet.
>

Hi, I have a question: could you estimate (more\less) when those things are 
likely to happen? I mean more documentation on grpclb and ideas about load 
reporter.
I'm not asking about a specific date, only if it possible to be e.g. next 
1-2 months or rather it will be a year?

-- 
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 grpc-io+unsubscr...@googlegroups.com.
To post to this group, send email to grpc-io@googlegroups.com.
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/4f705eb8-5778-4cf2-805d-4cb09c890d8e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[grpc-io] Re: gRPCLB in gRPC Java 1.14

2018-09-06 Thread Lisandro Diaz
Thanks Carl!

On Thursday, September 6, 2018 at 3:55:32 PM UTC-4, Carl Mastrangelo wrote:
>
> It should be sufficient to have GrpclbLoadBalancerFactory in the 
> classpath.  You can set it explicitly if you would like.
>
>
> As for the endpoint, The load balancer and the load report are separate 
> pieces.  The load balancer it the proto service that your client connects 
> to and asks for server addresses and weights.  The load reporter service 
> connects to your servers and asks them how loaded or alive they are.  Only 
> the load balancer api was part of this release, and there currently isn't a 
> load reporter.  I am considering showing how to make a simple one, but 
> there isn't an off the shelf version for use yet.   
>
> On Thursday, September 6, 2018 at 8:15:28 AM UTC-7, Lisandro Diaz wrote:
>>
>> Do i need to create my own loadbalancer or can i use the RoundRobin 
>>
>>> NettyChannelBuilder.forTarget(rpcTarget)
>>> .loadBalancerFactory(RoundRobinLoadBalancerFactory.getInstance())
>>> .nameResolverFactory(DnsNameResolverProvider.asFactory())
>>> .negotiationType(NegotiationType.valueOf(rpcNegotiationType))
>>> .build();
>>>
>>>
>> or do i need to use .loadBalancerFactory(GrpclbLoadBalancerFactory.
>> getInstance())
>>
>> Also the proto defined in grpclb is this meant to be served up by the 
>> loadbalancer (i.e: HAProxy) ? Which means i have to expose a grpc endpoint 
>> on HAProxy to reply with stats?
>>
>> On Tuesday, July 31, 2018 at 2:30:41 PM UTC-4, Carl Mastrangelo wrote:
>>>
>>> In release 1.14, it is now possible to use gPRC LB, gRPC's full featured 
>>> load balancer client.  This is an experimental feature that contacts a gRPC 
>>> LB server to get load balancing data.  
>>>
>>> To get started, you will need to set the JVM flag 
>>> "-Dio.grpc.internal.DnsNameResolverProvider.enable_grpclb=true", and 
>>> include the grpc-grpclb artifact on your class path.  This enables using 
>>> DNS SRV records to point to gRPCLB servers when doing load balancing.  
>>>
>>> The DNS entries need to be in a specific format to be usable.   For a 
>>> service called "api.service.com", It should look something like this:
>>>
>>> A api.service.com - 127.0.0.1
>>>  api.service.com - ::1
>>> SRV _grpclb._tcp.api.service.com - lb.service.com
>>> A  lb.service.com - 192.168.0.1
>>>
>>>
>>> gRPC will check for an SRV record with the prefix "_grpclb._tcp"   on 
>>> the target you provide to the channel.  If present, gRPC will use the 
>>> addresses of THAT domain as balancer addresses.  In LB parlance, 
>>> lb.service.com is a *balancer* address, while api.service.com is a 
>>> *backend* address.   Balanacer addresses must speak the gRPCLB protocol (as 
>>> defined in the proto).
>>>
>>> There will be upcoming documentation on the exact way to configure this, 
>>> but this is being announced here for interested parties to try it out and 
>>> answer any questions.
>>>
>>

-- 
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 grpc-io+unsubscr...@googlegroups.com.
To post to this group, send email to grpc-io@googlegroups.com.
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/69440f45-f578-4829-a3a6-c0f872ec5d7c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[grpc-io] Re: gRPCLB in gRPC Java 1.14

2018-09-06 Thread 'Carl Mastrangelo' via grpc.io
It should be sufficient to have GrpclbLoadBalancerFactory in the 
classpath.  You can set it explicitly if you would like.


As for the endpoint, The load balancer and the load report are separate 
pieces.  The load balancer it the proto service that your client connects 
to and asks for server addresses and weights.  The load reporter service 
connects to your servers and asks them how loaded or alive they are.  Only 
the load balancer api was part of this release, and there currently isn't a 
load reporter.  I am considering showing how to make a simple one, but 
there isn't an off the shelf version for use yet.   

On Thursday, September 6, 2018 at 8:15:28 AM UTC-7, Lisandro Diaz wrote:
>
> Do i need to create my own loadbalancer or can i use the RoundRobin 
>
>> NettyChannelBuilder.forTarget(rpcTarget)
>> .loadBalancerFactory(RoundRobinLoadBalancerFactory.getInstance())
>> .nameResolverFactory(DnsNameResolverProvider.asFactory())
>> .negotiationType(NegotiationType.valueOf(rpcNegotiationType))
>> .build();
>>
>>
> or do i need to use .loadBalancerFactory(GrpclbLoadBalancerFactory.
> getInstance())
>
> Also the proto defined in grpclb is this meant to be served up by the 
> loadbalancer (i.e: HAProxy) ? Which means i have to expose a grpc endpoint 
> on HAProxy to reply with stats?
>
> On Tuesday, July 31, 2018 at 2:30:41 PM UTC-4, Carl Mastrangelo wrote:
>>
>> In release 1.14, it is now possible to use gPRC LB, gRPC's full featured 
>> load balancer client.  This is an experimental feature that contacts a gRPC 
>> LB server to get load balancing data.  
>>
>> To get started, you will need to set the JVM flag 
>> "-Dio.grpc.internal.DnsNameResolverProvider.enable_grpclb=true", and 
>> include the grpc-grpclb artifact on your class path.  This enables using 
>> DNS SRV records to point to gRPCLB servers when doing load balancing.  
>>
>> The DNS entries need to be in a specific format to be usable.   For a 
>> service called "api.service.com", It should look something like this:
>>
>> A api.service.com - 127.0.0.1
>>  api.service.com - ::1
>> SRV _grpclb._tcp.api.service.com - lb.service.com
>> A  lb.service.com - 192.168.0.1
>>
>>
>> gRPC will check for an SRV record with the prefix "_grpclb._tcp"   on the 
>> target you provide to the channel.  If present, gRPC will use the addresses 
>> of THAT domain as balancer addresses.  In LB parlance, lb.service.com is 
>> a *balancer* address, while api.service.com is a *backend* address.  
>>  Balanacer addresses must speak the gRPCLB protocol (as defined in the 
>> proto).
>>
>> There will be upcoming documentation on the exact way to configure this, 
>> but this is being announced here for interested parties to try it out and 
>> answer any questions.
>>
>

-- 
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 grpc-io+unsubscr...@googlegroups.com.
To post to this group, send email to grpc-io@googlegroups.com.
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/b16f72cc-47d2-4c31-b6e5-ac039eca0658%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[grpc-io] Re: gRPCLB in gRPC Java 1.14

2018-09-06 Thread Lisandro Diaz
Do i need to create my own loadbalancer or can i use the RoundRobin 

> NettyChannelBuilder.forTarget(rpcTarget)
> .loadBalancerFactory(RoundRobinLoadBalancerFactory.getInstance())
> .nameResolverFactory(DnsNameResolverProvider.asFactory())
> .negotiationType(NegotiationType.valueOf(rpcNegotiationType))
> .build();
>
>
or do i need to use .loadBalancerFactory(GrpclbLoadBalancerFactory.
getInstance())

Also the proto defined in grpclb is this meant to be served up by the 
loadbalancer (i.e: HAProxy) ? Which means i have to expose a grpc endpoint 
on HAProxy to reply with stats?

On Tuesday, July 31, 2018 at 2:30:41 PM UTC-4, Carl Mastrangelo wrote:
>
> In release 1.14, it is now possible to use gPRC LB, gRPC's full featured 
> load balancer client.  This is an experimental feature that contacts a gRPC 
> LB server to get load balancing data.  
>
> To get started, you will need to set the JVM flag 
> "-Dio.grpc.internal.DnsNameResolverProvider.enable_grpclb=true", and 
> include the grpc-grpclb artifact on your class path.  This enables using 
> DNS SRV records to point to gRPCLB servers when doing load balancing.  
>
> The DNS entries need to be in a specific format to be usable.   For a 
> service called "api.service.com", It should look something like this:
>
> A api.service.com - 127.0.0.1
>  api.service.com - ::1
> SRV _grpclb._tcp.api.service.com - lb.service.com
> A  lb.service.com - 192.168.0.1
>
>
> gRPC will check for an SRV record with the prefix "_grpclb._tcp"   on the 
> target you provide to the channel.  If present, gRPC will use the addresses 
> of THAT domain as balancer addresses.  In LB parlance, lb.service.com is 
> a *balancer* address, while api.service.com is a *backend* address.  
>  Balanacer addresses must speak the gRPCLB protocol (as defined in the 
> proto).
>
> There will be upcoming documentation on the exact way to configure this, 
> but this is being announced here for interested parties to try it out and 
> answer any questions.
>

-- 
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 grpc-io+unsubscr...@googlegroups.com.
To post to this group, send email to grpc-io@googlegroups.com.
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/526f4711-bf24-467e-b0a2-253df1c8e8d9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[grpc-io] Re: gRPCLB in gRPC Java 1.14

2018-08-17 Thread eleanore . jin
Thanks a lot for the clarification

On Friday, August 17, 2018 at 12:29:15 PM UTC-7, Carl Mastrangelo wrote:
>
> Yes, that is correct.   Load Balancing is done on a per-call basis.  Once 
> an RPC has been assigned to a backend, it will continue on that backend.
>
> On Friday, August 17, 2018 at 9:20:02 AM UTC-7, eleano...@gmail.com wrote:
>>
>> Hi, 
>>
>> I just wonder how does gRPC LB handles the bi-directional stream? Once it 
>> picks which server instance to serve the streaming request, then it will 
>> continue the streaming request only with that particular server?
>>
>> On Tuesday, July 31, 2018 at 11:30:41 AM UTC-7, Carl Mastrangelo wrote:
>>>
>>> In release 1.14, it is now possible to use gPRC LB, gRPC's full featured 
>>> load balancer client.  This is an experimental feature that contacts a gRPC 
>>> LB server to get load balancing data.  
>>>
>>> To get started, you will need to set the JVM flag 
>>> "-Dio.grpc.internal.DnsNameResolverProvider.enable_grpclb=true", and 
>>> include the grpc-grpclb artifact on your class path.  This enables using 
>>> DNS SRV records to point to gRPCLB servers when doing load balancing.  
>>>
>>> The DNS entries need to be in a specific format to be usable.   For a 
>>> service called "api.service.com", It should look something like this:
>>>
>>> A api.service.com - 127.0.0.1
>>>  api.service.com - ::1
>>> SRV _grpclb._tcp.api.service.com - lb.service.com
>>> A  lb.service.com - 192.168.0.1
>>>
>>>
>>> gRPC will check for an SRV record with the prefix "_grpclb._tcp"   on 
>>> the target you provide to the channel.  If present, gRPC will use the 
>>> addresses of THAT domain as balancer addresses.  In LB parlance, 
>>> lb.service.com is a *balancer* address, while api.service.com is a 
>>> *backend* address.   Balanacer addresses must speak the gRPCLB protocol (as 
>>> defined in the proto).
>>>
>>> There will be upcoming documentation on the exact way to configure this, 
>>> but this is being announced here for interested parties to try it out and 
>>> answer any questions.
>>>
>>

-- 
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 grpc-io+unsubscr...@googlegroups.com.
To post to this group, send email to grpc-io@googlegroups.com.
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/38bf8f7e-55d7-49af-94f1-4c7ee9131d50%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[grpc-io] Re: gRPCLB in gRPC Java 1.14

2018-08-17 Thread 'Carl Mastrangelo' via grpc.io
Yes, that is correct.   Load Balancing is done on a per-call basis.  Once 
an RPC has been assigned to a backend, it will continue on that backend.

On Friday, August 17, 2018 at 9:20:02 AM UTC-7, eleano...@gmail.com wrote:
>
> Hi, 
>
> I just wonder how does gRPC LB handles the bi-directional stream? Once it 
> picks which server instance to serve the streaming request, then it will 
> continue the streaming request only with that particular server?
>
> On Tuesday, July 31, 2018 at 11:30:41 AM UTC-7, Carl Mastrangelo wrote:
>>
>> In release 1.14, it is now possible to use gPRC LB, gRPC's full featured 
>> load balancer client.  This is an experimental feature that contacts a gRPC 
>> LB server to get load balancing data.  
>>
>> To get started, you will need to set the JVM flag 
>> "-Dio.grpc.internal.DnsNameResolverProvider.enable_grpclb=true", and 
>> include the grpc-grpclb artifact on your class path.  This enables using 
>> DNS SRV records to point to gRPCLB servers when doing load balancing.  
>>
>> The DNS entries need to be in a specific format to be usable.   For a 
>> service called "api.service.com", It should look something like this:
>>
>> A api.service.com - 127.0.0.1
>>  api.service.com - ::1
>> SRV _grpclb._tcp.api.service.com - lb.service.com
>> A  lb.service.com - 192.168.0.1
>>
>>
>> gRPC will check for an SRV record with the prefix "_grpclb._tcp"   on the 
>> target you provide to the channel.  If present, gRPC will use the addresses 
>> of THAT domain as balancer addresses.  In LB parlance, lb.service.com is 
>> a *balancer* address, while api.service.com is a *backend* address.  
>>  Balanacer addresses must speak the gRPCLB protocol (as defined in the 
>> proto).
>>
>> There will be upcoming documentation on the exact way to configure this, 
>> but this is being announced here for interested parties to try it out and 
>> answer any questions.
>>
>

-- 
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 grpc-io+unsubscr...@googlegroups.com.
To post to this group, send email to grpc-io@googlegroups.com.
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/e5b9cb1f-f280-4c3a-8fd2-47bd0e05c7c9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[grpc-io] Re: gRPCLB in gRPC Java 1.14

2018-08-17 Thread eleanore . jin
Hi, 

I just wonder how does gRPC LB handles the bi-directional stream? Once it 
picks which server instance to serve the streaming request, then it will 
continue the streaming request only with that particular server?

On Tuesday, July 31, 2018 at 11:30:41 AM UTC-7, Carl Mastrangelo wrote:
>
> In release 1.14, it is now possible to use gPRC LB, gRPC's full featured 
> load balancer client.  This is an experimental feature that contacts a gRPC 
> LB server to get load balancing data.  
>
> To get started, you will need to set the JVM flag 
> "-Dio.grpc.internal.DnsNameResolverProvider.enable_grpclb=true", and 
> include the grpc-grpclb artifact on your class path.  This enables using 
> DNS SRV records to point to gRPCLB servers when doing load balancing.  
>
> The DNS entries need to be in a specific format to be usable.   For a 
> service called "api.service.com", It should look something like this:
>
> A api.service.com - 127.0.0.1
>  api.service.com - ::1
> SRV _grpclb._tcp.api.service.com - lb.service.com
> A  lb.service.com - 192.168.0.1
>
>
> gRPC will check for an SRV record with the prefix "_grpclb._tcp"   on the 
> target you provide to the channel.  If present, gRPC will use the addresses 
> of THAT domain as balancer addresses.  In LB parlance, lb.service.com is 
> a *balancer* address, while api.service.com is a *backend* address.  
>  Balanacer addresses must speak the gRPCLB protocol (as defined in the 
> proto).
>
> There will be upcoming documentation on the exact way to configure this, 
> but this is being announced here for interested parties to try it out and 
> answer any questions.
>

-- 
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 grpc-io+unsubscr...@googlegroups.com.
To post to this group, send email to grpc-io@googlegroups.com.
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/1f66b078-fb95-46dd-bbb0-bbaad8cceb2b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.