Skip to content
This repository has been archived by the owner on Feb 13, 2019. It is now read-only.

ASP.NET 5 RC1 Web API application #465

Closed
rustd opened this issue Nov 11, 2015 · 6 comments
Closed

ASP.NET 5 RC1 Web API application #465

rustd opened this issue Nov 11, 2015 · 6 comments
Assignees

Comments

@rustd
Copy link

rustd commented Nov 11, 2015

Samples:
http://1drv.ms/1QiuMQs

Feed:
https://www.myget.org/F/aspnetrc1

@peterblazejewicz
Copy link
Member

Me, thanks!

@peterblazejewicz
Copy link
Member

Just like with #466:
#466 (comment)
This one does not run on OS X (mono/darwin):

dnx web  
Application startup exception: System.ArgumentException: The path must be absolute.
Parameter name: root
  at Microsoft.AspNet.FileProviders.PhysicalFileProvider..ctor (System.String root) [0x00000] in <filename unknown>:0 
  at Microsoft.Extensions.Configuration.FileProviderExtensions.ReloadOnChanged (IConfigurationRoot config, System.String basePath, System.String filename) [0x00000] in <filename unknown>:0 
  at Microsoft.Extensions.Configuration.FileProviderExtensions.ReloadOnChanged (IConfigurationRoot config, System.String filename) [0x00000] in <filename unknown>:0 
  at WebAPIApplication.Startup..ctor (IHostingEnvironment env) [0x00000] in <filename unknown>:0 
  at (wrapper managed-to-native) System.Reflection.MonoCMethod:InternalInvoke (System.Reflection.MonoCMethod,object,object[],System.Exception&)
  at System.Reflection.MonoCMethod.InternalInvoke (System.Object obj, System.Object[] parameters) [0x00000] in <filename unknown>:0 
--- End of stack trace from previous location where exception was thrown ---
  at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw () [0x00000] in <filename unknown>:0 
  at Microsoft.Extensions.DependencyInjection.ActivatorUtilities+ConstructorMatcher.CreateInstance (IServiceProvider provider) [0x00000] in <filename unknown>:0 
  at Microsoft.Extensions.DependencyInjection.ActivatorUtilities.CreateInstance (IServiceProvider provider, System.Type instanceType, System.Object[] parameters) [0x00000] in <filename unknown>:0 
  at Microsoft.Extensions.DependencyInjection.ActivatorUtilities.GetServiceOrCreateInstance (IServiceProvider provider, System.Type type) [0x00000] in <filename unknown>:0 
  at Microsoft.AspNet.Hosting.Startup.StartupLoader.LoadMethods (System.Type startupType, IList`1 diagnosticMessages) [0x00000] in <filename unknown>:0 
  at Microsoft.AspNet.Hosting.Internal.HostingEngine.EnsureStartup () [0x00000] in <filename unknown>:0 
  at Microsoft.AspNet.Hosting.Internal.HostingEngine.EnsureApplicationServices () [0x00000] in <filename unknown>:0 
  at Microsoft.AspNet.Hosting.Internal.HostingEngine.BuildApplication () [0x00000] in <filename unknown>:0 
Hosting environment: Production
Now listening on: http://localhost:5000
Application started. Press Ctrl+C to shut down.

unless I comment out .ReloadOnChanged("appsettings.json");

peterblazejewicz added a commit to peterblazejewicz/generator-aspnet that referenced this issue Nov 12, 2015
- add new app configuration file
- update test coverage
- update project configuration file
@rustd
Copy link
Author

rustd commented Nov 13, 2015

@peterblazejewicz can you please update this sample remove ReloadOnChanged call for RC1
Before

Configuration = builder.Build().ReloadOnChanged("appsettings.json");

After

Configuration = builder.Build();

peterblazejewicz added a commit to peterblazejewicz/generator-aspnet that referenced this issue Nov 13, 2015
- add new app configuration file
- update test coverage
- update project configuration file
@peterblazejewicz
Copy link
Member

@rustd
Thanks, updated PR

@rustd
Copy link
Author

rustd commented Nov 13, 2015

Thanks @peterblazejewicz you should do it for other templates as well where this is being used.

sayedihashimi added a commit that referenced this issue Nov 14, 2015
Update WebApi template for RC1. Closes #465
@peterblazejewicz
Copy link
Member

closed via: 00eebad

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants