Spring for Apache Hadoop

org.springframework.yarn.batch.repository
Class BatchAppmasterService.JobRepositoryServiceInterceptorList

java.lang.Object
  extended by org.springframework.yarn.batch.repository.BatchAppmasterService.JobRepositoryServiceInterceptorList
Enclosing class:
BatchAppmasterService

protected class BatchAppmasterService.JobRepositoryServiceInterceptorList
extends java.lang.Object

Convenient wrapper for interceptor list.


Constructor Summary
protected BatchAppmasterService.JobRepositoryServiceInterceptorList()
           
 
Method Summary
 boolean add(JobRepositoryRemoteServiceInterceptor interceptor)
          Adds interceptor to the list.
 BaseResponseObject handleRequest(BaseObject baseObject)
          Handles the handleRequest calls.
 BaseResponseObject postRequest(BaseResponseObject baseResponseObject)
          Handles he post request calls.
 BaseObject preRequest(BaseObject baseObject)
          Handles the pre request calls.
 boolean set(java.util.List<JobRepositoryRemoteServiceInterceptor> interceptors)
          Sets the interceptors, clears any existing interceptors.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BatchAppmasterService.JobRepositoryServiceInterceptorList

protected BatchAppmasterService.JobRepositoryServiceInterceptorList()
Method Detail

set

public boolean set(java.util.List<JobRepositoryRemoteServiceInterceptor> interceptors)
Sets the interceptors, clears any existing interceptors.

Parameters:
interceptors - the list of interceptors
Returns:
true if interceptor list changed as a result of the call

add

public boolean add(JobRepositoryRemoteServiceInterceptor interceptor)
Adds interceptor to the list.

Parameters:
interceptor - the interceptor
Returns:
true (as specified by Collection.add(E))

preRequest

public BaseObject preRequest(BaseObject baseObject)
Handles the pre request calls.

Parameters:
baseObject - the base request object
Returns:
the final modified request or null if interceptor broke the chain

handleRequest

public BaseResponseObject handleRequest(BaseObject baseObject)
Handles the handleRequest calls. Method returns immediately if one of the interceptors chooses to process the request.

Parameters:
baseObject - the base request object
Returns:
the processed request if any, null if no processing

postRequest

public BaseResponseObject postRequest(BaseResponseObject baseResponseObject)
Handles he post request calls.

Parameters:
baseResponseObject - the base response object
Returns:
the final modified response

Spring for Apache Hadoop