Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8247231
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T22:46:27+00:00 2026-06-07T22:46:27+00:00

In version 1.9 of the mini profiler I found a way to get the

  • 0

In version 1.9 of the mini profiler I found a way to get the SQL timings of asynchronous DB calls into the profiler results. Basically, I added a ContinueWith to my async task and then added all the SQL timings to the step that initiated the async action:

foreach (var sqlTiming in completedResult.SqlTimings)
{
    currentStep.AddSqlTiming(sqlTiming);
}

However, this no longer works in 2.0.2 – those SQL timings just disappear. There appears to be a new method that does exactly what I want (source, line 487):

/// <summary>
/// Adds <paramref name="externalProfiler"/>'s <see cref="Timing"/> hierarchy to this profiler's current Timing step,
/// allowing other threads, remote calls, etc. to be profiled and joined into this profiling session.
/// </summary>
public static void AddProfilerResults(this MiniProfiler profiler, MiniProfiler externalProfiler)
{
    ...

So it looks as if this is what I should do now:

MiniProfiler.Current.AddProfilerResults(profilerFromAsyncTask);

But, while that doesn’t throw an error, it doesn’t seem to add anything at all to the results. I can get the steps to appear in the step with:

currentStep.AddChild(profilerFromAsyncTask.Root)

However that still discards the SQL timings and results in negative times for the step that starts the async task.

Is there something I need to do to get the results from AddProfilerResults to appear with the SQL timings?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T22:46:29+00:00Added an answer on June 7, 2026 at 10:46 pm

    Async is not currently an actively supported or tested scenario for mini-profiler. Until there is a supported mechanism to do that, I’m loathe to dig in to find a way to hack it in, only for that hack to evaporate with the next change. Long term, async is something we should handle – it just hasn’t been a requirement so far.

    I suspect your best option would be to create a suggestion on the project site (or add a comment on an existing suggestion). Or perhaps even better: figure out a mechanism to do it (that works without breaking anything or being risky) and submit a change-set.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a asp.net project that uses mvc-mini-profiler. I was using version 1.7 of
I've added Mini Profiler through NuGet and though in a really simple project works
Is it possible to create rounded corner that viewable on opera mini (version 4)
I have made two versions of my application, a large version, and a mini/lite
So hell froze over and Apple accepted Opera Mini into the app store. Does
I added bash completion for Maven following the docs: http://maven.apache.org/guides/mini/guide-bash-m2-completion.html Everything works well except
I've got the MVC Mini Profiler set up as described on its project page
I installed trail version of windows 8 in inspiron Dell mini 10 in this
I cant get x10 mini to show up in adb devices, (only emulators show
I tried to follow these instructions get OpenCV to compile on my MAC MINI,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.