I have two applications. One is ASP.NET WebForms and the other is WebAPI. Locally, both are hosted on the same port and both are set up to run MiniProfiler, meaning they both return a X-MiniProfiler-Ids
header in their responses.
The WebForms application is hosted from localhost:20030/www
.
The WebAPI application is hosted from localhost:20030/api/v2
.
The WebForms UI makes some AJAX calls in the browser both to the WebForms app and also to WebAPI.
My problem is that for calls to both /www
and /api/v2
the Miniprofiler UI makes a request to /www/mini-profiler-resources/results
to retrieve results. Only the results for the WebForms app are there, meaning it returns 404 for the requests for the profiler IDs it’s trying to get for the WebAPI calls.
Is there a way to configure MiniProfiler to hit /www/mini-profiler-resources/results
for calls made to localhost:20030/www
and to hit /api/v2/mini-profiler-resources/results
for calls made to localhost:20030/api/v2
? In other words, how can I get it to retrieve the WebAPI results from the WebAPI project and the WebForms results from the WebForms project?