I'm trying the new asp.net 5 alongside VSNET 2015 RC.
Configuration of my webapp: Microsoft.AspNet.Mvc 6.0.0-beta4
I'm really confused about this behavior: if i use
public void Configure(IApplicationBuilder app, IHostingEnvironment env)
{
...
app.UseMvc();
}
everything works. I call my controller via http://localhost:1234/api/values and all is ok.
For the sake of my testing if i change the snippet above in
public void Configure(IApplicationBuilder app, IHostingEnvironment env)
{
...
app.Map("/api", api => {
...
api.UseMvc();
});
}
and now every time I call the controller with the address above, the app returs 404.
Where I'm wrong?