com.gs.api.accelrx.web.client.AccelRxWebClientImpl Maven / Gradle / Ivy
package com.gs.api.accelrx.web.client;
import com.gs.api.accelrx.*;
import com.gs.api.accelrx.retry.RetryPolicyTransformers;
import com.gs.api.accelrx.web.client.response.AccelRxWebClientObservableResponse;
import com.gs.api.accelrx.web.client.response.AccelRxWebClientSingleResponse;
import com.gs.api.accelrx.web.client.validation.WebResponseValidation;
import dev.failsafe.RetryPolicy;
import dev.failsafe.RetryPolicyBuilder;
import io.reactivex.rxjava3.core.Completable;
import io.reactivex.rxjava3.core.Single;
import io.vertx.rxjava3.core.Vertx;
import io.vertx.rxjava3.core.http.HttpClient;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import java.time.Duration;
import java.time.temporal.ChronoUnit;
import java.util.function.Function;
public class AccelRxWebClientImpl implements AccelRxWebClient {
private static final Logger log = LoggerFactory.getLogger(AccelRxWebClientImpl.class);
private final Vertx vertx;
private final String serviceName;
private final APIContract apiContract;
private final AccelRxWebClientConfig webClientConfig;
private final AccelRxWebClientServiceDiscovery serviceDiscovery;
private final AccelRxWebClientSecurity webSecurity;
private final WebResponseValidation responseValidation;
private final AccelRxEncoding encoding;
private final VertxClientBuilder clientBuilder;
private final RetryPolicy> requestRetryPolicy;
private final RetryPolicyTransformers retryPolicyTransformers;
public AccelRxWebClientImpl(Vertx vertx,
String serviceName,
APIContract apiContract,
AccelRxWebClientConfig webClientConfig,
AccelRxWebClientServiceDiscovery serviceDiscovery,
VertxClientBuilder clientBuilder,
AccelRxEncoding encoding,
AccelRxWebClientSecurity webSecurity,
WebResponseValidation responseValidation) {
this.vertx = vertx;
this.serviceName = serviceName;
this.apiContract = apiContract;
this.webClientConfig = webClientConfig;
this.serviceDiscovery = serviceDiscovery;
this.webSecurity = webSecurity;
this.clientBuilder = clientBuilder;
this.responseValidation = responseValidation;
this.encoding = encoding;
RetryPolicyBuilder
© 2015 - 2025 Weber Informatics LLC | Privacy Policy