diff --git a/prj/coherence-core/src/main/java/com/tangosol/util/AsynchronousAgent.java b/prj/coherence-core/src/main/java/com/tangosol/util/AsynchronousAgent.java index 96dde45a86c3a..6f516e83bcef7 100644 --- a/prj/coherence-core/src/main/java/com/tangosol/util/AsynchronousAgent.java +++ b/prj/coherence-core/src/main/java/com/tangosol/util/AsynchronousAgent.java @@ -47,6 +47,18 @@ public abstract class AsynchronousAgent implements FlowControl, Future { + /** + * Construct the agent. + * + * @param iOrderId a unit-of-order id associated with this agent. Ordering + * semantics of operations based on this id are defined + * by subclasses + */ + protected AsynchronousAgent(int iOrderId) + { + this(iOrderId, null); + } + /** * Construct the agent. * diff --git a/prj/coherence-core/src/main/java/com/tangosol/util/InvocableMapHelper.java b/prj/coherence-core/src/main/java/com/tangosol/util/InvocableMapHelper.java index 06b4ad7f71401..69f83dc13c19e 100644 --- a/prj/coherence-core/src/main/java/com/tangosol/util/InvocableMapHelper.java +++ b/prj/coherence-core/src/main/java/com/tangosol/util/InvocableMapHelper.java @@ -67,6 +67,27 @@ public abstract class InvocableMapHelper extends Base { + /** + * Invoke the specified EntryProcessor asynchronously. + * + * @param cache the cache to invoke against + * @param key the key to invoke upon + * @param proc the processor to invoke + * + * @param the key type + * @param the value type + * @param the result type + * + * @return a CompletableFuture which will contain the result + * + * @deprecated As of Coherence 14.1.1, use enhanced + * {@link #invokeAsync(NamedCache, Object, int, InvocableMap.EntryProcessor, BiConsumer[])}. + */ + public static CompletableFuture invokeAsync(NamedCache cache, K key, InvocableMap.EntryProcessor proc) + { + return invokeAsync(cache, key, Thread.currentThread().hashCode(), proc); + } + /** * Invoke the specified EntryProcessor asynchronously. *

diff --git a/prj/coherence-core/src/main/java/com/tangosol/util/aggregator/AbstractAsynchronousAggregator.java b/prj/coherence-core/src/main/java/com/tangosol/util/aggregator/AbstractAsynchronousAggregator.java index 3dbee3ababf65..8e766f710d3e8 100644 --- a/prj/coherence-core/src/main/java/com/tangosol/util/aggregator/AbstractAsynchronousAggregator.java +++ b/prj/coherence-core/src/main/java/com/tangosol/util/aggregator/AbstractAsynchronousAggregator.java @@ -37,6 +37,17 @@ public abstract class AbstractAsynchronousAggregator implements EntryAggregator { + /** + * Construct an AsynchronousAggregator for a given streaming aggregator. + * + * @param aggregator the underlying streaming aggregator + * @param iUnitOrderId the unit-of-order id for this aggregator + */ + protected AbstractAsynchronousAggregator(StreamingAggregator aggregator, int iUnitOrderId) + { + this(aggregator, iUnitOrderId, null); + } + /** * Construct an AsynchronousAggregator for a given streaming aggregator. * diff --git a/prj/coherence-core/src/main/java/com/tangosol/util/processor/AbstractAsynchronousProcessor.java b/prj/coherence-core/src/main/java/com/tangosol/util/processor/AbstractAsynchronousProcessor.java index db2121ce1a0aa..b4b0754ba2d4a 100644 --- a/prj/coherence-core/src/main/java/com/tangosol/util/processor/AbstractAsynchronousProcessor.java +++ b/prj/coherence-core/src/main/java/com/tangosol/util/processor/AbstractAsynchronousProcessor.java @@ -35,6 +35,17 @@ public abstract class AbstractAsynchronousProcessor { // ---- constructors ---------------------------------------------------- + /** + * Construct AbstractAsynchronousProcessor instance. + * + * @param processor the underlying {@link InvocableMap.EntryProcessor} + * @param iUnitOrderId the unit-of-order id for this processor + */ + protected AbstractAsynchronousProcessor(InvocableMap.EntryProcessor processor, int iUnitOrderId) + { + this(processor, iUnitOrderId, null); + } + /** * Construct AbstractAsynchronousProcessor instance. *