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

Rdf iteration for mutation3 #137

Closed
wants to merge 6 commits into from
Closed

Rdf iteration for mutation3 #137

wants to merge 6 commits into from

Conversation

ajs6f
Copy link
Contributor

@ajs6f ajs6f commented Nov 1, 2013

Last interim PR for this saga before Austin, where we'll refactor the epic.

try {
final FedoraResource resource =
nodeService.getObject(session, path);
final FedoraResource resource = nodeService.getObject(session, path);
Copy link

Choose a reason for hiding this comment

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

If the arg path does not exist, the top-level exception handler will not return the wanted 404, will it?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Looking at the unedited, it never could have. +1 to our integration tests for catching that boo-boo! Wait, no, they didn't. I'll add it in when I get a chance.

Copy link

Choose a reason for hiding this comment

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

Are you saying

  • that the path can never be bad? or
  • that the response will be 404? or
  • that it did not work right before and still will not work right? or
  • something else?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The third. And what's more, we didn't know it and it was only because you happened to review a change to it that we found out.

Copy link

Choose a reason for hiding this comment

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

If you are not inclined to fix it now, could you please add a ticket at least, and we can push this branch in.
Thanks.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Now I'm not sure. Won't the PathNotFoundExceptionMapper handle this? Is that why we never saw a problem before?

Copy link

Choose a reason for hiding this comment

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

A quick test indicates you are correct:
curl -v http://localhost:8080/rest/junk/fcr:versions

Let's ship it.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Okay, but I stand by every word of my snarky ranting about i-tests.

@awoods
Copy link

awoods commented Nov 1, 2013

Nice job with the Futures and Callback.

@ajs6f
Copy link
Contributor Author

ajs6f commented Nov 1, 2013

It's not obvious what happens there, especially in a transactional context. IOW, it works, but it doesn't help people understand itself. There's probably a factoring there to bring some of that stuff out into the type system where it can be more effectively tested/documented.

@awoods
Copy link

awoods commented Nov 1, 2013

Resolved with:
0364678

@awoods awoods closed this Nov 1, 2013
@awoods awoods deleted the RDFIterationForMutation3 branch November 1, 2013 19:46
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

2 participants