test_class.file: herd-code/herd-tools/herd-downloader/src/test/java/org/finra/herd/tools/downloader/DownloaderWebClientTest.java
test_class.identifier: DownloaderWebClientTest
test_class.superclass: extends AbstractDownloaderTest
test_case.body: @Test
      public void testGetS3KeyPrefix() throws Exception
      {
          // Upload and register business object data parents.
          uploadAndRegisterTestDataParents(downloaderWebClient);
  
          // Upload and register the initial version if of the test business object data.
          uploadTestDataFilesToS3(S3_TEST_PATH_V0);
          final UploaderInputManifestDto uploaderInputManifestDto = getTestUploaderInputManifestDto();
  
          executeWithoutLogging(DataBridgeWebClient.class, new Command()
          {
              @Override
              public void execute() throws Exception
              {
                  BusinessObjectData businessObjectData =
                      downloaderWebClient.preRegisterBusinessObjectData(uploaderInputManifestDto, StorageEntity.MANAGED_STORAGE, false);
                  BusinessObjectDataKey businessObjectDataKey = businessObjectDataHelper.getBusinessObjectDataKey(businessObjectData);
                  downloaderWebClient
                      .addStorageFiles(businessObjectDataKey, uploaderInputManifestDto, getTestS3FileTransferRequestParamsDto(S3_TEST_PATH_V0 + "/"),
                          StorageEntity.MANAGED_STORAGE);
                  downloaderWebClient.updateBusinessObjectDataStatus(businessObjectDataKey, BusinessObjectDataStatusEntity.VALID);
              }
          });
  
          // Get S3 key prefix.
          BusinessObjectData businessObjectData = toBusinessObjectData(uploaderInputManifestDto);
          S3KeyPrefixInformation resultS3KeyPrefixInformation = downloaderWebClient.getS3KeyPrefix(businessObjectData);
  
          // Validate the results.
          assertNotNull(resultS3KeyPrefixInformation);
          assertEquals(S3_SIMPLE_TEST_PATH, resultS3KeyPrefixInformation.getS3KeyPrefix());
      }
test_case.class_method_signature: DownloaderWebClientTest.testGetS3KeyPrefix()
test_case.full_signature: @Test public void testGetS3KeyPrefix()
test_case.identifier: testGetS3KeyPrefix
test_case.invocations: uploadAndRegisterTestDataParents uploadTestDataFilesToS3 getTestUploaderInputManifestDto executeWithoutLogging preRegisterBusinessObjectData getBusinessObjectDataKey addStorageFiles getTestS3FileTransferRequestParamsDto updateBusinessObjectDataStatus toBusinessObjectData getS3KeyPrefix assertNotNull assertEquals getS3KeyPrefix
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testGetS3KeyPrefix()
focal_class.declarator: LOGGER = LoggerFactory.getLogger(DownloaderWebClient.class)
focal_class.modifier: private static final
focal_class.original_string: private static final Logger LOGGER = LoggerFactory.getLogger(DownloaderWebClient.class);
focal_class.type: Logger
focal_class.var_name: LOGGER
focal_class.file: herd-code/herd-tools/herd-downloader/src/main/java/org/finra/herd/tools/downloader/DownloaderWebClient.java
focal_class.identifier: DownloaderWebClient
focal_class.class_method_signature: DownloaderWebClient.getBusinessObjectData(DownloaderInputManifestDto manifest)
focal_class.full_signature: public BusinessObjectData getBusinessObjectData(DownloaderInputManifestDto manifest)
focal_class.identifier: getBusinessObjectData
focal_class.modifiers: public
focal_class.parameters: (DownloaderInputManifestDto manifest)
focal_class.return: BusinessObjectData
focal_class.signature: BusinessObjectData getBusinessObjectData(DownloaderInputManifestDto manifest)
focal_class.class_method_signature: DownloaderWebClient.getS3KeyPrefix(BusinessObjectData businessObjectData)
focal_class.full_signature: public S3KeyPrefixInformation getS3KeyPrefix(BusinessObjectData businessObjectData)
focal_class.identifier: getS3KeyPrefix
focal_class.modifiers: public
focal_class.parameters: (BusinessObjectData businessObjectData)
focal_class.return: S3KeyPrefixInformation
focal_class.signature: S3KeyPrefixInformation getS3KeyPrefix(BusinessObjectData businessObjectData)
focal_class.class_method_signature: DownloaderWebClient.getStorageUnitDownloadCredential(DownloaderInputManifestDto manifest, String storageName)
focal_class.full_signature: public StorageUnitDownloadCredential getStorageUnitDownloadCredential(DownloaderInputManifestDto manifest, String storageName)
focal_class.identifier: getStorageUnitDownloadCredential
focal_class.modifiers: public
focal_class.parameters: (DownloaderInputManifestDto manifest, String storageName)
focal_class.return: StorageUnitDownloadCredential
focal_class.signature: StorageUnitDownloadCredential getStorageUnitDownloadCredential(DownloaderInputManifestDto manifest, String storageName)
focal_class.class_method_signature: DownloaderWebClient.getStorageUnitDownloadCredential(CloseableHttpResponse response)
focal_class.full_signature: private StorageUnitDownloadCredential getStorageUnitDownloadCredential(CloseableHttpResponse response)
focal_class.identifier: getStorageUnitDownloadCredential
focal_class.modifiers: private
focal_class.parameters: (CloseableHttpResponse response)
focal_class.return: StorageUnitDownloadCredential
focal_class.signature: StorageUnitDownloadCredential getStorageUnitDownloadCredential(CloseableHttpResponse response)
focal_class.superclass: extends DataBridgeWebClient
focal_method.body: public S3KeyPrefixInformation getS3KeyPrefix(BusinessObjectData businessObjectData)
          throws IOException, JAXBException, URISyntaxException, NoSuchAlgorithmException, KeyStoreException, KeyManagementException
      {
          DataBridgeBaseManifestDto dataBridgeBaseManifestDto = new DataBridgeBaseManifestDto();
          dataBridgeBaseManifestDto.setNamespace(businessObjectData.getNamespace());
          dataBridgeBaseManifestDto.setBusinessObjectDefinitionName(businessObjectData.getBusinessObjectDefinitionName());
          dataBridgeBaseManifestDto.setBusinessObjectFormatUsage(businessObjectData.getBusinessObjectFormatUsage());
          dataBridgeBaseManifestDto.setBusinessObjectFormatFileType(businessObjectData.getBusinessObjectFormatFileType());
          dataBridgeBaseManifestDto.setBusinessObjectFormatVersion(String.valueOf(businessObjectData.getBusinessObjectFormatVersion()));
          dataBridgeBaseManifestDto.setPartitionKey(businessObjectData.getPartitionKey());
          dataBridgeBaseManifestDto.setPartitionValue(businessObjectData.getPartitionValue());
          dataBridgeBaseManifestDto.setSubPartitionValues(businessObjectData.getSubPartitionValues());
          dataBridgeBaseManifestDto.setStorageName(businessObjectData.getStorageUnits().get(0).getStorage().getName());
          return super.getS3KeyPrefix(dataBridgeBaseManifestDto, businessObjectData.getVersion(), Boolean.FALSE);
      }
focal_method.class_method_signature: DownloaderWebClient.getS3KeyPrefix(BusinessObjectData businessObjectData)
focal_method.full_signature: public S3KeyPrefixInformation getS3KeyPrefix(BusinessObjectData businessObjectData)
focal_method.identifier: getS3KeyPrefix
focal_method.invocations: setNamespace getNamespace setBusinessObjectDefinitionName getBusinessObjectDefinitionName setBusinessObjectFormatUsage getBusinessObjectFormatUsage setBusinessObjectFormatFileType getBusinessObjectFormatFileType setBusinessObjectFormatVersion valueOf getBusinessObjectFormatVersion setPartitionKey getPartitionKey setPartitionValue getPartitionValue setSubPartitionValues getSubPartitionValues setStorageName getName getStorage get getStorageUnits getS3KeyPrefix getVersion
focal_method.modifiers: public
focal_method.parameters: (BusinessObjectData businessObjectData)
focal_method.return: S3KeyPrefixInformation
focal_method.signature: S3KeyPrefixInformation getS3KeyPrefix(BusinessObjectData businessObjectData)