Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Validate DC name does not contain a period #169

Closed
armon opened this issue May 22, 2014 · 7 comments
Closed

Validate DC name does not contain a period #169

armon opened this issue May 22, 2014 · 7 comments
Labels
type/enhancement Proposed improvement or new feature

Comments

@armon
Copy link
Member

armon commented May 22, 2014

DC names should match [a-zA-Z0-9-_]+

@andrewwatson
Copy link
Contributor

What should happen if it doesn't match that character class? Just drop the bad characters? Should it warn you first or fail completely?

@armon
Copy link
Member Author

armon commented Jun 8, 2014

Yeah fail the validation, agent will refuse to start.

@armon armon added this to the 0.3 milestone Jun 9, 2014
@armon armon closed this as completed in 922c21a Jun 9, 2014
@blalor
Copy link
Contributor

blalor commented Aug 4, 2014

Why was this a problem? The change is undocumented, and it just broke my Consul cluster: we were using DCs like us-east-1.aws.prod.

@blalor
Copy link
Contributor

blalor commented Aug 4, 2014

Corollary: this issue is referenced in the changelog, but the impact is not.

@armon
Copy link
Member Author

armon commented Aug 4, 2014

@blalor It should have broken the DNS parser to have a DC like that. Were you using the DNS interface at all?

We must have mistakenly failed to put it in the change log.

@blalor
Copy link
Contributor

blalor commented Aug 5, 2014

No, we weren’t using the DNS interface, yet. I see where that would cause problems, but I’d like to have seen the DC treated as an opaque string by the resolver. This also implies that dots in node names will also cause problems, correct?

@armon
Copy link
Member Author

armon commented Aug 5, 2014

I think a dot in a node name is fine. I can look into changing the resolver to remove this limitation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/enhancement Proposed improvement or new feature
Projects
None yet
Development

No branches or pull requests

3 participants