core: Use lazy message formatting in checkState (#12144)

This commit is contained in:
MV Shiva 2025-06-13 12:30:13 +05:30 committed by GitHub
parent 6f69363d90
commit 26bd0eee47
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -346,7 +346,7 @@ final class InternalSubchannel implements InternalInstrumented<ChannelStats>, Tr
if (state.getState() != newState.getState()) {
Preconditions.checkState(state.getState() != SHUTDOWN,
"Cannot transition out of SHUTDOWN to " + newState);
"Cannot transition out of SHUTDOWN to %s", newState.getState());
if (reconnectDisabled && newState.getState() == TRANSIENT_FAILURE) {
state = ConnectivityStateInfo.forNonError(IDLE);
} else {