NamedCacheSingleObjectInvokeT, P Method (CachedObjectId, P, ActionT, P, EvalArgs, TimeSpan)

ScaleOut Software NamedCache API
Invoke the user-defined method on the StateServer object identified by objectId within this NamedCache. The method invocation will be passed the parameter object param. In this overload, method has a void return.

Namespace:  Soss.Client
Assembly:  soss_namedcache (in soss_namedcache.dll) Version: 6.2.0.0
Syntax

public void SingleObjectInvoke<T, P>(
	CachedObjectId objectId,
	P param,
	Action<T, P, EvalArgs> method,
	TimeSpan invokeTimeout
)

Parameters

objectId
Type: Soss.ClientCachedObjectId
A NamedCache objectId identifying the object to be retrieved from StateServer and supplied to method when it runs.
param
Type: P
an object to be passed to each method at evaluation time. param must be serializable and the assembly in which it is defined must be available on all StateServer hosts.
method
Type: SystemActionT, P, EvalArgs
a delegate specifying the method to run for the target object specified by objectId. The Type in which method is defined must be serializable.

In this Invoke overload, the method is expected to take three arguments: an object of type T, referred to as the Target object, an object of type P which is the type of param and an EvalArgs argument through which the method can indicate the disposition of the target object and determine the StateServerKey of the target object.

invokeTimeout
Type: SystemTimeSpan

The amount of time allowed for this Invoke operation. After the expires, the operation will be canceled. You may specify InfiniteInvokeTimeout if you want the operation to continue no matter how long it takes. However, temporary objects used while processing SingleObjectInvokeT, P, R(CachedObjectId, P, FuncT, P, R, TimeSpan) may accumulate if an error occurs and you specify InfiniteInvokeTimeout.

The value specified is currently adjusted up to the smallest number of seconds equal or greater than the TimeSpan value specified. This granularity may change in future implementations.

Type Parameters

T
the type of the Target object to be retrieved from StateServer and supplied to method when it runs. In order to be stored in StateServer, objects of type T must be serializable.
P
the type of the Parameter object passed to each Eval method invocation. P must be serializable.
Remarks

The method invocation will occur at a host which currently has the object in its store.
See Also

Reference