-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
[C++][FS][Azure] Remove StatusFromErrorResponse as it's not necessary #39718
Comments
felipecrv
added a commit
that referenced
this issue
Jan 22, 2024
… necessary (#39719) ### Rationale for this change Only the "*IfExists" functions from the Azure SDK ever set `response.Value.Deleted` to `false` to indicate that a resource wasn't found and the request succeeded without deleting anything. It's better that we use the `Delete()` versions of these functions instead of `DeleteIfExists` and check the `ErrorCode` ourselves to return an appropriate `Status` instead of something generic. ### What changes are included in this PR? - Removing `StatusFromErrorResponse` - Comments explaining the error handling decisions - Addition of a boolean parameter to `DeleteDirOnFileSystem` that controls how it fails when the directory being deleted doesn't exist ### Are these changes tested? - Yes, by the existing tests in `azurefs_test.cc`. * Closes: #39718 Authored-by: Felipe Oliveira Carvalho <[email protected]> Signed-off-by: Felipe Oliveira Carvalho <[email protected]>
dgreiss
pushed a commit
to dgreiss/arrow
that referenced
this issue
Feb 19, 2024
…'s not necessary (apache#39719) ### Rationale for this change Only the "*IfExists" functions from the Azure SDK ever set `response.Value.Deleted` to `false` to indicate that a resource wasn't found and the request succeeded without deleting anything. It's better that we use the `Delete()` versions of these functions instead of `DeleteIfExists` and check the `ErrorCode` ourselves to return an appropriate `Status` instead of something generic. ### What changes are included in this PR? - Removing `StatusFromErrorResponse` - Comments explaining the error handling decisions - Addition of a boolean parameter to `DeleteDirOnFileSystem` that controls how it fails when the directory being deleted doesn't exist ### Are these changes tested? - Yes, by the existing tests in `azurefs_test.cc`. * Closes: apache#39718 Authored-by: Felipe Oliveira Carvalho <[email protected]> Signed-off-by: Felipe Oliveira Carvalho <[email protected]>
zanmato1984
pushed a commit
to zanmato1984/arrow
that referenced
this issue
Feb 28, 2024
…'s not necessary (apache#39719) ### Rationale for this change Only the "*IfExists" functions from the Azure SDK ever set `response.Value.Deleted` to `false` to indicate that a resource wasn't found and the request succeeded without deleting anything. It's better that we use the `Delete()` versions of these functions instead of `DeleteIfExists` and check the `ErrorCode` ourselves to return an appropriate `Status` instead of something generic. ### What changes are included in this PR? - Removing `StatusFromErrorResponse` - Comments explaining the error handling decisions - Addition of a boolean parameter to `DeleteDirOnFileSystem` that controls how it fails when the directory being deleted doesn't exist ### Are these changes tested? - Yes, by the existing tests in `azurefs_test.cc`. * Closes: apache#39718 Authored-by: Felipe Oliveira Carvalho <[email protected]> Signed-off-by: Felipe Oliveira Carvalho <[email protected]>
thisisnic
pushed a commit
to thisisnic/arrow
that referenced
this issue
Mar 8, 2024
…'s not necessary (apache#39719) ### Rationale for this change Only the "*IfExists" functions from the Azure SDK ever set `response.Value.Deleted` to `false` to indicate that a resource wasn't found and the request succeeded without deleting anything. It's better that we use the `Delete()` versions of these functions instead of `DeleteIfExists` and check the `ErrorCode` ourselves to return an appropriate `Status` instead of something generic. ### What changes are included in this PR? - Removing `StatusFromErrorResponse` - Comments explaining the error handling decisions - Addition of a boolean parameter to `DeleteDirOnFileSystem` that controls how it fails when the directory being deleted doesn't exist ### Are these changes tested? - Yes, by the existing tests in `azurefs_test.cc`. * Closes: apache#39718 Authored-by: Felipe Oliveira Carvalho <[email protected]> Signed-off-by: Felipe Oliveira Carvalho <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Describe the enhancement requested
Only the "*IfExists" functions from the Azure SDK ever set
response.Value.Deleted
tofalse
to indicate that a resource wasn't found and the request succeeded without deleting anything.This is the implementation of
DataLakePathClient::DeleteIfExists
:It's better that we use the
Delete()
versions of these functions instead ofDeleteIfExists
and check theErrorCode
ourselves to return an appropriateStatus
instead of something generic.Component(s)
C++
The text was updated successfully, but these errors were encountered: