-
Notifications
You must be signed in to change notification settings - Fork 16
LiteDbOptions
NuGet package: DotNetWorkQueue.Transport.LiteDb
Options class: LiteDbMessageQueueTransportOptions
Namespace: DotNetWorkQueue.Transport.LiteDb.Basic
The LiteDb transport uses the local machine's clock for all time-dependent operations (delayed processing, expiration, heartbeat). If consumers run on multiple machines sharing the same database file, their clocks should be synchronized.
LiteDb requires shared connections. The connection string format is:
Filename=path/to/queue.db;Connection=shared;
These options are set at queue creation time and cannot be changed after the queue exists.
| Property | Type | Default | Notes |
|---|---|---|---|
EnableDelayedProcessing |
bool |
false |
Messages can be scheduled for future processing |
EnableStatusTable |
bool |
false |
Separate table for queue status queries |
EnableRoute |
bool |
false |
Tag messages with a route string |
EnableMessageExpiration |
bool |
false |
Auto-remove unprocessed messages past expiry |
EnableHistory |
bool |
false |
Message lifecycle tracking |
When EnableHistory is true, the HistoryOptions property (type HistoryTransportOptions) controls retention:
| Property | Type | Default |
|---|---|---|
RetentionDays |
int |
30 |
MaxExceptionLength |
int |
4000 |
StoreBody |
bool |
false |
TrackEnqueue |
bool |
true |
TrackProcessing |
bool |
true |
TrackComplete |
bool |
true |
TrackError |
bool |
true |
TrackDelete |
bool |
true |
TrackExpire |
bool |
true |
MonitorTime |
TimeSpan |
1 day |
The following are hardcoded in the LiteDb transport and cannot be changed:
| Property | Fixed value | Notes |
|---|---|---|
EnablePriority |
false |
Priority queuing is not supported |
EnableStatus |
true |
Status tracking is always on |
EnableHeartBeat |
true |
Crashed workers will have their messages recovered |
LiteDb does not support EnableHoldTransactionUntilMessageCommitted, QueueType, AdditionalColumns, or AdditionalConstraints. These properties are not present on the LiteDb options class.
See MessageHistory for details on history tracking behavior.
For any issues please use the GitHub issues