Skip navigation links

Oracle® Coherence Java API Reference
Release 3.6.1.0

E18814-01


com.tangosol.net
Interface InvocableInOrder

All Superinterfaces:
Invocable, java.lang.Runnable, java.io.Serializable
All Known Implementing Classes:
AbstractHttpSessionCollection.ExitAgent, AbstractInvocable, LogThreadsHoldingLockAgent, PortalCacheProvider.FlushAgent, WorkManager.AbstractWork, WorkManager.CollectMembershipInfo, WorkManager.ReleaseWork, WorkManager.RequestStatus, WorkManager.ScheduleWork, WorkManager.SendFeedback

public interface InvocableInOrder
extends Invocable

The InvocableInOrder interface allows to control the ordering in which the results of Invocable tasks are returned back to the caller by the Invocation service with a thread pool.

Consider the following scenario. Cluster node A executes two asynchronous queries Q1 and Q2 calling InvocationService.execute(Invocable, Set, InvocationObserver). Both queries are to be executed on a cluster node B; Q2 is called after Q1 and therefore received by the InvocationService on the node B in that order.

If the Invocation service is configured to use a thread pool of more than one thread and the processing time of Q1 is significantly longer then the processing time of Q2, then the result of Q2 execution will be returned to the caller ahead of the response for Q1.

If a client application semantics require "in order" response guarantees, the corresponding Invocable tasks will have to implement InvocableInOrder interface and return "true" from isRespondInOrder() method.

Since:
Coherence 2.2
Author:
gg 2003-06-12
See Also:
AbstractInvocable

Method Summary
 boolean isRespondInOrder()
          Determine whether this Invocable object has to preserve the order of responses according to the order of requests.

 

Methods inherited from interface com.tangosol.net.Invocable
getResult, init, run

 

Method Detail

isRespondInOrder

boolean isRespondInOrder()
Determine whether this Invocable object has to preserve the order of responses according to the order of requests.
Returns:
true if the response order must be preserved; false otherwise

Skip navigation links

Oracle® Coherence Java API Reference
Release 3.6.1.0

E18814-01


Copyright © 2000, 2010, Oracle and/or its affiliates. All rights reserved.