docs: static InternalChannelz.SocketOptions getSocketOptions(Socket socket) {
      InternalChannelz.SocketOptions.Builder builder = new InternalChannelz.SocketOptions.Builder();
      try {
        builder.setSocketOptionLingerSeconds(socket.getSoLinger());
      } catch (SocketException e) {
        log.log(Level.SEVERE, "Exception caught while reading socket option", e);
        builder.addOption("SO_LINGER", "channelz_internal_error");
      }
  
      try {
        builder.setSocketOptionTimeoutMillis(socket.getSoTimeout());
      } catch (Exception e) {
        log.log(Level.SEVERE, "Exception caught while reading socket option", e);
        builder.addOption("SO_TIMEOUT", "channelz_internal_error");
      }
  
      try {
        builder.addOption("TCP_NODELAY", socket.getTcpNoDelay());
      } catch (SocketException e) {
        log.log(Level.SEVERE, "Exception caught while reading socket option", e);
        builder.addOption("TCP_NODELAY", "channelz_internal_error");
      }
  
      try {
        builder.addOption("SO_REUSEADDR", socket.getReuseAddress());
      } catch (SocketException e) {
        log.log(Level.SEVERE, "Exception caught while reading socket option", e);
        builder.addOption("SO_REUSEADDR", "channelz_internal_error");
      }
  
      try {
        builder.addOption("SO_SNDBUF", socket.getSendBufferSize());
      } catch (SocketException e) {
        log.log(Level.SEVERE, "Exception caught while reading socket option", e);
        builder.addOption("SO_SNDBUF", "channelz_internal_error");
      }
  
      try {
        builder.addOption("SO_RECVBUF", socket.getReceiveBufferSize());
      } catch (SocketException e) {
        log.log(Level.SEVERE, "Exception caught while reading socket option", e);
        builder.addOption("SO_RECVBUF", "channelz_internal_error");
      }
  
      try {
        builder.addOption("SO_KEEPALIVE", socket.getKeepAlive());
      } catch (SocketException e) {
        log.log(Level.SEVERE, "Exception caught while reading socket option", e);
        builder.addOption("SO_KEEPALIVE", "channelz_internal_error");
      }
  
      try {
        builder.addOption("SO_OOBINLINE", socket.getOOBInline());
      } catch (SocketException e) {
        log.log(Level.SEVERE, "Exception caught while reading socket option", e);
        builder.addOption("SO_OOBINLINE", "channelz_internal_error");
      }
  
      try {
        builder.addOption("IP_TOS", socket.getTrafficClass());
      } catch (SocketException e) {
        log.log(Level.SEVERE, "Exception caught while reading socket option", e);
        builder.addOption("IP_TOS", "channelz_internal_error");
      }
      return builder.build();
    }