Skip to content

Conversation

costasd
Copy link
Contributor

@costasd costasd commented Jun 14, 2025

This changeset splits the existing provider code into multiple files to enhance readability.

While there, fix also a couple minor tidbits observed during the split:

  • Use the GetZone() that handles api timeouts in GetNameservers
  • Merge a runaway capability to the rest of the capabilities

@tlimoncelli
Copy link
Collaborator

Very interesting!

Just the other day I was thinking that it would be useful to create a standard set of filenames to use for providers. I really like your name scheme.

The name scheme I had come up with was based on interfaces, not type of work. (see #3611 ).

I'd be interested in any feedback about what the new standard should be.

@costasd
Copy link
Contributor Author

costasd commented Jun 26, 2025

ah nice! Originally I was trying to do something more similar to #3611 - essentially splitting by the interfaces but it proved too complicated for a simple reorg, as the NS1 code doesn't separate concerns that clearly. So I went with something closer to what namedotcom, hexonet and gcore do instead - essentially splitting by the type of work.

Going back now, it seems more natural to me when implementing or reading a provider that you'll go and start implementing step-by-step: let's do the registrar, then the zones, then the records etc. No strong opinions though.

@tlimoncelli
Copy link
Collaborator

Yeah, I have no strong opinions here either. I do notice that some functions appear in 2 different interfaces, which makes my proposal not work as well. On the other hand, we could just document which place the function should appear.

@tlimoncelli
Copy link
Collaborator

After much consideration... I prefer your format. Merging.

@tlimoncelli tlimoncelli merged commit 75821a8 into StackExchange:main Jul 10, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants