in flink-connector-rabbitmq/src/main/java/org/apache/flink/streaming/connectors/rabbitmq/common/RMQConnectionConfig.java [85:123]
private RMQConnectionConfig(
String host,
Integer port,
String virtualHost,
String username,
String password,
Integer networkRecoveryInterval,
Boolean automaticRecovery,
Boolean topologyRecovery,
Integer connectionTimeout,
Integer requestedChannelMax,
Integer requestedFrameMax,
Integer requestedHeartbeat,
Integer prefetchCount,
Long deliveryTimeout) {
Preconditions.checkNotNull(host, "host can not be null");
Preconditions.checkNotNull(port, "port can not be null");
Preconditions.checkNotNull(virtualHost, "virtualHost can not be null");
Preconditions.checkNotNull(username, "username can not be null");
Preconditions.checkNotNull(password, "password can not be null");
Preconditions.checkArgument(
deliveryTimeout == null || deliveryTimeout > 0, "deliveryTimeout must be positive");
this.host = host;
this.port = port;
this.virtualHost = virtualHost;
this.username = username;
this.password = password;
this.networkRecoveryInterval = networkRecoveryInterval;
this.automaticRecovery = automaticRecovery;
this.topologyRecovery = topologyRecovery;
this.connectionTimeout = connectionTimeout;
this.requestedChannelMax = requestedChannelMax;
this.requestedFrameMax = requestedFrameMax;
this.requestedHeartbeat = requestedHeartbeat;
this.prefetchCount = prefetchCount;
this.deliveryTimeout =
Optional.ofNullable(deliveryTimeout).orElse(DEFAULT_DELIVERY_TIMEOUT);
}