using Quadarax.Foundation.Core.Business.Processor.Enums; using Quadarax.Foundation.Core.Object; namespace Quadarax.Foundation.Core.Business.Processor.Task { public interface ITaskItemData : ITaskIdentifier, ITimeTracked, IEquatable { #region *** Properties *** /// /// Contains the affinity token which is used to identify owning/locking queue. /// IAffinityToken? AffinityToken { get; } /// /// External reference of the task. /// public string Reference { get; } /// /// Status of the task. /// public ProcessStatusEnum Status { get; } /// /// Assembly qualified name of the provider class responsible to process task. /// public string ProviderClass { get; } /// /// Task priority value (0-maximal, 255-minimal / default 100). /// public byte Priority { get; } /// /// Time when task can be processed. /// public DateTime ProcessingValidFrom { get; } /// /// Time when task will be expired. /// public DateTime? ProcessingValidTo { get; } /// /// Defines single attempt timeout. If null, timeout is not used. /// public TimeSpan? AttemptTimeout { get; } /// /// Decremental counter of attempts to try process task. /// public int AttemptsLeft { get; } /// /// Initial attempt count value /// public int InitialAttempts { get; } /// /// Statistical timestamp when task begins to process. /// public DateTime StatStarted { get; } /// /// Statistical timestamp when task finished. /// public DateTime StatFinished { get; } /// /// Latest attempt duration /// public TimeSpan StatLastAttemptDuration { get; } /// /// Collection of task status changes history log items. Ordered by descending. /// public ITaskStatusLogItem[] StatusLog { get; } /// /// Collection of task arguments. /// public TypedArgument[] Arguments { get; } #endregion } }