aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/lib/channel/channelz_registry.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/lib/channel/channelz_registry.h')
-rw-r--r--src/core/lib/channel/channelz_registry.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/core/lib/channel/channelz_registry.h b/src/core/lib/channel/channelz_registry.h
index 326f0201c7..73b330785d 100644
--- a/src/core/lib/channel/channelz_registry.h
+++ b/src/core/lib/channel/channelz_registry.h
@@ -62,6 +62,10 @@ class ChannelzRegistry {
return Default()->InternalGetServers(start_server_id);
}
+ // Test only helper function to dump the JSON representation to std out.
+ // This can aid in debugging channelz code.
+ static void LogAllEntities() { Default()->InternalLogAllEntities(); }
+
private:
GPRC_ALLOW_CLASS_TO_USE_NON_PUBLIC_NEW
GPRC_ALLOW_CLASS_TO_USE_NON_PUBLIC_DELETE
@@ -96,6 +100,8 @@ class ChannelzRegistry {
// Else, will return idx of the first uuid higher than the target.
int FindByUuidLocked(intptr_t uuid, bool direct_hit_needed);
+ void InternalLogAllEntities();
+
// protects members
gpr_mu mu_;
InlinedVector<BaseNode*, 20> entities_;