Hi,
In the following code snippet:
InternalSubchannel.java the log message string is built even if it is not ultimately used.
The toString() method of ConnectivityStateInfo calls toString() on the Status object. If the Status contains an exception, its stack trace is computed via getStackTrace().
In our usage of gRPC—where we enforce retries to many servers, some of which may be down—this stack trace computation shows up in our profiler and accounts for a few percent of CPU usage.
Thank you,
Marc Guiot