JavaScript is disabled on your browser.
Skip navigation links

AWS SDK for Java 1.x API Reference - 1.12.793

We announced the upcoming end-of-support for AWS SDK for Java (v1). We recommend that you migrate to AWS SDK for Java v2. For dates, additional details, and information on how to migrate, please refer to the linked announcement.
  • Summary:
  • Nested |
  • Field |
  • Constr |
  • Method
  • Detail:
  • Field |
  • Constr |
  • Method
com.amazonaws.handlers

Interface IRequestHandler2

    • Method Detail

      • beforeExecution

        AmazonWebServiceRequest beforeExecution(AmazonWebServiceRequest request)
        Runs any additional processing logic on the specified request object as soon as the request is provided to the service client.

        This request handler is excluded from the client execution time metrics and is run on the application's thread, even for asynchronous requests.

        Warning: Modifications to this message will leak out to the user, who might reuse the request object without realizing that it was modified as part of sending it the first time. For this reason, we recommend that you only modify the request in the beforeRequest(Request) method. If you require data that is not available in that method, you should create a AmazonWebServiceRequest.clone() of the request (which performs a deep copy of the handler context map), add any context data you require in the beforeRequest(Request) method using AmazonWebServiceRequest.addHandlerContext(HandlerContextKey, Object), and return your cloned message from this method. You can then extract that data for use in the request using HandlerContextAware.getHandlerContext(HandlerContextKey).

        Parameters:
        request - the request passed in by the user
        Returns:
        the (possibly different) request to execute
      • beforeRequest

        void beforeRequest(Request<?> request)
        Runs any additional processing logic on the specified request (before it is executed by the client runtime).
        Parameters:
        request - The low level request being processed.
      • beforeAttempt

        void beforeAttempt(HandlerBeforeAttemptContext context)
        Runs any additional processing logic on a request before each individual attempt is made.
        Parameters:
        context - container for callback-related data; includes the request
      • beforeUnmarshalling

        HttpResponse beforeUnmarshalling(Request<?> request,
         HttpResponse httpResponse)
        Runs any additional processing logic on the specified response before it's unmarshalled. This callback is only invoked on successful responses that will be unmarshalled into an appropriate modeled class and not for unsuccessful responses that will be unmarshalled into a subclass of AmazonServiceException
        Parameters:
        request - The low level request being processed.
        httpResponse - The Raw HTTP response before being unmarshalled
        Returns:
        HttpResponse to replace the actual response. May be a mutated version of the original or a completely new HttpResponse object
      • afterAttempt

        void afterAttempt(HandlerAfterAttemptContext context)
        Runs any additional processing logic on a request after each individual attempt. Callback is invoked whether or not the attempt resulted in a successful response or an error. This callback is invoked within a finally block and so any exceptions it generates will "replace" the current exception, if one is outstanding.
        Parameters:
        context - container for the request as well as all possible results of the attempt
      • afterResponse

        void afterResponse(Request<?> request,
         Response<?> response)
        Runs any additional processing logic on the specified request (after is has been executed by the client runtime).
        Parameters:
        request - The low level request being processed.
        response - The response generated from the specified request.
      • afterError

        void afterError(Request<?> request,
         Response<?> response,
         Exception e)
        Runs any additional processing logic on a request after it has failed. This callback is invoked from a catch block. If it generates an exception, the original AmazonClientException will be lost.
        Parameters:
        request - The request that generated an error.
        response - the response or null if the failure occurred before the response is made available
        e - The error that resulted from executing the request.
Skip navigation links
  • Summary:
  • Nested |
  • Field |
  • Constr |
  • Method
  • Detail:
  • Field |
  • Constr |
  • Method

AltStyle によって変換されたページ (->オリジナル) /