Package io.grpc.netty
Class NettyServer.ListenSocket
- java.lang.Object
-
- io.grpc.netty.NettyServer.ListenSocket
-
- All Implemented Interfaces:
InternalInstrumented<InternalChannelz.SocketStats>
,InternalWithLogId
- Enclosing class:
- NettyServer
private static final class NettyServer.ListenSocket extends java.lang.Object implements InternalInstrumented<InternalChannelz.SocketStats>
A class that can answer channelz queries about the server listen sockets.
-
-
Field Summary
Fields Modifier and Type Field Description private io.netty.channel.Channel
ch
private InternalLogId
id
-
Constructor Summary
Constructors Constructor Description ListenSocket(io.netty.channel.Channel ch)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description InternalLogId
getLogId()
Returns an ID that is primarily used in debug logs.com.google.common.util.concurrent.ListenableFuture<InternalChannelz.SocketStats>
getStats()
Returns the stats object.java.lang.String
toString()
-
-
-
Field Detail
-
id
private final InternalLogId id
-
ch
private final io.netty.channel.Channel ch
-
-
Method Detail
-
getStats
public com.google.common.util.concurrent.ListenableFuture<InternalChannelz.SocketStats> getStats()
Description copied from interface:InternalInstrumented
Returns the stats object.- Specified by:
getStats
in interfaceInternalInstrumented<InternalChannelz.SocketStats>
-
getLogId
public InternalLogId getLogId()
Description copied from interface:InternalWithLogId
Returns an ID that is primarily used in debug logs. It usually contains the class name and a numeric ID that is unique among the instances.The subclasses of this interface usually want to include the log ID in their
Object.toString()
results.- Specified by:
getLogId
in interfaceInternalWithLogId
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-