Skip to content

Docs for logging, events, and diagnostics - #2787

Merged
ajcvickers merged 4 commits into
masterfrom
FallOnME1008
Nov 10, 2020
Merged

ajcvickers merged 4 commits into
masterfrom
FallOnME1008

Conversation

@ajcvickers

@ajcvickers ajcvickers commented Oct 17, 2020 •

Copy link
Copy Markdown
Contributor

No TOC yet since we need to decide what to do with Fundamentals. smitpatel I do not intend to merge this way.

@ajcvickers
ajcvickers force-pushed the FallOnME1008 branch 3 times, most recently from 4b194ad to 777e0c0 Compare October 17, 2020 19:08
@ajcvickers
ajcvickers requested a review from a team October 17, 2020 19:12
@smitpatel

Copy link
Copy Markdown
Contributor

Can you remove my mention in the commit message? Github is showering me with notifications. 😢

@roji roji left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is much awesomeness here 🚀

Resolving EF Core events is a two-step process. First, an [observer](/dotnet/standard/events/observer-design-pattern) for `DiagnosticListener` itself must be created:

<!--
public class DiagnosticObserver : IObserver<DiagnosticListener>

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We may want to show the simplified/minimal sample as in the DiagnosticSource docs, without a special Observer type.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure if I fully understand why things are designed this way, but that "simplied" example does not look simpler to me.

-->
[!code-csharp[AuditContext](../../../../samples/core/Miscellaneous/SaveChangesInterception/AuditContext.cs?name=AuditContext)]

#### The interceptor

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider moving this up before the actual code sample of the interceptor

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't understand which part you want moving to where...

**No TOC yet since we need to decide what to do with `Fundamentals`. @smitpatel I do not intend to merge this way.**

* Fixes #2615: Add information on controlling suppressing warnings and otherwise configuring EventIds
* Fixes #2557: Support logging on DB level #2557
* Fixes #2770: Add entry in TOC for logging/interceptors
* Fixes #583: Document how to use DiagnosticSource/DiagnosticListener
* Fixes #673: Document EnableSensitiveDataLogging
* Fixes #1913: Interception of database operations: InterceptionResult or InterceptionResult<DbDataReader>?
* Fixes #1543: Document database interceptors with examples
* Fixes #955: Document EnableRichDataErrorHandling
* Fixes #661: EF Core 2.1: document state change events
@ajcvickers

Copy link
Copy Markdown
Contributor Author

@dotnet/efteam I believe this is now ready to merge--I will do so today. (I will make any uncontroversial minor updates from reviews. Any other suggested changes will be tracked by a new issue so I can get this merged.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment