code: private long getTimeoutMillis(String type, Duration timeout) {
      return timeout != null ? timeout.toMillis() : computeTimeoutMillis(type);
    }
docs: Returns the timeout in milliseconds for the given timeout duration
  
  @param type    the message type
  @param timeout the timeout duration or {@code null} if the timeout is dynamic
  @return the timeout in milliseconds