Search in sources :

Example 1 with ServiceClientRetryFilter

use of com.emc.storageos.security.helpers.ServiceClientRetryFilter in project coprhd-controller by CoprHD.

the class GeoClientCacheManager method createClient.

private GeoServiceClient createClient(VirtualDataCenter vdc) {
    GeoServiceClient client = new GeoServiceClient();
    client.setCoordinatorClient(coordinatorClient);
    client.setServer(vdc.getApiEndpoint());
    client.setSecretKey(vdc.getSecretKey());
    // set both timeout values to 30s due to CTRL-2779
    client.setClientConnectTimeout(_clientConnTimeout);
    client.setClientReadTimeout(_clientReadTimeout);
    client.addFilter(new ServiceClientRetryFilter(client.getClientMaxRetries(), client.getClientRetryInterval()));
    client.addFilter(new GeoServiceExceptionFilter());
    return client;
}
Also used : ServiceClientRetryFilter(com.emc.storageos.security.helpers.ServiceClientRetryFilter)

Example 2 with ServiceClientRetryFilter

use of com.emc.storageos.security.helpers.ServiceClientRetryFilter in project coprhd-controller by CoprHD.

the class GeoClientCacheManager method createClient.

private GeoServiceClient createClient(Properties vdcInfo) {
    GeoServiceClient client = new GeoServiceClient();
    client.setCoordinatorClient(coordinatorClient);
    client.setServer(vdcInfo.getProperty(GeoServiceJob.VDC_API_ENDPOINT));
    client.setSecretKey(vdcInfo.getProperty(GeoServiceJob.VDC_SECRETE_KEY));
    // set both timeout values to 30s due to CTRL-2779
    client.setClientConnectTimeout(_clientConnTimeout);
    client.setClientReadTimeout(_clientReadTimeout);
    client.addFilter(new ServiceClientRetryFilter(client.getClientMaxRetries(), client.getClientRetryInterval()));
    client.addFilter(new GeoServiceExceptionFilter());
    return client;
}
Also used : ServiceClientRetryFilter(com.emc.storageos.security.helpers.ServiceClientRetryFilter)

Example 3 with ServiceClientRetryFilter

use of com.emc.storageos.security.helpers.ServiceClientRetryFilter in project coprhd-controller by CoprHD.

the class GeoTest method setup.

@Before
public void setup() throws Exception {
    setupHttpsResources();
    geoClient = new GeoServiceClient();
    geoClient.setServer(server);
    geoClient.setCoordinatorClient(coordinatorClient);
    geoClient.addFilter(new ServiceClientRetryFilter(geoClient.getClientMaxRetries(), geoClient.getClientRetryInterval()));
    geoClient.addFilter(new GeoServiceExceptionFilter());
    // prepare test data
    createVirtualArrays();
    createVirtualPools();
}
Also used : ServiceClientRetryFilter(com.emc.storageos.security.helpers.ServiceClientRetryFilter) GeoServiceExceptionFilter(com.emc.storageos.security.geo.GeoServiceExceptionFilter) GeoServiceClient(com.emc.storageos.security.geo.GeoServiceClient) Before(org.junit.Before)

Aggregations

ServiceClientRetryFilter (com.emc.storageos.security.helpers.ServiceClientRetryFilter)3 GeoServiceClient (com.emc.storageos.security.geo.GeoServiceClient)1 GeoServiceExceptionFilter (com.emc.storageos.security.geo.GeoServiceExceptionFilter)1 Before (org.junit.Before)1