Skip to content

Commit

Permalink
core: updated the variable name and logger message
Browse files Browse the repository at this point in the history
  • Loading branch information
vinodhabib committed Feb 25, 2025
1 parent 140e2f1 commit c9ee995
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions core/src/main/java/io/grpc/internal/ManagedChannelImpl.java
Original file line number Diff line number Diff line change
Expand Up @@ -936,11 +936,11 @@ public void run() {
}

// Must run in SynchronizationContext.
void updateConfigSelector(@Nullable InternalConfigSelector config) {
void updateConfigSelector(@Nullable InternalConfigSelector currentConfig) {
InternalConfigSelector prevConfig = configSelector.get();
configSelector.set(config);
configSelector.set(currentConfig);
channelLogger.log(ChannelLogLevel.INFO,
"Current service config is replaced", prevConfig, config);
"Previous service config updated to current", prevConfig, currentConfig);
if (prevConfig == INITIAL_PENDING_SELECTOR && pendingCalls != null) {
for (RealChannel.PendingCall<?, ?> pendingCall : pendingCalls) {
pendingCall.reprocess();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3377,7 +3377,7 @@ public void channelTracing_serviceConfigChange() throws Exception {
assertThat(getStats(channel).channelTrace.events).hasSize(prevSize + 2);
assertThat(getStats(channel).channelTrace.events.get(prevSize))
.isEqualTo(new ChannelTrace.Event.Builder()
.setDescription("Current service config is replaced")
.setDescription("Previous service config updated to current")
.setSeverity(ChannelTrace.Event.Severity.CT_INFO)
.setTimestampNanos(timer.getTicker().read())
.build());
Expand All @@ -3404,7 +3404,7 @@ public void channelTracing_serviceConfigChange() throws Exception {
assertThat(getStats(channel).channelTrace.events).hasSize(prevSize + 2);
assertThat(getStats(channel).channelTrace.events.get(prevSize))
.isEqualTo(new ChannelTrace.Event.Builder()
.setDescription("Current service config is replaced")
.setDescription("Previous service config updated to current")
.setSeverity(ChannelTrace.Event.Severity.CT_INFO)
.setTimestampNanos(timer.getTicker().read())
.build());
Expand Down Expand Up @@ -3438,7 +3438,7 @@ public void channelTracing_serviceConfigChange_usesListener2OnResult2() throws E
assertThat(getStats(channel).channelTrace.events).hasSize(prevSize + 2);
assertThat(getStats(channel).channelTrace.events.get(prevSize))
.isEqualTo(new ChannelTrace.Event.Builder()
.setDescription("Current service config is replaced")
.setDescription("Previous service config updated to current")
.setSeverity(ChannelTrace.Event.Severity.CT_INFO)
.setTimestampNanos(timer.getTicker().read())
.build());
Expand Down Expand Up @@ -3467,7 +3467,7 @@ public void channelTracing_serviceConfigChange_usesListener2OnResult2() throws E
assertThat(getStats(channel).channelTrace.events).hasSize(prevSize + 2);
assertThat(getStats(channel).channelTrace.events.get(prevSize))
.isEqualTo(new ChannelTrace.Event.Builder()
.setDescription("Current service config is replaced")
.setDescription("Previous service config updated to current")
.setSeverity(ChannelTrace.Event.Severity.CT_INFO)
.setTimestampNanos(timer.getTicker().read())
.build());
Expand Down

0 comments on commit c9ee995

Please sign in to comment.