test_class.file: herd-code/herd-tools/herd-retention-expiration-destroyer/src/test/java/org/finra/herd/tools/retention/destroyer/RetentionExpirationDestroyerWebClientTest.java
test_class.identifier: RetentionExpirationDestroyerWebClientTest
test_class.superclass: extends AbstractRetentionExpirationDestroyerTest
test_case.body: @Test
      public void testDestroyBusinessObjectDataUseSsl() throws Exception
      {
          retentionExpirationDestroyerWebClient.getRegServerAccessParamsDto().setUseSsl(true);
          BusinessObjectDataKey businessObjectDataKey =
              new BusinessObjectDataKey("test", "test", "test", "test", 0, "test", Collections.singletonList("test"), 0);
          BusinessObjectData result = retentionExpirationDestroyerWebClient.destroyBusinessObjectData(businessObjectDataKey);
          assertNotNull(result);
      }
test_case.class_method_signature: RetentionExpirationDestroyerWebClientTest.testDestroyBusinessObjectDataUseSsl()
test_case.full_signature: @Test public void testDestroyBusinessObjectDataUseSsl()
test_case.identifier: testDestroyBusinessObjectDataUseSsl
test_case.invocations: setUseSsl getRegServerAccessParamsDto singletonList destroyBusinessObjectData assertNotNull
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testDestroyBusinessObjectDataUseSsl()
focal_class.declarator: LOGGER = LoggerFactory.getLogger(RetentionExpirationDestroyerWebClient.class)
focal_class.modifier: private static final
focal_class.original_string: private static final Logger LOGGER = LoggerFactory.getLogger(RetentionExpirationDestroyerWebClient.class);
focal_class.type: Logger
focal_class.var_name: LOGGER
focal_class.file: herd-code/herd-tools/herd-retention-expiration-destroyer/src/main/java/org/finra/herd/tools/retention/destroyer/RetentionExpirationDestroyerWebClient.java
focal_class.identifier: RetentionExpirationDestroyerWebClient
focal_class.class_method_signature: RetentionExpirationDestroyerWebClient.destroyBusinessObjectData(BusinessObjectDataKey businessObjectDataKey)
focal_class.full_signature: public BusinessObjectData destroyBusinessObjectData(BusinessObjectDataKey businessObjectDataKey)
focal_class.identifier: destroyBusinessObjectData
focal_class.modifiers: public
focal_class.parameters: (BusinessObjectDataKey businessObjectDataKey)
focal_class.return: BusinessObjectData
focal_class.signature: BusinessObjectData destroyBusinessObjectData(BusinessObjectDataKey businessObjectDataKey)
focal_class.class_method_signature: RetentionExpirationDestroyerWebClient.destroyBusinessObjectData(CloseableHttpResponse httpResponse)
focal_class.full_signature: private BusinessObjectData destroyBusinessObjectData(CloseableHttpResponse httpResponse)
focal_class.identifier: destroyBusinessObjectData
focal_class.modifiers: private
focal_class.parameters: (CloseableHttpResponse httpResponse)
focal_class.return: BusinessObjectData
focal_class.signature: BusinessObjectData destroyBusinessObjectData(CloseableHttpResponse httpResponse)
focal_class.superclass: extends DataBridgeWebClient
focal_method.body: public BusinessObjectData destroyBusinessObjectData(BusinessObjectDataKey businessObjectDataKey)
          throws IOException, JAXBException, URISyntaxException, NoSuchAlgorithmException, KeyStoreException, KeyManagementException
      {
          String uriPath = HERD_APP_REST_URI_PREFIX + "/businessObjectData/destroy" + "/namespaces/" + businessObjectDataKey.getNamespace() +
              "/businessObjectDefinitionNames/" + businessObjectDataKey.getBusinessObjectDefinitionName() + "/businessObjectFormatUsages/" +
              businessObjectDataKey.getBusinessObjectFormatUsage() + "/businessObjectFormatFileTypes/" + businessObjectDataKey.getBusinessObjectFormatFileType() +
              "/businessObjectFormatVersions/" + businessObjectDataKey.getBusinessObjectFormatVersion() + "/partitionValues/" +
              businessObjectDataKey.getPartitionValue() + "/businessObjectDataVersions/" + businessObjectDataKey.getBusinessObjectDataVersion();
  
          URIBuilder uriBuilder =
              new URIBuilder().setScheme(getUriScheme()).setHost(regServerAccessParamsDto.getRegServerHost()).setPort(regServerAccessParamsDto.getRegServerPort())
                  .setPath(uriPath);
  
          if (CollectionUtils.isNotEmpty(businessObjectDataKey.getSubPartitionValues()))
          {
              uriBuilder.setParameter("subPartitionValues", herdStringHelper.join(businessObjectDataKey.getSubPartitionValues(), "|", "\\"));
          }
  
          URI uri = uriBuilder.build();
  
          try (CloseableHttpClient client = httpClientHelper
              .createHttpClient(regServerAccessParamsDto.isTrustSelfSignedCertificate(), regServerAccessParamsDto.isDisableHostnameVerification()))
          {
              HttpPost request = new HttpPost(uri);
              request.addHeader("Content-Type", DEFAULT_CONTENT_TYPE);
              request.addHeader("Accepts", DEFAULT_ACCEPT);
  
              // If SSL is enabled, set the client authentication header.
              if (regServerAccessParamsDto.isUseSsl())
              {
                  request.addHeader(getAuthorizationHeader());
              }
  
              LOGGER.info(String.format("    HTTP POST URI: %s", request.getURI().toString()));
  
              BusinessObjectData businessObjectData = destroyBusinessObjectData(httpClientOperations.execute(client, request));
  
              LOGGER.info("Successfully destroyed business object data from the registration server.");
  
              return businessObjectData;
          }
      }
focal_method.class_method_signature: RetentionExpirationDestroyerWebClient.destroyBusinessObjectData(BusinessObjectDataKey businessObjectDataKey)
focal_method.full_signature: public BusinessObjectData destroyBusinessObjectData(BusinessObjectDataKey businessObjectDataKey)
focal_method.identifier: destroyBusinessObjectData
focal_method.invocations: getNamespace getBusinessObjectDefinitionName getBusinessObjectFormatUsage getBusinessObjectFormatFileType getBusinessObjectFormatVersion getPartitionValue getBusinessObjectDataVersion setPath setPort setHost setScheme getUriScheme getRegServerHost getRegServerPort isNotEmpty getSubPartitionValues setParameter join getSubPartitionValues build createHttpClient isTrustSelfSignedCertificate isDisableHostnameVerification addHeader addHeader isUseSsl addHeader getAuthorizationHeader info format toString getURI destroyBusinessObjectData execute info
focal_method.modifiers: public
focal_method.parameters: (BusinessObjectDataKey businessObjectDataKey)
focal_method.return: BusinessObjectData
focal_method.signature: BusinessObjectData destroyBusinessObjectData(BusinessObjectDataKey businessObjectDataKey)