use of com.sequenceiq.common.api.cloudstorage.StorageIdentityBase in project cloudbreak by hortonworks.
the class StackToDescribeFreeIpaResponseConverter method decorateWithCloudStorageAndTelemetry.
private void decorateWithCloudStorageAndTelemetry(Stack stack, DescribeFreeIpaResponse response) {
TelemetryResponse telemetryResponse = telemetryConverter.convert(stack.getTelemetry());
if (telemetryResponse != null) {
response.setTelemetry(telemetryResponse);
if (telemetryResponse.getLogging() != null) {
CloudStorageResponse cloudStorageResponse = new CloudStorageResponse();
List<StorageIdentityBase> identities = new ArrayList<>();
StorageIdentityBase logIdentity = new StorageIdentityBase();
logIdentity.setType(CloudIdentityType.LOG);
identities.add(logIdentity);
cloudStorageResponse.setIdentities(identities);
response.setCloudStorage(cloudStorageResponse);
}
}
}
use of com.sequenceiq.common.api.cloudstorage.StorageIdentityBase in project cloudbreak by hortonworks.
the class AzureAdlsGen2Tests method adlsGen2CloudStorageV4RequestWithoutStorageLocations.
private CloudStorageRequest adlsGen2CloudStorageV4RequestWithoutStorageLocations() {
CloudStorageRequest request = new CloudStorageRequest();
AdlsGen2CloudStorageV1Parameters adlsGen2 = new AdlsGen2CloudStorageV1Parameters();
String accountName = azureProperties.getCloudStorage().getAccountName();
String accountKey = azureProperties.getCloudStorage().getAccountKey();
adlsGen2.setAccountKey(accountKey);
adlsGen2.setAccountName(accountName);
StorageLocationBase storageLocationBase = new StorageLocationBase();
storageLocationBase.setType(CloudStorageCdpService.RANGER_AUDIT);
storageLocationBase.setValue("somePath");
request.setLocations(List.of(storageLocationBase));
StorageIdentityBase storageIdentityBase = new StorageIdentityBase();
storageIdentityBase.setAdlsGen2(adlsGen2);
request.setIdentities(List.of(storageIdentityBase));
return request;
}
Aggregations