Table of Contents

Constructor CommandFailedEvent

Namespace
MongoDB.Driver.Core.Events
Assembly
MongoDB.Driver.dll

CommandFailedEvent(string, DatabaseNamespace, Exception, long?, int, ConnectionId, TimeSpan)

Initializes a new instance of the CommandFailedEvent struct.

public CommandFailedEvent(string commandName, DatabaseNamespace databaseNamespace, Exception exception, long? operationId, int requestId, ConnectionId connectionId, TimeSpan duration)

Parameters

commandName string

Name of the command.

databaseNamespace DatabaseNamespace

The database namespace.

exception Exception

The exception.

operationId long?

The operation identifier.

requestId int

The request identifier.

connectionId ConnectionId

The connection identifier.

duration TimeSpan

The duration.

CommandFailedEvent(string, DatabaseNamespace, Exception, long?, int, ConnectionId, ObjectId?, TimeSpan)

Initializes a new instance of the CommandFailedEvent struct.

public CommandFailedEvent(string commandName, DatabaseNamespace databaseNamespace, Exception exception, long? operationId, int requestId, ConnectionId connectionId, ObjectId? serviceId, TimeSpan duration)

Parameters

commandName string

Name of the command.

databaseNamespace DatabaseNamespace

The database namespace.

exception Exception

The exception.

operationId long?

The operation identifier.

requestId int

The request identifier.

connectionId ConnectionId

The connection identifier.

serviceId ObjectId?

The service identifier.

duration TimeSpan

The duration.