[
https://issues.apache.org/jira/browse/ARROW-1927?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16293996#comment-16293996
]
ASF GitHub Bot commented on ARROW-1927:
---------------------------------------
pcmoritz commented on a change in pull request #1427: ARROW-1927: [Plasma] Add
delete function
URL: https://github.com/apache/arrow/pull/1427#discussion_r157356867
##########
File path: cpp/src/plasma/client.cc
##########
@@ -501,9 +501,19 @@ Status PlasmaClient::Abort(const ObjectID& object_id) {
}
Status PlasmaClient::Delete(const ObjectID& object_id) {
- // TODO(rkn): In the future, we can use this method to give hints to the
- // eviction policy about when an object will no longer be needed.
- return Status::NotImplemented("PlasmaClient::Delete is not implemented.");
+ // If the object is in used, client can't send the remove message.
+ if (objects_in_use_.count(object_id) > 0) {
+ return Status::UnknownError("PlasmaClient::Object is in used.");
Review comment:
Shall we create a custom error for this so it can be caught in Python?
cc @wesm
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
> [Plasma] Implement delete function
> ----------------------------------
>
> Key: ARROW-1927
> URL: https://issues.apache.org/jira/browse/ARROW-1927
> Project: Apache Arrow
> Issue Type: Improvement
> Components: Plasma (C++), Python
> Reporter: Philipp Moritz
> Labels: pull-request-available
>
> The function should check if the reference count of the object is zero and if
> yes, delete it from the store. If no, it should raise an exception or return
> a status value.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)