How to get EFProf and EFProviderWrapper working together in on Entity Framework Connection

812 views Asked by At

Has anyone found a way to get Kowalski's EFProviderWrapper framework to run alongside Rhino's EFProf (Entity Framework Profiler) within the same Entity Framework context/connection? Currently if i try to register the EFProf Profiler while using an EntitytConnection wrapped with the EFProviderWrapper i get the following error at runtime when a new connection is attempted to be created:

Unable to cast object of type 'HibernatingRhinos.Profiler.Appender.ProfiledDataAccess.ProfiledConnection' to type 'EFProviderWrapperToolkit.DbConnectionWrapper'.

From what I can gether it appears to be because EFProf is registering last, and EFProviderWrapperToolkit expects to be the last one registered. Im guessing that this requires a change to EFProviderWrapperToolkit possibly to create a new DbConnectionWrapper type that allows for non-EFProviderWrapper types? If anyone has any experience with multiple DBConnection provider frameworks then im all ears.

1

There are 1 answers

0
Gergely Orosz On BEST ANSWER

After 3 years of inactivity I'm pretty certain the answer is:

Probably no.