AuditMode Enumeration

Assembly: CodeEffects.Rule.Audit.dll
Namespace: CodeEffects.Rule.Audit

Summary

Specifies whether an evaluation waits for its record to be written to the Rule Repository database.

Syntax

public enum AuditMode
{
	// The record is written to the database on the evaluating thread before the evaluation returns
	Synchronous = 0,

	// The record is handed to a background thread and the evaluation returns at once. The default
	Asynchronous = 1
}

Remarks

Set the mode through the Mode property of AuditSettings.

In Asynchronous mode the evaluation costs the time to build the record and hand it on. How much of what the recorder holds survives the process going away is then decided by Resilience. A background thread writes the records to the database in batches.

In Synchronous mode nothing is held anywhere, so nothing can be lost when the process ends, but every evaluation waits for a database round trip. Use it for decisions that must not be acted on unless they are recorded: together with ThrowOnStoreFailure, an evaluation whose record could not be written throws an AuditException instead of returning its result. Resilience, the journal settings, QueueCapacity and WhenFull do not apply in this mode.

The numeric values are permanent.

Ask on Stack Overflow - Yes, it's still active
Ask in GitHub Discussions

p102

l097 --

l102

p101

×