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

Let mirrors specify multiple countries #268

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

mdomsch
Copy link
Contributor

@mdomsch mdomsch commented May 10, 2019

#267
requests the ability for a mirror (really, a globally load balanced
set of mirrors behind a single DNS name) to be able to specify the
countries of their actual mirrors.

This patch lets Host.country be a comma-separated list of countries.

fedora-infra#267
requests the ability for a mirror (really, a globally load balanced
set of mirrors behind a single DNS name) to be able to specify the
countries of their actual mirrors.

This patch lets Host.country be a comma-separated list of countries.

Signed-off-by: Matt Domsch <[email protected]>
@mdomsch mdomsch force-pushed the mirror-in-multiple-countries branch from 6e00f98 to 106eaf6 Compare May 10, 2019 04:52
@ott
Copy link
Contributor

ott commented Dec 30, 2021

I think this is a useful feature, in particular for smaller countries and for people who live in a border region. Several use cases in Europe come to mind. However, I think it would be preferred in the relational model to make the country column a table instead of a comma separated string. Only smaller changes would be required for it to add a model definition and migration the current data.

@mdomsch What do you think about this idea? And are you still interested in this pull request? If not, I would try to adopt it.

@mdomsch
Copy link
Contributor Author

mdomsch commented Dec 30, 2021

I'm not directly involved in mirrormanager maintenance anymore. The current maintainers would be in a better position to comment as to the direction they want to see here (if any).

@abompard abompard force-pushed the master branch 4 times, most recently from 861f200 to d9d0078 Compare July 12, 2024 10:19
@ott
Copy link
Contributor

ott commented Aug 16, 2024

@abompard I would volunteer to update this pull request. Can you briefly comment on how you would like the database schema to be for multiple countries, so that I can work in the right direction?

As mentioned, I would suggest a separate n:m relation between hosts and countries.

@abompard
Copy link
Member

Hey! It looks like hosts and countries are already linked by a relationship table: HostCountry. So, hosts can already have multiple countries. Am I missing something? (I only did maintenance on the code a few months ago, I'm not aware of all use cases).

@abompard
Copy link
Member

Ah, I see, there's a confusion between HostCountry and HostCountryAllowed in the UI. The list of allowed countries in the host form populates the .countries attribute, which is for HostCountry, not HostCountryAllowed. This needs to be fixed.

@ott
Copy link
Contributor

ott commented Aug 19, 2024

I'm not sure whether I understand the original intent of the data model but I think there is a bigger mismatch between the data model and its usage:

I agree that the form seems to be intended to add entries to HostCountryAllowed but adds them to HostCountry. Most likely the current entries would need to be migrated, perhaps even by hand as there might already be entries in HostCountryAllowed or entries in HostCountry were created in mirrormanager v1 with different semantics.

In addition this pull request points out and tries to address defect that the ByCountry and ByCountryInternet2 caches are created from the attribute country of Host. It seems that the intention of HostCountry was that a host could be designated to serve multiple countries and not just the country in which it is located. This would be useful in Europe, for example, in Luxembourg, which has three neighbouring countries and is well connected to Frankfurt am Main, or in Southeast Europe.

In addition, there might be anycast, DNS load balancing or Geo DNS mirror servers which are located in multiple countries as the description of this pull request points out. So the country attribute cannot represent the multiple locations of such mirror servers as they would need a multiple-valued attribute which would have to be implemented as a weak entity.

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