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

[FEATURE REQUEST] Canonical URLs for projects & organizations #730

Open
mrbobbytables opened this issue Oct 21, 2024 · 5 comments
Open

[FEATURE REQUEST] Canonical URLs for projects & organizations #730

mrbobbytables opened this issue Oct 21, 2024 · 5 comments
Labels
enhancement New feature or request

Comments

@mrbobbytables
Copy link
Member

Following up on a conversation in Slack. Currently projects & organizations do not have a canonical url.
Currently the unique ID is generated from a combination of item id by prefixing the name with the category and subcategory names.
This makes it difficult to reference the landscape as a source of truth, or if we want to crosslink with other CNCF sites or embed in project pages.

This would require some clean-up, but one potential idea might be to give each item a :slug: and that could server as the canonical reference. If there is more than one or ones that are similar they'd need some other differentiator.

We could have some general guidelines like projects are prefixed with project (e.g. project-kubeflow), or vendor services like GKE would be prefixed with the vendor name google-gke

Thoughts? would there be a better way to go about doing it?

@mrbobbytables mrbobbytables added the enhancement New feature or request label Oct 21, 2024
@tegioz
Copy link
Collaborator

tegioz commented Oct 22, 2024

Hi @mrbobbytables

Adding a slug field to the items and use it as the item identifier wouldn't be a problem, we can do that. We would still need to fallback to the current item id format when the slug wasn't provided though.

Another approach could be to add a new landscape setting to require items names to be unique across the whole landscape. This would allow us to use a normalized version of the item name as the unique identifier. Going this way could also help us solve some other related problems.

At the moment (in the CNCF landscape), when the same item needs to be added to multiple groups or categories, it's often duplicated and copied over to the new category where it's needed. Sometimes the item name is slightly modified (i.e. with a suffix) and other times it's exactly the same. But duplicating items creates some problems:

  • Stats are not fully accurate
  • Duplicates are displayed in some reports (see Dapr, for example) and search results
  • It makes it harder to keep entries up-to-date in the landscape.yml file, complicating its maintenance
  • The item name cannot be used as a unique id, which could be used in items' urls

The landscapes generator allows providing additional categories / subcategories for items. My suggestion would be to leverage this feature and get rid of the duplicates. There are just a handful of them, and they can be easily spotted in the items.csv file available on the landscape UI.

On the landscapes generator side, we could update the tool [1] to:

  • Allow enforcing items names to be unique across the landscape
  • Generate the item id from the item name when names are guaranteed to be unique (feature described above enabled)

On the cncf/landscape repo, we should probably update the PR template to encourage folks to review if any of the items they'd like to add already exists, and use the additional category approach when applicable instead of duplicating.

[1] Please note that this tool is used to generate multiple landscapes across the Linux Foundation, and probably many more out there, so we need to be mindful about any breaking change we introduce 🙂

@mrbobbytables
Copy link
Member Author

I've deduped a good chunk of them - theres a few where having a separate entry is valid as it links to a different repo than the main one -_-

Anyway here's the PR: cncf/landscape#4114

@tegioz
Copy link
Collaborator

tegioz commented Nov 4, 2024

Thanks @mrbobbytables! It looks great 🙂

Would it be possible to add those different repositories as additional ones to a single deduped landscape item? We won't be able to rely on the name as a unique identifier unless we can deduplicate them all.

@mrbobbytables
Copy link
Member Author

@tegioz yeah, we should be able to do that 👍
that will be a later thing^^;; just trying to get what I can done before KubeCon lol

@tegioz
Copy link
Collaborator

tegioz commented Nov 4, 2024

Awesome 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants