Class CorrelatedTodo
Extends Todo toallow for correlation of multiple instances on SysCorrelationKey. This is used for example to aggregate various asynchronous events together. Example: batch frequent email notifications into one
Implements
System.IEquatable<Doc>
System.Collections.Generic.IEnumerable<System.Object>
System.Collections.IEnumerable
Inherited Members
System.Object.Equals(System.Object, System.Object)
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
Namespace: Azos.Sky.Workers
Assembly: Azos.Sky.dll
Syntax
[Serializable]
public abstract class CorrelatedTodo : Todo, IConfigurable, IConfigurationPersistent, IEquatable<Doc>, IEnumerable<object>, IEnumerable, IValidatable, IJSONWritable, IAmorphousData, IDistributedStableHashProvider
Constructors
CorrelatedTodo()
Declaration
protected CorrelatedTodo()
Properties
SysCorrelationKey
Provides the correlation key which is used for merging the CorrelatedTodo instances. The key technically may be null
Declaration
public string SysCorrelationKey { get; set; }
Property Value
Type | Description |
---|---|
System.String |
Methods
Merge(ITodoHost, DateTime, CorrelatedTodo)
Executes merge operation returning what whould happen to the original and another todo. This method MUST execute be VERY FAST and only contain merge logic, do not make externall IO calls - all business data must already be contained in the original and another instance
Declaration
protected abstract CorrelatedTodo.MergeResult Merge(ITodoHost host, DateTime utcNow, CorrelatedTodo another)
Parameters
Type | Name | Description |
---|---|---|
ITodoHost | host | |
System.DateTime | utcNow | |
CorrelatedTodo | another |
Returns
Type | Description |
---|---|
CorrelatedTodo.MergeResult |
Implements
System.IEquatable<T>
System.Collections.Generic.IEnumerable<T>
System.Collections.IEnumerable