Table of Contents

Constructor MongoTransactionErrorEventData

Namespace
MongoDB.EntityFrameworkCore.Diagnostics
Assembly
MongoDB.EntityFrameworkCore.dll

MongoTransactionErrorEventData(EventDefinitionBase, Func<EventDefinitionBase, EventData, string>, MongoTransaction, bool, string, Exception, DateTimeOffset, TimeSpan)

Constructs the event payload.

public MongoTransactionErrorEventData(EventDefinitionBase eventDefinition, Func<EventDefinitionBase, EventData, string> messageGenerator, MongoTransaction transaction, bool async, string action, Exception exception, DateTimeOffset startTime, TimeSpan duration)

Parameters

eventDefinition EventDefinitionBase

The event definition.

messageGenerator Func<EventDefinitionBase, EventData, string>

A delegate that generates a log message for this event.

transaction MongoTransaction

The MongoTransaction.

async bool

Indicates whether or not the transaction is being used asynchronously.

action string

One of "Commit" or "Rollback".

exception Exception

The exception that was thrown when the transaction failed.

startTime DateTimeOffset

The start time of this event.

duration TimeSpan

The duration this event.