Trace.axd and other profiling tools in Orchard

Topics: Troubleshooting
May 23, 2013 at 6:27 PM
Has anyone managed to get the OOB trace.axd functionality of asp.net working in Orchard? I've tried this and the Glimpse nuget package, neither of which work. Looking at the basic Orchard.Web app, it appears to be set to ignore routes with .axd in, but still nothing works.

Anyone know of a workaround? It would be great if at least trace.axd worked as part of the core product.
Coordinator
May 26, 2013 at 7:16 AM
Didn't you ask that same question on StackOverflow?
May 26, 2013 at 9:42 AM
Edited May 26, 2013 at 9:45 AM
yes, and it wasn't answered there either. It's really rather frustrating to me when good, default parts of the .NET framework are unavailable. I just want to work out how to get it back. I tried posting here, but generally there is not much reply
Coordinator
May 28, 2013 at 2:12 AM
Webforms are also unavailable, as are lots of things that do not make sense in the context of Orchard. What is it exactly that you are trying to do that you can't do with log4net?
May 29, 2013 at 8:38 AM
Edited May 29, 2013 at 8:38 AM
I really don't understand this answer. Webforms is an entirely seperate thread of the ASP.NET stack. You choose either MVC or Webforms (in general) to create your application. I don't want webforms (or why would we be writting a project in Orchard?), I want the trace.axd functionality. Since it seems I have to justify myself in order to get anything other than post-boosting replies on this forum, here are my reasons:

Summary: we wish to use trace.axd to quickly review performance, based on some performance trace statements

1) Trace.axd is available by default to every MVC application, unless it is removed.
2) You can see the results of a trace inline with page, or via trace,axd. This allows a quick, in browser check of all HTTP Headers, Server variables and trace statements
3) It allows you to see the trace statements relating to 1 request, without having to separate it through logging
4) It can be turned on/off separately to logging. If we were to run this using log4net we would also have to make all the performance trace items WARN or ERROR for anything other than local machine. Setting orchard logging to DEBUG results in about 2 mins to load a page as the logging is extremely verbose.
5) We are running in Windows Azure, and getting at the logs is not trivial. If we could, we would then need to post process them in order to see these results. Significantly harder than glancing at a trace

So - I'll ask my question again. Does anyone know of a workaround? Or a way I might get this working.

Some investigation leads me to believe it is to do with a HttpNotFoundHandler (something like that), as Glimpse works if i turn that off (obviously I probably have a different problem if I do). Sadly Trace.axd still does not work in that circumstance, I've not been able to work out why
Coordinator
May 31, 2013 at 7:26 AM
Orchard is not an ordinary MVC application. It is a modular and multi-tenant application, and anything that greedily uses global resources is going to be problematic.

I strongly recommend that you use the tools that are available for Orchard. In your case, Mini-profiler (which is easily extended) seems to be the perfect solution.

I didn't ask you to "justify yourself", I asked for more information about what you were trying to do so that I could recommend the best solution for your problem. Gee.