Issue with Resolving Service Config from DNS using gRPC

48 views
Skip to first unread message

Gaby Banu

unread,
Jan 21, 2025, 9:57:28 AMJan 21
to grpc.io

Problem Description:

I am trying to configure the round_robin load balancing policy using a Service Config provided via DNS, as outlined in the A2-service-configs-in-dns.md. However, I do not observe any DNS TXT record queries in the client logs, and the load balancing policy remains set to pick_first.


Additional Details:

  1. Environment:
    • The gRPC client (grpc-c++/1.30.3 grpc-c/10.0.0 (linux; chttp2)) is configured with the following service URI:
<streaming-recognition service-uri="dns:///aiml-pool.dev.orange.intra:50051" />
  1. DNS Setup:
    • The DNS record is configured as follows:
$ nslookup -type=TXT _grpc_config.aiml-pool.dev.orange.intraServer:         62.217.251.212Address:        62.217.251.212#53 Non-authoritative answer:_grpc_config.aiml-pool.dev.orange.intra text = "grpc_config=[{\"serviceConfig\":{\"loadBalancingPolicy\":\"round_robin\",\"methodConfig\":[{\"name\":[{\"service\":\"VoicebotService\",\"method\":\"recognize\"}],\"waitForReady\":true}]}}]"
  1. Client Logs:
    • Enabling DEBUG level logs shows queries for A and AAAA records, but no queries for TXT records (entire log file is attached):
[DEBUG]  Load Streaming Recognition Attribute: service-uri = dns:///aiml-pool.dev.orange.intra:50051[DEBUG]  Using ares dns resolver[DEBUG] (c-ares resolver) request:0x7f6714037610 create_hostbyname_request_locked host:aiml-pool.dev.orange.intra port:33731 is_balancer:0 qtype:AAAA[DEBUG] (c-ares resolver) request:0x7f6714037610 create_hostbyname_request_locked host:aiml-pool.dev.orange.intra port:33731 is_balancer:0 qtype:A[DEBUG] (c-ares resolver) request:0x7f7bf8037610 on_hostbyname_done_locked qtype=A host=aiml-pool.dev.orange.intra ARES_SUCCESS[DEBUG] (c-ares resolver) request:0x7f7bf8037610 c-ares resolver gets a AF_INET result:[DEBUG] (c-ares resolver) request:0x7f7bf8037610 c-ares resolver gets a AF_INET result:[INFO]  [child_policy_handler 0x7f7bd4001ea0] created new LB policy "pick_first" (0x7f7bf80253f0)
  1. Expected Behavior:
    • The client should query the TXT record _grpc_config.aiml-pool.dev.orange.intra to retrieve the ServiceConfig and apply the round_robin policy.

Questions:

  1. Is there a specific configuration required to enable the client to query TXT records for the Service Config?
  2. Could there be a limitation or bug in the C gRPC client implementation that prevents it from querying TXT records?

Thank you for your assistance!

  

Best regards,

Gabriel Banu

Mark D. Roth

unread,
May 15, 2025, 6:05:53 PMMay 15
to Gaby Banu, grpc.io
I don't see any obvious problems with your setup.  However, the version of gRPC that you're using is extremely old -- version 1.30 was released in June 2020, almost 5 years ago.  Please try upgrading to a current version and see if that works.  If not, we can have a closer look.

--
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+u...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/grpc-io/c09b0708-0f0d-4eb0-b894-a0357a186f71n%40googlegroups.com.


--
Mark D. Roth <ro...@google.com>
Software Engineer
Google, Inc.
Reply all
Reply to author
Forward
0 new messages