{"action":"created","comment":{"url":"https://api.github.com/repos/fcrepo4/fcrepo4/pulls/comments/223850009","pull_request_review_id":163066245,"id":223850009,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIyMzg1MDAwOQ==","diff_hunk":"@@ -871,14 +908,11 @@ private void checkInteractionModel(final UpdateRequest request) {\n                 deleteQuads.addAll(op.getQuads());\n             }\n \n-            final Optional<String> resIxn = INTERACTION_MODELS.stream().filter(x -> hasType(x)).findFirst();\n+            final Optional<String> resIxn = getResourceInteraction();","path":"fcrepo-kernel-modeshape/src/main/java/org/fcrepo/kernel/modeshape/FedoraResourceImpl.java","position":125,"original_position":125,"commit_id":"5e05c9fb032b4857fb04332ada74f5f893a07f6a","original_commit_id":"5e05c9fb032b4857fb04332ada74f5f893a07f6a","user":{"login":"awoods","id":149283,"node_id":"MDQ6VXNlcjE0OTI4Mw==","avatar_url":"https://avatars2.githubusercontent.com/u/149283?v=4","gravatar_id":"","url":"https://api.github.com/users/awoods","html_url":"https://github.com/awoods","followers_url":"https://api.github.com/users/awoods/followers","following_url":"https://api.github.com/users/awoods/following{/other_user}","gists_url":"https://api.github.com/users/awoods/gists{/gist_id}","starred_url":"https://api.github.com/users/awoods/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/awoods/subscriptions","organizations_url":"https://api.github.com/users/awoods/orgs","repos_url":"https://api.github.com/users/awoods/repos","events_url":"https://api.github.com/users/awoods/events{/privacy}","received_events_url":"https://api.github.com/users/awoods/received_events","type":"User","site_admin":false},"body":"You are checking for `resIxn.isPresent()` here as well as within `checkInteractionModel(triple, Optional<String>)`.\r\nCan this be more efficient/consistent?","created_at":"2018-10-09T20:24:38Z","updated_at":"2018-10-09T20:56:30Z","html_url":"https://github.com/fcrepo4/fcrepo4/pull/1442#discussion_r223850009","pull_request_url":"https://api.github.com/repos/fcrepo4/fcrepo4/pulls/1442","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/fcrepo4/fcrepo4/pulls/comments/223850009"},"html":{"href":"https://github.com/fcrepo4/fcrepo4/pull/1442#discussion_r223850009"},"pull_request":{"href":"https://api.github.com/repos/fcrepo4/fcrepo4/pulls/1442"}}},"pull_request":{"url":"https://api.github.com/repos/fcrepo4/fcrepo4/pulls/1442","id":221514850,"node_id":"MDExOlB1bGxSZXF1ZXN0MjIxNTE0ODUw","html_url":"https://github.com/fcrepo4/fcrepo4/pull/1442","diff_url":"https://github.com/fcrepo4/fcrepo4/pull/1442.diff","patch_url":"https://github.com/fcrepo4/fcrepo4/pull/1442.patch","issue_url":"https://api.github.com/repos/fcrepo4/fcrepo4/issues/1442","number":1442,"state":"open","locked":false,"title":"Prevents adding, updating, deleting predicates memento:* predicates.","user":{"login":"dbernstein","id":344939,"node_id":"MDQ6VXNlcjM0NDkzOQ==","avatar_url":"https://avatars2.githubusercontent.com/u/344939?v=4","gravatar_id":"","url":"https://api.github.com/users/dbernstein","html_url":"https://github.com/dbernstein","followers_url":"https://api.github.com/users/dbernstein/followers","following_url":"https://api.github.com/users/dbernstein/following{/other_user}","gists_url":"https://api.github.com/users/dbernstein/gists{/gist_id}","starred_url":"https://api.github.com/users/dbernstein/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dbernstein/subscriptions","organizations_url":"https://api.github.com/users/dbernstein/orgs","repos_url":"https://api.github.com/users/dbernstein/repos","events_url":"https://api.github.com/users/dbernstein/events{/privacy}","received_events_url":"https://api.github.com/users/dbernstein/received_events","type":"User","site_admin":false},"body":"**Prevents adding, updating, deleting predicates memento:* predicates.**\r\n* * *\r\n\r\n**JIRA Ticket**: https://jira.duraspace.org/browse/FCREPO-2898\r\n\r\n* Other Relevant Links (Mailing list discussion, related pull requests, etc.)\r\n\r\n# What does this Pull Request do?\r\nPrevents adding, updating, deleting predicates memento:* predicates.\r\nAdditionally, this commit refactors the handling of validations in order\r\nto reduce duplicate code and make better use of existing validation patterns.\r\nIntegration tests cover the new rejections.  Some tests are now producing 400's instead of 409's.  These changes still align with the specification.\r\n\r\n# How should this be tested?\r\nAttempting to POST, PUT, or PATCH a triple with a memento:* predicate should now fail.\r\n\r\n1. POST a resource  and verify 400 response: \r\n` curl -i -u fedoraAdmin:fedoraAdmin -X POST http://localhost:8080/rest -H \"Content-Type: text/turtle\"  --data \"<>  <http://mementoweb.org/ns#original> <http://localhost:8080/rest>  .\"`\r\n\r\n2. PUT a resource  and verify 400 response: \r\n` curl -i -u fedoraAdmin:fedoraAdmin -X PUT http://localhost:8080/rest/test -H \"Content-Type: text/turtle\"  --data \"<>  <http://mementoweb.org/ns#original> <http://localhost:8080/rest>  .\"`\r\n\r\n3. Create a resource, PATCH,   and verify 400 response: \r\n```\r\ncurl -i -u fedoraAdmin:fedoraAdmin -X PUT  http://localhost:8080/rest/test;\r\ncurl -i -u fedoraAdmin:fedoraAdmin -X PATCH  http://localhost:8080/rest/test -H \"Content-Type: application/sparql-update\"  --data \"INSERT {<>  <http://mementoweb.org/ns#original> <http://localhost:8080/rest>  . } WHERE {}\"\r\n```\r\n\r\nExample:\r\n* Does this change require documentation to be updated?  No\r\n* Does this change add any new dependencies?  No\r\n* Does this change require any other modifications to be made to the repository (ie. Regeneration activity, etc.)?  No\r\n* Could this change impact execution of existing code? Probably not.\r\n\r\n# Interested parties\r\nTag (@ mention) interested parties or, if unsure, @fcrepo4/committers\r\n","created_at":"2018-10-09T16:59:36Z","updated_at":"2018-10-09T20:56:30Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d0a54e1631403e6114b3d3e21535afbc929c3ace","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/fcrepo4/fcrepo4/pulls/1442/commits","review_comments_url":"https://api.github.com/repos/fcrepo4/fcrepo4/pulls/1442/comments","review_comment_url":"https://api.github.com/repos/fcrepo4/fcrepo4/pulls/comments{/number}","comments_url":"https://api.github.com/repos/fcrepo4/fcrepo4/issues/1442/comments","statuses_url":"https://api.github.com/repos/fcrepo4/fcrepo4/statuses/5e05c9fb032b4857fb04332ada74f5f893a07f6a","head":{"label":"dbernstein:fcrepo-2898","ref":"fcrepo-2898","sha":"5e05c9fb032b4857fb04332ada74f5f893a07f6a","user":{"login":"dbernstein","id":344939,"node_id":"MDQ6VXNlcjM0NDkzOQ==","avatar_url":"https://avatars2.githubusercontent.com/u/344939?v=4","gravatar_id":"","url":"https://api.github.com/users/dbernstein","html_url":"https://github.com/dbernstein","followers_url":"https://api.github.com/users/dbernstein/followers","following_url":"https://api.github.com/users/dbernstein/following{/other_user}","gists_url":"https://api.github.com/users/dbernstein/gists{/gist_id}","starred_url":"https://api.github.com/users/dbernstein/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dbernstein/subscriptions","organizations_url":"https://api.github.com/users/dbernstein/orgs","repos_url":"https://api.github.com/users/dbernstein/repos","events_url":"https://api.github.com/users/dbernstein/events{/privacy}","received_events_url":"https://api.github.com/users/dbernstein/received_events","type":"User","site_admin":false},"repo":{"id":70508115,"node_id":"MDEwOlJlcG9zaXRvcnk3MDUwODExNQ==","name":"fcrepo4","full_name":"dbernstein/fcrepo4","private":false,"owner":{"login":"dbernstein","id":344939,"node_id":"MDQ6VXNlcjM0NDkzOQ==","avatar_url":"https://avatars2.githubusercontent.com/u/344939?v=4","gravatar_id":"","url":"https://api.github.com/users/dbernstein","html_url":"https://github.com/dbernstein","followers_url":"https://api.github.com/users/dbernstein/followers","following_url":"https://api.github.com/users/dbernstein/following{/other_user}","gists_url":"https://api.github.com/users/dbernstein/gists{/gist_id}","starred_url":"https://api.github.com/users/dbernstein/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dbernstein/subscriptions","organizations_url":"https://api.github.com/users/dbernstein/orgs","repos_url":"https://api.github.com/users/dbernstein/repos","events_url":"https://api.github.com/users/dbernstein/events{/privacy}","received_events_url":"https://api.github.com/users/dbernstein/received_events","type":"User","site_admin":false},"html_url":"https://github.com/dbernstein/fcrepo4","description":"Fedora 4","fork":true,"url":"https://api.github.com/repos/dbernstein/fcrepo4","forks_url":"https://api.github.com/repos/dbernstein/fcrepo4/forks","keys_url":"https://api.github.com/repos/dbernstein/fcrepo4/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dbernstein/fcrepo4/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dbernstein/fcrepo4/teams","hooks_url":"https://api.github.com/repos/dbernstein/fcrepo4/hooks","issue_events_url":"https://api.github.com/repos/dbernstein/fcrepo4/issues/events{/number}","events_url":"https://api.github.com/repos/dbernstein/fcrepo4/events","assignees_url":"https://api.github.com/repos/dbernstein/fcrepo4/assignees{/user}","branches_url":"https://api.github.com/repos/dbernstein/fcrepo4/branches{/branch}","tags_url":"https://api.github.com/repos/dbernstein/fcrepo4/tags","blobs_url":"https://api.github.com/repos/dbernstein/fcrepo4/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dbernstein/fcrepo4/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dbernstein/fcrepo4/git/refs{/sha}","trees_url":"https://api.github.com/repos/dbernstein/fcrepo4/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dbernstein/fcrepo4/statuses/{sha}","languages_url":"https://api.github.com/repos/dbernstein/fcrepo4/languages","stargazers_url":"https://api.github.com/repos/dbernstein/fcrepo4/stargazers","contributors_url":"https://api.github.com/repos/dbernstein/fcrepo4/contributors","subscribers_url":"https://api.github.com/repos/dbernstein/fcrepo4/subscribers","subscription_url":"https://api.github.com/repos/dbernstein/fcrepo4/subscription","commits_url":"https://api.github.com/repos/dbernstein/fcrepo4/commits{/sha}","git_commits_url":"https://api.github.com/repos/dbernstein/fcrepo4/git/commits{/sha}","comments_url":"https://api.github.com/repos/dbernstein/fcrepo4/comments{/number}","issue_comment_url":"https://api.github.com/repos/dbernstein/fcrepo4/issues/comments{/number}","contents_url":"https://api.github.com/repos/dbernstein/fcrepo4/contents/{+path}","compare_url":"https://api.github.com/repos/dbernstein/fcrepo4/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dbernstein/fcrepo4/merges","archive_url":"https://api.github.com/repos/dbernstein/fcrepo4/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dbernstein/fcrepo4/downloads","issues_url":"https://api.github.com/repos/dbernstein/fcrepo4/issues{/number}","pulls_url":"https://api.github.com/repos/dbernstein/fcrepo4/pulls{/number}","milestones_url":"https://api.github.com/repos/dbernstein/fcrepo4/milestones{/number}","notifications_url":"https://api.github.com/repos/dbernstein/fcrepo4/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dbernstein/fcrepo4/labels{/name}","releases_url":"https://api.github.com/repos/dbernstein/fcrepo4/releases{/id}","deployments_url":"https://api.github.com/repos/dbernstein/fcrepo4/deployments","created_at":"2016-10-10T16:42:42Z","updated_at":"2018-10-09T16:26:05Z","pushed_at":"2018-10-09T16:26:00Z","git_url":"git://github.com/dbernstein/fcrepo4.git","ssh_url":"git@github.com:dbernstein/fcrepo4.git","clone_url":"https://github.com/dbernstein/fcrepo4.git","svn_url":"https://github.com/dbernstein/fcrepo4","homepage":"https://wiki.duraspace.org/display/FF/Fedora+Repository+Home","size":87127,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"fcrepo4:master","ref":"master","sha":"d6c5b45501ed08be6998f0a34c493590ad4dfe7d","user":{"login":"fcrepo4","id":3057565,"node_id":"MDEyOk9yZ2FuaXphdGlvbjMwNTc1NjU=","avatar_url":"https://avatars2.githubusercontent.com/u/3057565?v=4","gravatar_id":"","url":"https://api.github.com/users/fcrepo4","html_url":"https://github.com/fcrepo4","followers_url":"https://api.github.com/users/fcrepo4/followers","following_url":"https://api.github.com/users/fcrepo4/following{/other_user}","gists_url":"https://api.github.com/users/fcrepo4/gists{/gist_id}","starred_url":"https://api.github.com/users/fcrepo4/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fcrepo4/subscriptions","organizations_url":"https://api.github.com/users/fcrepo4/orgs","repos_url":"https://api.github.com/users/fcrepo4/repos","events_url":"https://api.github.com/users/fcrepo4/events{/privacy}","received_events_url":"https://api.github.com/users/fcrepo4/received_events","type":"Organization","site_admin":false},"repo":{"id":7992797,"node_id":"MDEwOlJlcG9zaXRvcnk3OTkyNzk3","name":"fcrepo4","full_name":"fcrepo4/fcrepo4","private":false,"owner":{"login":"fcrepo4","id":3057565,"node_id":"MDEyOk9yZ2FuaXphdGlvbjMwNTc1NjU=","avatar_url":"https://avatars2.githubusercontent.com/u/3057565?v=4","gravatar_id":"","url":"https://api.github.com/users/fcrepo4","html_url":"https://github.com/fcrepo4","followers_url":"https://api.github.com/users/fcrepo4/followers","following_url":"https://api.github.com/users/fcrepo4/following{/other_user}","gists_url":"https://api.github.com/users/fcrepo4/gists{/gist_id}","starred_url":"https://api.github.com/users/fcrepo4/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fcrepo4/subscriptions","organizations_url":"https://api.github.com/users/fcrepo4/orgs","repos_url":"https://api.github.com/users/fcrepo4/repos","events_url":"https://api.github.com/users/fcrepo4/events{/privacy}","received_events_url":"https://api.github.com/users/fcrepo4/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/fcrepo4/fcrepo4","description":"Fedora 4","fork":false,"url":"https://api.github.com/repos/fcrepo4/fcrepo4","forks_url":"https://api.github.com/repos/fcrepo4/fcrepo4/forks","keys_url":"https://api.github.com/repos/fcrepo4/fcrepo4/keys{/key_id}","collaborators_url":"https://api.github.com/repos/fcrepo4/fcrepo4/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/fcrepo4/fcrepo4/teams","hooks_url":"https://api.github.com/repos/fcrepo4/fcrepo4/hooks","issue_events_url":"https://api.github.com/repos/fcrepo4/fcrepo4/issues/events{/number}","events_url":"https://api.github.com/repos/fcrepo4/fcrepo4/events","assignees_url":"https://api.github.com/repos/fcrepo4/fcrepo4/assignees{/user}","branches_url":"https://api.github.com/repos/fcrepo4/fcrepo4/branches{/branch}","tags_url":"https://api.github.com/repos/fcrepo4/fcrepo4/tags","blobs_url":"https://api.github.com/repos/fcrepo4/fcrepo4/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/fcrepo4/fcrepo4/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/fcrepo4/fcrepo4/git/refs{/sha}","trees_url":"https://api.github.com/repos/fcrepo4/fcrepo4/git/trees{/sha}","statuses_url":"https://api.github.com/repos/fcrepo4/fcrepo4/statuses/{sha}","languages_url":"https://api.github.com/repos/fcrepo4/fcrepo4/languages","stargazers_url":"https://api.github.com/repos/fcrepo4/fcrepo4/stargazers","contributors_url":"https://api.github.com/repos/fcrepo4/fcrepo4/contributors","subscribers_url":"https://api.github.com/repos/fcrepo4/fcrepo4/subscribers","subscription_url":"https://api.github.com/repos/fcrepo4/fcrepo4/subscription","commits_url":"https://api.github.com/repos/fcrepo4/fcrepo4/commits{/sha}","git_commits_url":"https://api.github.com/repos/fcrepo4/fcrepo4/git/commits{/sha}","comments_url":"https://api.github.com/repos/fcrepo4/fcrepo4/comments{/number}","issue_comment_url":"https://api.github.com/repos/fcrepo4/fcrepo4/issues/comments{/number}","contents_url":"https://api.github.com/repos/fcrepo4/fcrepo4/contents/{+path}","compare_url":"https://api.github.com/repos/fcrepo4/fcrepo4/compare/{base}...{head}","merges_url":"https://api.github.com/repos/fcrepo4/fcrepo4/merges","archive_url":"https://api.github.com/repos/fcrepo4/fcrepo4/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/fcrepo4/fcrepo4/downloads","issues_url":"https://api.github.com/repos/fcrepo4/fcrepo4/issues{/number}","pulls_url":"https://api.github.com/repos/fcrepo4/fcrepo4/pulls{/number}","milestones_url":"https://api.github.com/repos/fcrepo4/fcrepo4/milestones{/number}","notifications_url":"https://api.github.com/repos/fcrepo4/fcrepo4/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/fcrepo4/fcrepo4/labels{/name}","releases_url":"https://api.github.com/repos/fcrepo4/fcrepo4/releases{/id}","deployments_url":"https://api.github.com/repos/fcrepo4/fcrepo4/deployments","created_at":"2013-02-03T16:18:55Z","updated_at":"2018-10-09T15:38:38Z","pushed_at":"2018-10-09T16:59:37Z","git_url":"git://github.com/fcrepo4/fcrepo4.git","ssh_url":"git@github.com:fcrepo4/fcrepo4.git","clone_url":"https://github.com/fcrepo4/fcrepo4.git","svn_url":"https://github.com/fcrepo4/fcrepo4","homepage":"https://wiki.duraspace.org/display/FF/Fedora+Repository+Home","size":102163,"stargazers_count":109,"watchers_count":109,"language":"Java","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":106,"mirror_url":null,"archived":false,"open_issues_count":17,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":106,"open_issues":17,"watchers":109,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/fcrepo4/fcrepo4/pulls/1442"},"html":{"href":"https://github.com/fcrepo4/fcrepo4/pull/1442"},"issue":{"href":"https://api.github.com/repos/fcrepo4/fcrepo4/issues/1442"},"comments":{"href":"https://api.github.com/repos/fcrepo4/fcrepo4/issues/1442/comments"},"review_comments":{"href":"https://api.github.com/repos/fcrepo4/fcrepo4/pulls/1442/comments"},"review_comment":{"href":"https://api.github.com/repos/fcrepo4/fcrepo4/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/fcrepo4/fcrepo4/pulls/1442/commits"},"statuses":{"href":"https://api.github.com/repos/fcrepo4/fcrepo4/statuses/5e05c9fb032b4857fb04332ada74f5f893a07f6a"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"awoods"}}