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

Added properly error message for system to system container copy #2883

Open
wants to merge 7 commits into
base: main
Choose a base branch
from

Conversation

dphulkar-msft
Copy link
Collaborator

@dphulkar-msft dphulkar-msft commented Nov 28, 2024

Description

Customers attempt to copy $blobchangefeed in a source to $blobchangefeed in a destination.

  • Feature / Bug Fix: (Brief description of the feature or issue being addressed)
    We should allow copy of system containers to non-system containers, but need better error messaging for system container to system container copies when customers try to execute
    sysContainerBug

  • Related Links:

  • Issues

  • Team thread

  • Documents

  • [Email Subject]

Type of Change

  • Bug fix
  • New feature
  • Documentation update required
  • Code quality improvement
  • Other (describe):

How Has This Been Tested?

Manual Testing
sysContainerCopy

sysContainerSync

Thank you for your contribution to AzCopy!

if cca.FromTo.IsS2S() {
dstContainerName, err := GetContainerName(cca.Destination.Value, cca.FromTo.To())
if err != nil {
return fmt.Errorf("failed to get container name from destination (is it formatted correctly?)")
Copy link
Collaborator

Choose a reason for hiding this comment

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

should we add the err with %w to the print statement?

// @brief Thia API check if the container name provided is a system container or not
func IsSystemContainer(containerName string) bool {
// define the system variables for the system containers
systemContainers := []string{"$blobchangefeed", "$logs"}
Copy link
Member

Choose a reason for hiding this comment

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

These containers as destination of copy shall be errored out but as source it shall still work. Add test cases around such combinations in E2E

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.

4 participants