> on how this works in C++ (how do you actually read this file so that the 
gRPC service applies the configurations), 

Check this 
out https://github.com/grpc/proposal/blob/master/A2-service-configs-in-dns.md

> *a single service where different PRCs have varying authentication 
requirements,*

Do you really mean authentication requirements or authorization 
requirements? Can you give a concrete use-case? Authentication is at 
connection level and then you can use gRPC Authorization API 
(https://github.com/grpc/proposal/blob/master/A43-grpc-authorization-api.md)

On Saturday, July 23, 2022 at 12:59:54 PM UTC+5:30 Philipp T wrote:

> Hello, Im pretty new to gRPC but I was wondering if the following is 
> possible
>
> I have a proto file which contains a single service with two RPCs which 
> looks as follows:
>
> *service MyService {*
> *    // This function requires credentials*
> *    rpc YouNeedCreds(Empty) returns (Empty) {}*
>
> *    // This function should be callable by anyone without credentials*
> *    rpc NoCredentialsNeeded(Empty) returns (Empty) {}*
> *}*
>
> *My question is, is it possible, using C++ to have a single service where 
> different PRCs have varying authentication requirements, without having to 
> deploy to something like google cloud (I just want to run it between 2 
> computers on the same network)? *
>
> I have seen references to using .yaml files to configure services (like 
> this one 
> <https://cloud.google.com/endpoints/docs/grpc/grpc-service-config#rules_and_selectors>),
>  
> but I have not found any examples on how this works in C++ (how do you 
> actually read this file so that the gRPC service applies the 
> configurations), and I don't intend on deploying this on google cloud. I 
> just want to run this on my local network and use the device IP to connect 
> to the service. 
>
> At the moment I create the server by creating using 
> grpc::SslSecureCredentials and passing them to the .AddListeningPort method 
> provided by the grpc::ServerBuilder.
>
> Hopefully this is somewhat helpful, thanks in advanced for.
>

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/grpc-io/0cbaf664-1648-449b-93ae-6ef2263569fdn%40googlegroups.com.

Reply via email to