dotnet/aspnetcore

Add EventSource/EventCounter tracing and metrics for Session

Open

#2,396 建立於 2018年1月1日

在 GitHub 查看
 (0 留言) (0 反應) (0 負責人)C# (10,653 fork)batch import
affected-fewarea-middlewareenhancementfeature-sessionhelp wantedseverity-nice-to-have

倉庫指標

Star
 (37,933 star)
PR 合併指標
 (平均合併 16天 9小時) (30 天內合併 258 個 PR)

描述

From @anurse on Wednesday, November 1, 2017 3:22:31 PM

Some events listed below. The goal is to add events that will help users solve problems so if these aren't going to do that job, feel free to suggest/discuss others!

  • Microsoft-AspNetCore-Session EventSource
    • SessionsCreated - Counts sessions created
    • SessionsLoaded - Counts the number of times a session is loaded from the provider (this happens on each request for a session)
    • SessionsCommitted - Counts the number of times a session is commited to the provider (again, happens on each request)
    • We can't track abandoned or timed-out sessions any more as they are handled by caching now and we don't provide a way to explicitly abandon a session. We could detect "empty" sessions (with no data) but such a session could always be added to again later.

See https://gist.github.com/anurse/af1859663ac91c6cf69c820cebe92303 for some guidance on adding EventSources and EventCounters to ASP.NET projects.

Copied from original issue: aspnet/Session#200

貢獻者指南