Skip to content

Clarify error message about multiple datastores #4692

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

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

Conversation

europaul
Copy link
Contributor

EVE currently doens't support multiple datastores for OCI images. This commit adds a more descriptive error message to the error that is returned when multiple datastores are detected.

For reasons behind this limitation, see commit
34ae228

EVE currently doens't support multiple datastores for OCI images. This
commit adds a more descriptive error message to the error that is
returned when multiple datastores are detected.

For reasons behind this limitation, see commit
34ae228

Signed-off-by: Paul Gaiduk <[email protected]>
Copy link
Contributor

@eriknordmark eriknordmark left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Re-reading the old commit you cited, I think it is overly conservative.
The logic in it assumes that if one datastore is an OCI registry then all of them should be, but it doesn't explicitly check for that but instead checks that there is only one.

I don't think it would be hard to fix that by checking that all or none are OCI. Can you look into this as an alternative approach?

@OhmSpectator OhmSpectator requested a review from Copilot April 7, 2025 12:11
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot reviewed 1 out of 1 changed files in this pull request and generated 1 comment.

@@ -34,7 +34,7 @@ func doUpdateContentTree(ctx *volumemgrContext, status *types.ContentTreeStatus)

if status.IsOCIRegistry {
if len(status.DatastoreIDList) > 1 {
err := fmt.Sprintf("doUpdateContentTree(%s) name %s: OCI registry along with the fallback datastores list is not supported",
err := fmt.Sprintf("doUpdateContentTree(%s) name %s: EVE doesn't support multiple datastores for OCI registry. Please use only one datastore",
Copy link
Preview

Copilot AI Apr 7, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The error message now uses 'OCI registry', but the PR title and description reference OCI images; consider aligning the terminology for consistency.

Suggested change
err := fmt.Sprintf("doUpdateContentTree(%s) name %s: EVE doesn't support multiple datastores for OCI registry. Please use only one datastore",
err := fmt.Sprintf("doUpdateContentTree(%s) name %s: EVE doesn't support multiple datastores for OCI images. Please use only one datastore",

Copilot uses AI. Check for mistakes.

Copy link
Member

@OhmSpectator OhmSpectator left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@europaul what's the status of this PR?

@europaul
Copy link
Contributor Author

I'm going to do what @eriknordmark suggested, but I haven't started yet.

@OhmSpectator
Copy link
Member

I'm going to do what @eriknordmark suggested, but I haven't started yet.

Got it, thanks for the clarification!

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