public NettyRequestReplySpec()

in statefun-flink/statefun-flink-core/src/main/java/org/apache/flink/statefun/flink/core/nettyclient/NettyRequestReplySpec.java [67:101]


  public NettyRequestReplySpec(
      @JsonProperty(CALL_TIMEOUT_PROPERTY) Duration callTimeout,
      @JsonProperty(CONNECT_TIMEOUT_PROPERTY) Duration connectTimeout,
      @JsonProperty(POOLED_CONNECTION_TTL_PROPERTY) Duration pooledConnectionTTL,
      @JsonProperty(CONNECTION_POOL_MAX_SIZE_PROPERTY) Integer connectionPoolMaxSize,
      @JsonProperty(MAX_REQUEST_OR_RESPONSE_SIZE_IN_BYTES_PROPERTY)
          Integer maxRequestOrResponseSizeInBytes,
      @JsonProperty(TRUST_CA_CERTS_PROPERTY) String trustedCaCerts,
      @JsonProperty(CLIENT_CERT_PROPERTY) String clientCerts,
      @JsonProperty(CLIENT_KEY_PROPERTY) String clientKey,
      @JsonProperty(CLIENT_KEY_PASSWORD_PROPERTY) String clientKeyPassword,
      @JsonProperty(TIMEOUTS_PROPERTY) Timeouts timeouts) {
    this.trustedCaCerts = trustedCaCerts;
    this.clientCerts = clientCerts;
    this.clientKey = clientKey;
    this.clientKeyPassword = clientKeyPassword;
    this.callTimeout =
        firstPresentOrDefault(
            ofNullable(timeouts).map(Timeouts::getCallTimeout),
            ofNullable(callTimeout),
            () -> DEFAULT_CALL_TIMEOUT);

    this.connectTimeout =
        firstPresentOrDefault(
            ofNullable(timeouts).map(Timeouts::getConnectTimeout),
            ofNullable(connectTimeout),
            () -> DEFAULT_CONNECT_TIMEOUT);
    this.pooledConnectionTTL =
        ofNullable(pooledConnectionTTL).orElse(DEFAULT_POOLED_CONNECTION_TTL);
    this.connectionPoolMaxSize =
        ofNullable(connectionPoolMaxSize).orElse(DEFAULT_CONNECTION_POOL_MAX_SIZE);
    this.maxRequestOrResponseSizeInBytes =
        ofNullable(maxRequestOrResponseSizeInBytes)
            .orElse(DEFAULT_MAX_REQUEST_OR_RESPONSE_SIZE_IN_BYTES);
  }