@Test public void createClient_withNoProxy_shouldUseObjectStorageClientConstructor() throws Exception { setUpStubForCreateAuthenticator(); setUpObjectStorageClientBuilder(); whenNew(ObjectStorageClient.class).withAnyArguments().thenReturn(mockObjectStorageClient); final ObjectStorage client = factoryUnderTest.createClient(mockPropAccessor); assertEquals("ObjectStorage should be equal", mockObjectStorageClient, client); verifyNew(ObjectStorageClient.class) .withArguments( isA(BasicAuthenticationDetailsProvider.class), isA(ClientConfiguration.class)); }
@VisibleForTesting ObjectStorage createClient(final BmcPropertyAccessor propertyAccessor) { final String customObjectStoreClient = propertyAccessor.asString().get(BmcProperties.OBJECT_STORE_CLIENT_CLASS); final ObjectStorage objectStorage = (customObjectStoreClient != null) ? (ObjectStorage) this.createClass(customObjectStoreClient) : buildClient(propertyAccessor); final String endpoint = propertyAccessor.asString().get(BmcProperties.HOST_NAME); LOG.info("Using endpoint {}", endpoint); objectStorage.setEndpoint(endpoint); return objectStorage; }
BmcDataStoreFactory { @VisibleForTesting ObjectStorage createClient(final BmcPropertyAccessor propertyAccessor) { final String customObjectStoreClient = propertyAccessor.asString().get(BmcProperties.OBJECT_STORE_CLIENT_CLASS); final ObjectStorage objectStorage = (customObjectStoreClient != null) ? (ObjectStorage) this.createClass(customObjectStoreClient) : buildClient(propertyAccessor); final String endpoint = propertyAccessor.asString().get(BmcProperties.HOST_NAME); LOG.info("Using endpoint {}", endpoint); objectStorage.setEndpoint(endpoint); return objectStorage; } }
BmcDataStoreFactory { @VisibleForTesting ObjectStorage createClient(final BmcPropertyAccessor propertyAccessor) { final String customObjectStoreClient = propertyAccessor.asString().get(BmcProperties.OBJECT_STORE_CLIENT_CLASS); final ObjectStorage objectStorage = (customObjectStoreClient != null) ? (ObjectStorage) this.createClass(customObjectStoreClient) : buildClient(propertyAccessor); final String endpoint = propertyAccessor.asString().get(BmcProperties.HOST_NAME); LOG.info("Using endpoint {}", endpoint); objectStorage.setEndpoint(endpoint); return objectStorage; }  }
BmcDataStoreFactory { @VisibleForTesting ObjectStorage createClient(final BmcPropertyAccessor propertyAccessor) { final String customObjectStoreClient = propertyAccessor.asString().get(BmcProperties.OBJECT_STORE_CLIENT_CLASS); final ObjectStorage objectStorage = (customObjectStoreClient != null) ? (ObjectStorage) this.createClass(customObjectStoreClient) : buildClient(propertyAccessor); final String endpoint = propertyAccessor.asString().get(BmcProperties.HOST_NAME); LOG.info("Using endpoint {}", endpoint); objectStorage.setEndpoint(endpoint); return objectStorage; }  BmcDataStore createDataStore(
            final String namespace, final String bucket, final Statistics statistics); }
BmcDataStoreFactory { @VisibleForTesting ObjectStorage createClient(final BmcPropertyAccessor propertyAccessor) { final String customObjectStoreClient = propertyAccessor.asString().get(BmcProperties.OBJECT_STORE_CLIENT_CLASS); final ObjectStorage objectStorage = (customObjectStoreClient != null) ? (ObjectStorage) this.createClass(customObjectStoreClient) : buildClient(propertyAccessor); final String endpoint = propertyAccessor.asString().get(BmcProperties.HOST_NAME); LOG.info("Using endpoint {}", endpoint); objectStorage.setEndpoint(endpoint); return objectStorage; }  BmcDataStore createDataStore(
            final String namespace, final String bucket, final Statistics statistics);  }