I am trying to get any DB queries that happen when using the SqlMembershipProvider to show in MiniProfiler but I can't think of any way to swap out the SqlConnection is uses with a ProfiledDbConnection as it seems to do everything internally. Anyone have any ingenious ideas?
You could download the source (freely avaliable) for the ASP.Net SQL Providers here, read more about it here, Scott Gu published tons of whitepapers in this article about the provider model. internal to the assembly is a SQLConnectionHelper that you can update to use the ProfiledDBConnection instead. This would give profiling to all the providers using that class, all thats left is to change your .config file to use the new provider instead.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With