Class AppConfigurationEndpoint

java.lang.Object
com.azure.spring.cloud.config.web.AppConfigurationEndpoint

public class AppConfigurationEndpoint extends Object
Common class for authenticating refresh requests.
  • Constructor Details

    • AppConfigurationEndpoint

      public AppConfigurationEndpoint(javax.servlet.http.HttpServletRequest request, List<ConfigStore> configStores, Map<String,String> allRequestParams) throws IOException
      Base Authentication for refresh endpoints.
      Parameters:
      request - Json body of the request
      configStores - List of all of the config stores that request could be for
      allRequestParams - paramaters to validate the request.
      Throws:
      IOException - Failed to read the Request body or parse it to json
      IllegalArgumentException - Request missing valid topic field.
  • Method Details

    • authenticate

      public boolean authenticate()
      Checks if the request is from a valid AppConfiguration Store and has a valid Token and Secret.
      Returns:
      true if a valid connection.
    • triggerRefresh

      public boolean triggerRefresh()
      Checks if the endpoint's store has been configured for refresh.
      Returns:
      true, if the configured endpoint has monitoring enabled.
    • getSyncToken

      public String getSyncToken()
      Returns the syncToken from the event grid request
      Returns:
      string value of sync token or null if it doesn't exist.
    • getValidationResponse

      public JsonNode getValidationResponse()
      Returns:
      the validationResponse
    • getEndpoint

      public String getEndpoint()
      Returns:
      the endpoint
    • getStore

      public String getStore()
      Returns:
      the store