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

Add tombstone for move #652

Closed
wants to merge 2 commits into from
Closed

Add tombstone for move #652

wants to merge 2 commits into from

Conversation

osmandin
Copy link
Contributor

No description provided.

@@ -174,8 +177,17 @@ public Response moveObject(@HeaderParam("Destination") final String destinationU
throw new ClientErrorException("Destination resource already exists", PRECONDITION_FAILED);
}

final FedoraResource srcResource = nodeService.find(session, source);
final Node sourceNode = srcResource.getNode();
Copy link

Choose a reason for hiding this comment

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

We want to avoid dealing directly with JCR nodes at the fcrepo-http-api level.
Additionally, if the request to move a resource comes directly against the NodeService, we also want a tombstone to be created, i.e. tombstones are not something that only need to be created when a invocation comes through the REST-API.
I would suggest moving the tombstone creation logic into NodeService.moveObject().

Copy link
Contributor

Choose a reason for hiding this comment

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

Just to be clear about the scope in which JCR is a presence: we want to avoid dealing directly with JCR nodes anywhere except -kernel-impl. Admittedly, that's an ideal, but it's the mark against which we should be measuring.

@awoods
Copy link

awoods commented Nov 19, 2014

Resolved with: 58676ec

@awoods awoods closed this Nov 19, 2014
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.

None yet

3 participants