If an assembly A contains ApiControllers and it references another assembly B that does not contain ApiControllers and this assembly B is not found (because it is not installed for example) controller type resolution does not find the ApiControllers in assembly A.
In this case only a 404 status code is returned together with a HttpError message indicating that no matching controller for the specified route could be found. There is no indication __why__ this controller (that actually exists) has not been found.
For a developer who experiences this behaviour (lots of or even all routes return 404) this error is very hard to detect and to analyze. An improvement of either controller type resolution (prefered in my opinion) or at least error reporting or tracing would be very welcome.
Details about this problem are in this Stackoverflow question and its answers:
http://stackoverflow.com/questions/16812995/all-requests-to-asp-net-web-api-return-404-error
I'd like to mention that type resolution for MVC controllers does not suffer from this problem. MVC controllers in assembly A are found, even when assembly B is missing. It would be good in my opinion if controller type resolution in Web API would behave the same way.
Comments: Verified.
In this case only a 404 status code is returned together with a HttpError message indicating that no matching controller for the specified route could be found. There is no indication __why__ this controller (that actually exists) has not been found.
For a developer who experiences this behaviour (lots of or even all routes return 404) this error is very hard to detect and to analyze. An improvement of either controller type resolution (prefered in my opinion) or at least error reporting or tracing would be very welcome.
Details about this problem are in this Stackoverflow question and its answers:
http://stackoverflow.com/questions/16812995/all-requests-to-asp-net-web-api-return-404-error
I'd like to mention that type resolution for MVC controllers does not suffer from this problem. MVC controllers in assembly A are found, even when assembly B is missing. It would be good in my opinion if controller type resolution in Web API would behave the same way.
Comments: Verified.