Class RestTemplateWrapper

java.lang.Object
de.hybris.platform.kymaintegrationservices.utils.RestTemplateWrapper

public class RestTemplateWrapper extends Object
Wrapper for RestTemplate to handle ssl connections
  • Constructor Details

    • RestTemplateWrapper

      public RestTemplateWrapper()
  • Method Details

    • getUpdatedRestTemplate

      @Deprecated(since="1905", forRemoval=true) public org.springframework.web.client.RestTemplate getUpdatedRestTemplate()
      Deprecated, for removal: This API element is subject to removal in a future version.
      since 1905 This method returns the first RestTemplate from the restTemplateFactorycache, if no RestTemplate found then a new RestTemplate Object will be returned.
    • getRestTemplate

      public org.springframework.web.client.RestTemplate getRestTemplate(AbstractCredentialModel abstractCredentialModel) throws CredentialException
      Throws:
      CredentialException
    • updateCredentials

      @Deprecated(since="1905", forRemoval=true) public void updateCredentials(AbstractDestinationModel destination) throws CredentialException
      Deprecated, for removal: This API element is subject to removal in a future version.
      since 1905 Use the protected version of this method("updateCredential") instead.
      Throws:
      CredentialException
    • updateCredential

      protected void updateCredential(AbstractCredentialModel credential) throws CredentialException
      Throws:
      CredentialException
    • invalidateAndUpdateCache

      public void invalidateAndUpdateCache(ConsumedCertificateCredentialModel certificateCredential)
    • invalidateTheCache

      public void invalidateTheCache(String credentialId)
    • updateRequestFactory

      protected void updateRequestFactory(ConsumedCertificateCredentialModel credential) throws CredentialException
      Throws:
      CredentialException
    • getRestTemplate

      @Deprecated(since="1905", forRemoval=true) protected org.springframework.web.client.RestTemplate getRestTemplate()
      Deprecated, for removal: This API element is subject to removal in a future version.
      since 1905 This method returns the first RestTemplate from the restTemplateFactorycache, if no RestTemplate found then a new RestTemplate Object will be returned.
      Throws:
      CredentialException
    • getKeepAlive

      protected int getKeepAlive()
    • setRestTemplate

      @Deprecated(since="1905", forRemoval=true) public void setRestTemplate(org.springframework.web.client.RestTemplate restTemplate)
      Deprecated, for removal: This API element is subject to removal in a future version.
      since 1905 This method practically does nothing as it is not following the caching concept while storing the RestTemplate for the given credentials. It is there only for the backward compatibility.
    • getDestinationService

      protected DestinationService<AbstractDestinationModel> getDestinationService()
    • setDestinationService

      public void setDestinationService(DestinationService<AbstractDestinationModel> destinationService)
    • validateCredential

      @Deprecated(since="1905", forRemoval=true) protected void validateCredential(AbstractDestinationModel destination) throws CredentialException
      Deprecated, for removal: This API element is subject to removal in a future version.
      since 1905 This method has been replaced by validateCredential(AbstractCredentialModel) for convention.
      Throws:
      CredentialException
    • validateCredential

      protected void validateCredential(AbstractCredentialModel credential) throws CredentialException
      Throws:
      CredentialException
    • getTimeout

      protected int getTimeout()
    • setTimeout

      public void setTimeout(int timeout)
    • setMessageConverters

      public void setMessageConverters(List<org.springframework.http.converter.HttpMessageConverter<Object>> messageConverters)
    • getMessageConverters

      protected List<org.springframework.http.converter.HttpMessageConverter<Object>> getMessageConverters()
    • getSslContextFactoryService

      protected SSLContextFactoryService getSslContextFactoryService()
    • setSslContextFactoryService

      public void setSslContextFactoryService(SSLContextFactoryService sslContextFactoryService)