Class ClusteredGetResponseValidityFilter
java.lang.Object
org.infinispan.remoting.responses.ClusteredGetResponseValidityFilter
- All Implemented Interfaces:
ResponseFilter
A filter that tests the validity of
ClusteredGetCommands.
JGroups calls our handler while holding a lock, so we don't need any synchronization.- Since:
- 4.0
- Author:
- Manik Surtani
-
Constructor Summary
ConstructorsConstructorDescriptionClusteredGetResponseValidityFilter(Collection<Address> targets, Address self) -
Method Summary
Modifier and TypeMethodDescriptionbooleanisAcceptable(Response response, Address address) Determines whether a response from a given sender should be added to the response list of the requestbooleanRight after callingResponseFilter.isAcceptable(Response, Address), this method is called to see whether we are done with the request and can unblock the caller
-
Constructor Details
-
ClusteredGetResponseValidityFilter
-
-
Method Details
-
isAcceptable
Description copied from interface:ResponseFilterDetermines whether a response from a given sender should be added to the response list of the request- Specified by:
isAcceptablein interfaceResponseFilter- Parameters:
response- The response (usually a serializable value)address- The sender of response- Returns:
- True if we should add the response to the response list of a request, otherwise false. In the latter case, we don't add the response to the response list.
-
needMoreResponses
public boolean needMoreResponses()Description copied from interface:ResponseFilterRight after callingResponseFilter.isAcceptable(Response, Address), this method is called to see whether we are done with the request and can unblock the caller- Specified by:
needMoreResponsesin interfaceResponseFilter- Returns:
- False if the request is done, otherwise true
-