Поделиться через


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)

Это внутренний API, который поддерживает инфраструктуру Entity Framework Core и не подчиняется тем же стандартам совместимости, что и общедоступные 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 события.

Применяется к