Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
190 views
in Technique[技术] by (71.8m points)

Steeltoe Eureka with .Net Core gRPC

I registered my gRPC services into local Eureka Service registery with no problem. but I don know how to use it for clients that want to call these services. this is my code when I want to call gRPC service

        var config = new EurekaClientConfig
        {
            ShouldFetchRegistry = true,
            ShouldRegisterWithEureka = false,
            ValidateCertificates = false,
            EurekaServerServiceUrls = EurekaClientConfig.Default_ServerServiceUrl,
        };
        // this is where i don't know how to configure discovery client
        var client = new EurekaDiscoveryClient(null, null, null);

        var discoveryHandler = new DiscoveryHttpClientHandler(client);
        var channel = GrpcChannel.ForAddress("http://userservice/", new GrpcChannelOptions { HttpHandler = discoveryHandler });
question from:https://stackoverflow.com/questions/65679896/steeltoe-eureka-with-net-core-grpc

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...