Skip to content

Conversation

@m17kea
Copy link
Contributor

@m17kea m17kea commented Jun 18, 2019

@guardrex
Copy link
Collaborator

guardrex commented Jun 18, 2019

hum 🤔 ... that's interesting because we doc "keys" as case-insensitive ...

Configuration keys adopt the following conventions:

  • Keys are case-insensitive. For example, ConnectionString and connectionstring are treated as equivalent keys.

However, yes on the specific point. Let's match anyway.

@HaoK Does GetSection require case matching? If so, I'll need to do a tad of work on what we mean by "key" in the Configuration doc. I'll need to distinguish the behavior between keys of key-value pairs and keys of sections.

@guardrex guardrex requested a review from HaoK June 18, 2019 15:09
@m17kea
Copy link
Contributor Author

m17kea commented Jun 18, 2019

With a capital P i get this error:

 System.InvalidOperationException: The endpoint Http is missing the required 'Url' parameter.
Jun 18 13:38:35 ip-32-0-32-123.ec2.internal derivitec-nuget[20016]: at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.ConfigurationReader.ReadEndpoints()
Jun 18 13:38:35 ip-32-0-32-123.ec2.internal derivitec-nuget[20016]: at Microsoft.AspNetCore.Server.Kestrel.KestrelConfigurationLoader.Load()
Jun 18 13:38:35 ip-32-0-32-123.ec2.internal derivitec-nuget[20016]: at Microsoft.AspNetCore.Server.Kestrel.Core.KestrelServer.ValidateOptions()
Jun 18 13:38:35 ip-32-0-32-123.ec2.internal derivitec-nuget[20016]: at Microsoft.AspNetCore.Server.Kestrel.Core.KestrelServer.StartAsync[TContext](IHttpApplication`1 application, CancellationToken cancellationToken)
Jun 18 13:38:35 ip-32-0-32-123.ec2.internal derivitec-nuget[20016]: Unhandled Exception: System.InvalidOperationException: The endpoint Http is missing the required 'Url' parameter.
Jun 18 13:38:35 ip-32-0-32-123.ec2.internal derivitec-nuget[20016]: at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.ConfigurationReader.ReadEndpoints()
Jun 18 13:38:35 ip-32-0-32-123.ec2.internal derivitec-nuget[20016]: at Microsoft.AspNetCore.Server.Kestrel.KestrelConfigurationLoader.Load()
Jun 18 13:38:35 ip-32-0-32-123.ec2.internal derivitec-nuget[20016]: at Microsoft.AspNetCore.Server.Kestrel.Core.KestrelServer.ValidateOptions()
Jun 18 13:38:35 ip-32-0-32-123.ec2.internal derivitec-nuget[20016]: at Microsoft.AspNetCore.Server.Kestrel.Core.KestrelServer.StartAsync[TContext](IHttpApplication`1 application, CancellationToken cancellationToken)
Jun 18 13:38:35 ip-32-0-32-123.ec2.internal derivitec-nuget[20016]: at Microsoft.AspNetCore.Hosting.Internal.WebHost.StartAsync(CancellationToken cancellationToken)
Jun 18 13:38:35 ip-32-0-32-123.ec2.internal derivitec-nuget[20016]: at Microsoft.AspNetCore.Hosting.WebHostExtensions.RunAsync(IWebHost host, CancellationToken token, String shutdownMessage)
Jun 18 13:38:35 ip-32-0-32-123.ec2.internal derivitec-nuget[20016]: at Microsoft.AspNetCore.Hosting.WebHostExtensions.RunAsync(IWebHost host, CancellationToken token)
Jun 18 13:38:35 ip-32-0-32-123.ec2.internal derivitec-nuget[20016]: at Microsoft.AspNetCore.Hosting.WebHostExtensions.Run(IWebHost host)
Jun 18 13:38:35 ip-32-0-32-123.ec2.internal derivitec-nuget[20016]: at McMaster.Extensions.CommandLineUtils.CommandLineApplicationExtensions.<>c__DisplayClass9_0.<OnExecute>b__0()

@guardrex
Copy link
Collaborator

hum ... interesting ... yeah, that's not what one would expect from the case change.

@HaoK will 👀 that. He may direct u to open an engineering issue. Stand-by for his reaction.

After he looks, we'll merge this anyway. It is better to match, of course, so we thank u for sending the PR.

@HaoK
Copy link
Member

HaoK commented Jun 18, 2019

This is an issue with Kestrel since its doing its own configuration binding/reading/parsing, cc @Tratcher

@HaoK
Copy link
Member

HaoK commented Jun 18, 2019

But configuration.GetSection shouldn't be case sensitive, so it must be something else that is causing the case issue

@guardrex
Copy link
Collaborator

That's what I was thinking. I feel an engineering investigation might ensue. Should @armitagemderivitec open an issue in engineering and we can just proceed to merge this for docs?

@HaoK
Copy link
Member

HaoK commented Jun 18, 2019

Yeah that's best, open an issue with the repro config and we can take a look

@guardrex
Copy link
Collaborator

@armitagemderivitec Open an issue at ...

https://github.com/aspnet/AspNetCore/issues

... and describe that. Include the stack trace.

I'll go ahead with this. We want to match the casing no matter the underlying casing issue.

@guardrex guardrex merged commit b92da62 into dotnet:master Jun 18, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants