Creating links to other OData routes is hard


I have to figure out the appropriate path handler to use. The framework already knows which path handler should be used when I provide a route name; it shouldn't ask me for it.

Possible scenarios:
I want to create an OData link from an ODataController associated with a different model. In particular, I might be versioning and want to create a link from one version (v2) to another (v1).
I want to create an OData link from an ApiController (non-OData). In particular, I might want to migrate to OData and this method would give me an entry point to the OData world from the non-OData world.
Closed Jan 15 at 8:07 AM by lianw
Closed here and moved the issue to GitHub (https://github.com/OData/WebApi/issues/25)


HongmeiG wrote Jan 15, 2013 at 5:57 AM

This is a valid request. I am moving it to vNext so that we can provide a better url helper extension method to make this easier. This is an advance scenario. It is an advance scenario, and it is ok to punt since we are closing down RTM release.

HongmeiG wrote Mar 29, 2013 at 11:06 PM

In order to have the runtime to figure out the path handler, we will need to go back to the configuration and trying to retrieve it from the odata route constraint. It will be a lot simpler if user can pass the path handler directly. Usually that should be a singleton.