共用方式為


RelationalLoggerExtensions 類別

定義

這個類別包含 EF Core 內部和關係資料庫提供者用來將資訊 ILogger 寫入 至 和 DiagnosticListener 的靜態方法,以供已知事件使用。

此類型通常由資料庫提供者 (和其他延伸模組) 使用。 它通常不會用於應用程式程式碼。

public static class RelationalLoggerExtensions
type RelationalLoggerExtensions = class
Public Module RelationalLoggerExtensions
繼承
RelationalLoggerExtensions

備註

如需詳細資訊 和範例,請參閱資料庫提供者和延伸模組的實作

方法

AllIndexPropertiesNotToMappedToAnyTable(IDiagnosticsLogger<DbLoggerCategory.Model.Validation>, IEntityType, IIndex)

AllIndexPropertiesNotToMappedToAnyTable記錄事件。

AmbientTransactionEnlisted(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, Transaction)

AmbientTransactionEnlisted事件的記錄。

AmbientTransactionWarning(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DateTimeOffset)

AmbientTransactionWarning事件的記錄。

BatchExecutorFailedToReleaseSavepoint(IDiagnosticsLogger<DbLoggerCategory.Update>, Type, Exception)

BatchExecutorFailedToReleaseSavepoint事件的記錄。

BatchExecutorFailedToRollbackToSavepoint(IDiagnosticsLogger<DbLoggerCategory.Update>, Type, Exception)

BatchExecutorFailedToRollbackToSavepoint事件的記錄。

BatchReadyForExecution(IDiagnosticsLogger<DbLoggerCategory.Update>, IEnumerable<IUpdateEntry>, Int32)

BatchReadyForExecution事件的記錄。

BatchSmallerThanMinBatchSize(IDiagnosticsLogger<DbLoggerCategory.Update>, IEnumerable<IUpdateEntry>, Int32, Int32)

BatchSmallerThanMinBatchSize事件的記錄。

BoolWithDefaultWarning(IDiagnosticsLogger<DbLoggerCategory.Model.Validation>, IProperty)

BoolWithDefaultWarning事件的記錄。

ColumnOrderIgnoredWarning(IDiagnosticsLogger<DbLoggerCategory.Migrations>, ColumnOperation)

這是支援 Entity Framework Core 基礎結構的內部 API,不受與公用 API 相同的相容性標準。 它可能會在任何版本中變更或移除,而不會有任何通知。 您應該只在程式碼中直接使用它,並知道這麼做可能會導致應用程式在更新至新的 Entity Framework Core 版本時失敗。

CommandCreated(IDiagnosticsLogger<DbLoggerCategory.Database.Command>, IRelationalConnection, DbCommand, DbCommandMethod, DbContext, Guid, Guid, DateTimeOffset, TimeSpan)

CommandCreated事件的記錄。

CommandCreating(IDiagnosticsLogger<DbLoggerCategory.Database.Command>, IRelationalConnection, DbCommandMethod, DbContext, Guid, Guid, DateTimeOffset)

CommandCreating事件的記錄。

CommandError(IDiagnosticsLogger<DbLoggerCategory.Database.Command>, IRelationalConnection, DbCommand, DbContext, DbCommandMethod, Guid, Guid, Exception, DateTimeOffset, TimeSpan)

CommandError事件的記錄。

CommandErrorAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Command>, IRelationalConnection, DbCommand, DbContext, DbCommandMethod, Guid, Guid, Exception, DateTimeOffset, TimeSpan, CancellationToken)

CommandError事件的記錄。

CommandNonQueryExecuted(IDiagnosticsLogger<DbLoggerCategory.Database.Command>, IRelationalConnection, DbCommand, DbContext, Guid, Guid, Int32, DateTimeOffset, TimeSpan)

CommandExecuted事件的記錄。

CommandNonQueryExecutedAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Command>, IRelationalConnection, DbCommand, DbContext, Guid, Guid, Int32, DateTimeOffset, TimeSpan, CancellationToken)

CommandExecuted事件的記錄。

CommandNonQueryExecuting(IDiagnosticsLogger<DbLoggerCategory.Database.Command>, IRelationalConnection, DbCommand, DbContext, Guid, Guid, DateTimeOffset)

CommandExecuting事件的記錄。

CommandNonQueryExecutingAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Command>, IRelationalConnection, DbCommand, DbContext, Guid, Guid, DateTimeOffset, CancellationToken)

CommandExecuting事件的記錄。

CommandReaderExecuted(IDiagnosticsLogger<DbLoggerCategory.Database.Command>, IRelationalConnection, DbCommand, DbContext, Guid, Guid, DbDataReader, DateTimeOffset, TimeSpan)

CommandExecuted事件的記錄。

CommandReaderExecutedAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Command>, IRelationalConnection, DbCommand, DbContext, Guid, Guid, DbDataReader, DateTimeOffset, TimeSpan, CancellationToken)

CommandExecuted事件的記錄。

CommandReaderExecuting(IDiagnosticsLogger<DbLoggerCategory.Database.Command>, IRelationalConnection, DbCommand, DbContext, Guid, Guid, DateTimeOffset)

CommandExecuting事件的記錄。

CommandReaderExecutingAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Command>, IRelationalConnection, DbCommand, DbContext, Guid, Guid, DateTimeOffset, CancellationToken)

CommandExecuting事件的記錄。

CommandScalarExecuted(IDiagnosticsLogger<DbLoggerCategory.Database.Command>, IRelationalConnection, DbCommand, DbContext, Guid, Guid, Object, DateTimeOffset, TimeSpan)

CommandExecuted事件的記錄。

CommandScalarExecutedAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Command>, IRelationalConnection, DbCommand, DbContext, Guid, Guid, Object, DateTimeOffset, TimeSpan, CancellationToken)

CommandExecuted事件的記錄。

CommandScalarExecuting(IDiagnosticsLogger<DbLoggerCategory.Database.Command>, IRelationalConnection, DbCommand, DbContext, Guid, Guid, DateTimeOffset)

CommandExecuting事件的記錄。

CommandScalarExecutingAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Command>, IRelationalConnection, DbCommand, DbContext, Guid, Guid, DateTimeOffset, CancellationToken)

CommandExecuting事件的記錄。

ConnectionClosed(IDiagnosticsLogger<DbLoggerCategory.Database.Connection>, IRelationalConnection, DateTimeOffset, TimeSpan)

ConnectionClosed事件的記錄。

ConnectionClosedAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Connection>, IRelationalConnection, DateTimeOffset, TimeSpan)

ConnectionClosed事件的記錄。

ConnectionClosing(IDiagnosticsLogger<DbLoggerCategory.Database.Connection>, IRelationalConnection, DateTimeOffset)

ConnectionClosing事件的記錄。

ConnectionClosingAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Connection>, IRelationalConnection, DateTimeOffset)

ConnectionClosing事件的記錄。

ConnectionError(IDiagnosticsLogger<DbLoggerCategory.Database.Connection>, IRelationalConnection, Exception, DateTimeOffset, TimeSpan, Boolean)

ConnectionError事件的記錄。

ConnectionErrorAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Connection>, IRelationalConnection, Exception, DateTimeOffset, TimeSpan, Boolean, CancellationToken)

ConnectionError事件的記錄。

ConnectionOpened(IDiagnosticsLogger<DbLoggerCategory.Database.Connection>, IRelationalConnection, DateTimeOffset, TimeSpan)

ConnectionOpened事件的記錄。

ConnectionOpenedAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Connection>, IRelationalConnection, DateTimeOffset, TimeSpan, CancellationToken)

ConnectionOpened事件的記錄。

ConnectionOpening(IDiagnosticsLogger<DbLoggerCategory.Database.Connection>, IRelationalConnection, DateTimeOffset)

ConnectionOpening事件的記錄。

ConnectionOpeningAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Connection>, IRelationalConnection, DateTimeOffset, CancellationToken)

ConnectionOpening事件的記錄。

CreatedTransactionSavepoint(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset)

CreatedTransactionSavepoint事件的記錄。

CreatedTransactionSavepointAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset, CancellationToken)

CreatedTransactionSavepoint事件的記錄。

CreatingTransactionSavepoint(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset)

CreatingTransactionSavepoint事件的記錄。

CreatingTransactionSavepointAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset, CancellationToken)

CreatingTransactionSavepoint事件的記錄。

DataReaderDisposing(IDiagnosticsLogger<DbLoggerCategory.Database.Command>, IRelationalConnection, DbCommand, DbDataReader, Guid, Int32, Int32, DateTimeOffset, TimeSpan)

DataReaderDisposing事件的記錄。

DuplicateColumnOrders(IDiagnosticsLogger<DbLoggerCategory.Model.Validation>, StoreObjectIdentifier, IReadOnlyList<String>)

DuplicateColumnOrders記錄事件。

ExecuteDeleteFailed(IDiagnosticsLogger<DbLoggerCategory.Query>, Type, Exception)

ExecuteDeleteFailed事件的記錄。

ExecuteUpdateFailed(IDiagnosticsLogger<DbLoggerCategory.Query>, Type, Exception)

ExecuteUpdateFailed事件的記錄。

ExplicitTransactionEnlisted(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, Transaction)

ExplicitTransactionEnlisted事件的記錄。

ForeignKeyPropertiesMappedToUnrelatedTables(IDiagnosticsLogger<DbLoggerCategory.Model.Validation>, IForeignKey)

ForeignKeyPropertiesMappedToUnrelatedTables記錄事件。

ForeignKeyTpcPrincipalWarning(IDiagnosticsLogger<DbLoggerCategory.Model.Validation>, IForeignKey)

ForeignKeyTpcPrincipalWarning記錄事件。

IndexPropertiesBothMappedAndNotMappedToTable(IDiagnosticsLogger<DbLoggerCategory.Model.Validation>, IEntityType, IIndex, String)

IndexPropertiesBothMappedAndNotMappedToTable記錄事件。

IndexPropertiesMappedToNonOverlappingTables(IDiagnosticsLogger<DbLoggerCategory.Model.Validation>, IEntityType, IIndex, String, List<ValueTuple<String,String>>, String, List<ValueTuple<String,String>>)

IndexPropertiesMappedToNonOverlappingTables記錄事件。

KeyPropertiesNotMappedToTable(IDiagnosticsLogger<DbLoggerCategory.Model.Validation>, IKey)

KeyPropertiesNotMappedToTable記錄事件。

MigrateUsingConnection(IDiagnosticsLogger<DbLoggerCategory.Migrations>, IMigrator, IRelationalConnection)

MigrateUsingConnection事件的記錄。

MigrationApplying(IDiagnosticsLogger<DbLoggerCategory.Migrations>, IMigrator, Migration)

MigrationApplying事件的記錄。

MigrationAttributeMissingWarning(IDiagnosticsLogger<DbLoggerCategory.Migrations>, TypeInfo)

MigrationAttributeMissingWarning事件的記錄。

MigrationGeneratingDownScript(IDiagnosticsLogger<DbLoggerCategory.Migrations>, IMigrator, Migration, String, String, Boolean)

MigrationGeneratingDownScript事件的記錄。

MigrationGeneratingUpScript(IDiagnosticsLogger<DbLoggerCategory.Migrations>, IMigrator, Migration, String, String, Boolean)

MigrationGeneratingUpScript事件的記錄。

MigrationReverting(IDiagnosticsLogger<DbLoggerCategory.Migrations>, IMigrator, Migration)

MigrationReverting事件的記錄。

MigrationsNotApplied(IDiagnosticsLogger<DbLoggerCategory.Migrations>, IMigrator)

MigrationsNotApplied事件的記錄。

MigrationsNotFound(IDiagnosticsLogger<DbLoggerCategory.Migrations>, IMigrator, IMigrationsAssembly)

MigrationsNotFound事件的記錄。

ModelValidationKeyDefaultValueWarning(IDiagnosticsLogger<DbLoggerCategory.Model.Validation>, IProperty)

ModelValidationKeyDefaultValueWarning事件的記錄。

MultipleCollectionIncludeWarning(IDiagnosticsLogger<DbLoggerCategory.Query>)

MultipleCollectionIncludeWarning事件的記錄。

NonQueryOperationFailed(IDiagnosticsLogger<DbLoggerCategory.Query>, Type, Exception)

NonQueryOperationFailed事件的記錄。

OptionalDependentWithAllNullPropertiesWarning(IDiagnosticsLogger<DbLoggerCategory.Update>, IUpdateEntry)

OptionalDependentWithAllNullPropertiesWarning記錄事件。

OptionalDependentWithAllNullPropertiesWarningSensitive(IDiagnosticsLogger<DbLoggerCategory.Update>, IUpdateEntry)

OptionalDependentWithAllNullPropertiesWarning記錄事件。

OptionalDependentWithoutIdentifyingPropertyWarning(IDiagnosticsLogger<DbLoggerCategory.Model.Validation>, IEntityType)

OptionalDependentWithoutIdentifyingPropertyWarning記錄事件。

QueryPossibleExceptionWithAggregateOperatorWarning(IDiagnosticsLogger<DbLoggerCategory.Query>)
已過時。.

QueryPossibleExceptionWithAggregateOperatorWarning事件的記錄。

QueryPossibleUnintendedUseOfEqualsWarning(IDiagnosticsLogger<DbLoggerCategory.Query>, MethodCallExpression)

QueryPossibleUnintendedUseOfEqualsWarning事件的記錄。

QueryPossibleUnintendedUseOfEqualsWarning(IDiagnosticsLogger<DbLoggerCategory.Query>, SqlExpression, SqlExpression)

QueryPossibleUnintendedUseOfEqualsWarning事件的記錄。

ReleasedTransactionSavepoint(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset)

ReleasedTransactionSavepoint事件的記錄。

ReleasedTransactionSavepointAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset, CancellationToken)

ReleasedTransactionSavepoint事件的記錄。

ReleasingTransactionSavepoint(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset)

RollingBackToTransactionSavepoint事件的記錄。

ReleasingTransactionSavepointAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset, CancellationToken)

ReleasingTransactionSavepoint事件的記錄。

RolledBackToTransactionSavepoint(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset)

RolledBackToTransactionSavepoint事件的記錄。

RolledBackToTransactionSavepointAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset, CancellationToken)

CreatedTransactionSavepoint事件的記錄。

RollingBackToTransactionSavepoint(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset)

RollingBackToTransactionSavepoint事件的記錄。

RollingBackToTransactionSavepointAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset, CancellationToken)

RollingBackToTransactionSavepoint事件的記錄。

StoredProcedureConcurrencyTokenNotMapped(IDiagnosticsLogger<DbLoggerCategory.Model.Validation>, IEntityType, IProperty, String)

StoredProcedureConcurrencyTokenNotMapped記錄事件。

TpcStoreGeneratedIdentityWarning(IDiagnosticsLogger<DbLoggerCategory.Model.Validation>, IProperty)

TpcStoreGeneratedIdentityWarning記錄事件。

TransactionCommitted(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset, TimeSpan)

TransactionCommitted事件的記錄。

TransactionCommittedAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset, TimeSpan, CancellationToken)

TransactionCommitted事件的記錄。

TransactionCommitting(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset)

TransactionCommitting事件的記錄。

TransactionCommittingAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset, CancellationToken)

TransactionCommitting事件的記錄。

TransactionDisposed(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset)

TransactionDisposed事件的記錄。

TransactionError(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, String, Exception, DateTimeOffset, TimeSpan)

TransactionError事件的記錄。

TransactionErrorAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, String, Exception, DateTimeOffset, TimeSpan, CancellationToken)

TransactionError事件的記錄。

TransactionRolledBack(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset, TimeSpan)

TransactionRolledBack事件的記錄。

TransactionRolledBackAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset, TimeSpan, CancellationToken)

TransactionRolledBack事件的記錄。

TransactionRollingBack(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset)

TransactionRollingBack事件的記錄。

TransactionRollingBackAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset, CancellationToken)

TransactionRollingBack事件的記錄。

TransactionStarted(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset, TimeSpan)

TransactionStarted事件的記錄。

TransactionStartedAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset, TimeSpan, CancellationToken)

TransactionStarted事件的記錄。

TransactionStarting(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, IsolationLevel, Guid, DateTimeOffset)

TransactionStarting事件的記錄。

TransactionStartingAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, IsolationLevel, Guid, DateTimeOffset, CancellationToken)

TransactionStarting事件的記錄。

TransactionUsed(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset)

TransactionUsed事件的記錄。

TransactionUsedAsync(IDiagnosticsLogger<DbLoggerCategory.Database.Transaction>, IRelationalConnection, DbTransaction, Guid, DateTimeOffset, CancellationToken)

TransactionUsed事件的記錄。

TriggerOnNonRootTphEntity(IDiagnosticsLogger<DbLoggerCategory.Model.Validation>, IEntityType)

TransactionError事件的記錄。

UnexpectedTrailingResultSetWhenSaving(IDiagnosticsLogger<DbLoggerCategory.Update>)

UnexpectedTrailingResultSetWhenSaving事件的記錄。

適用於