Skip to content
New issue

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

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

Already on GitHub? # to your account

Cloud instance name should allow leading numerics #420

Closed
fantix opened this issue Mar 6, 2023 · 2 comments · Fixed by #423
Closed

Cloud instance name should allow leading numerics #420

fantix opened this issue Mar 6, 2023 · 2 comments · Fixed by #423
Assignees

Comments

@fantix
Copy link
Member

fantix commented Mar 6, 2023

1st1/test or fantix/1st1test should be accepted as valid instance names.

  • Regexp: ^(\w(?:\w|-(?=\w))*)(?:/(\w(?:\w|-(?=\w))*))?$
  • Total length should not be greater than 62 if / (inclusive) is present, so that the translated cloud domain label inst--org is no longer than 63 letters.
  • Don't narrow the limit on local instance names
@zackelan
Copy link

zackelan commented Mar 7, 2023

this has an unofficial but legit-looking regex for org slug. the "no consecutive hyphens" and "can't start or end with a hyphen" requirements may not be relevant for our regex because we shouldn't ever see a Github user with that name...but it does mean that we can safely treat -- as an internal DNS name separator because it will never appear in a org name.

I think cloud & local instance names should have identical requirements unless there's a very good reason to make them separate. if I have a local instance and want to migrate it to be hosted in the cloud, it would be annoying friction to be required to make up a new instance name as well

@fantix
Copy link
Member Author

fantix commented Mar 20, 2023

I think cloud & local instance names should have identical requirements unless there's a very good reason to make them separate. if I have a local instance and want to migrate it to be hosted in the cloud, it would be annoying friction to be required to make up a new instance name as well

With the updates from the discussion, this is not valid any more because:

  1. Local instance names may have underscores _ and we don't want to narrow down the existing limit
  2. Cloud instance names must not have underscores

The best we can do now is to allow single dashes - in local instance names like the cloud names (and leave underscores be).

fantix added a commit that referenced this issue May 26, 2023
Changes
=======

* Update for rules of instance names (#423)
  (by @fantix in 5bc5699 for #420)

* Synchronize error types (#429)
  (by @fantix in 03e4012)

* Allow enums in array codec (#431)
  (by @fantix in 2de7e3f for #408)

* Prohibit concurrent operations on the same transaction object (#430)
  (by @fantix in f1fa612 for #130)

* Fix state of transaction start (#424)
  (by @fantix in 297de72)

* codegen: Handle non-identifier characters in enum values (#432)
  (by @fantix in e1ec16d for #428)

Docs
====

* docs: add Code Generation to table of contents (#421)
  (by @AndreasPB in ffe74a1 for #421)
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants