{"action":"created","comment":{"url":"https://api.github.com/repos/yahoo/elide/pulls/comments/42399996","id":42399996,"diff_hunk":"@@ -0,0 +1,102 @@\n+package com.yahoo.elide.dbmanagers.hibernate5;\n+\n+import com.yahoo.elide.core.DatabaseManager;\n+import com.yahoo.elide.core.DatabaseTransaction;\n+import com.yahoo.elide.core.EntityDictionary;\n+import com.yahoo.elide.security.User;\n+\n+import javax.persistence.EntityManager;\n+import javax.persistence.EntityManagerFactory;\n+import javax.persistence.metamodel.EntityType;\n+import java.io.IOException;\n+\n+/**\n+ * Manager for javax.persistence compatible db resource\n+ */\n+public class PersistenceManager extends DatabaseManager {\n+    private final EntityManagerFactory entityManagerFactory;\n+\n+    public PersistenceManager(EntityManagerFactory entityManagerFactory) {\n+        this.entityManagerFactory = entityManagerFactory;\n+    }\n+\n+    @Override\n+    public void populateEntityDictionary(EntityDictionary dictionary) {\n+        for (EntityType entity : entityManagerFactory.getMetamodel().getEntities()) {","path":"elide-dbmanager/elide-dbmanager-hibernate5/src/main/java/com/yahoo/elide/dbmanagers/hibernate5/PersistenceManager.java","position":25,"original_position":25,"commit_id":"4e3e89a8dc70b74f18a201309297feadbe87500f","original_commit_id":"4e3e89a8dc70b74f18a201309297feadbe87500f","user":{"login":"shadanan","id":361429,"avatar_url":"https://avatars.githubusercontent.com/u/361429?v=3","gravatar_id":"","url":"https://api.github.com/users/shadanan","html_url":"https://github.com/shadanan","followers_url":"https://api.github.com/users/shadanan/followers","following_url":"https://api.github.com/users/shadanan/following{/other_user}","gists_url":"https://api.github.com/users/shadanan/gists{/gist_id}","starred_url":"https://api.github.com/users/shadanan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shadanan/subscriptions","organizations_url":"https://api.github.com/users/shadanan/orgs","repos_url":"https://api.github.com/users/shadanan/repos","events_url":"https://api.github.com/users/shadanan/events{/privacy}","received_events_url":"https://api.github.com/users/shadanan/received_events","type":"User","site_admin":false},"body":"It doesn't seem to be easy to get those to be null. I tried removing the classes from the persistence.xml file, and we just get back an empty entities set.","created_at":"2015-10-19T17:27:07Z","updated_at":"2015-10-19T17:27:07Z","html_url":"https://github.com/yahoo/elide/pull/12#discussion_r42399996","pull_request_url":"https://api.github.com/repos/yahoo/elide/pulls/12","_links":{"self":{"href":"https://api.github.com/repos/yahoo/elide/pulls/comments/42399996"},"html":{"href":"https://github.com/yahoo/elide/pull/12#discussion_r42399996"},"pull_request":{"href":"https://api.github.com/repos/yahoo/elide/pulls/12"}}},"pull_request":{"url":"https://api.github.com/repos/yahoo/elide/pulls/12","id":48018906,"html_url":"https://github.com/yahoo/elide/pull/12","diff_url":"https://github.com/yahoo/elide/pull/12.diff","patch_url":"https://github.com/yahoo/elide/pull/12.patch","issue_url":"https://api.github.com/repos/yahoo/elide/issues/12","number":12,"state":"open","locked":false,"title":"Add support for Hibernate5","user":{"login":"shadanan","id":361429,"avatar_url":"https://avatars.githubusercontent.com/u/361429?v=3","gravatar_id":"","url":"https://api.github.com/users/shadanan","html_url":"https://github.com/shadanan","followers_url":"https://api.github.com/users/shadanan/followers","following_url":"https://api.github.com/users/shadanan/following{/other_user}","gists_url":"https://api.github.com/users/shadanan/gists{/gist_id}","starred_url":"https://api.github.com/users/shadanan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shadanan/subscriptions","organizations_url":"https://api.github.com/users/shadanan/orgs","repos_url":"https://api.github.com/users/shadanan/repos","events_url":"https://api.github.com/users/shadanan/events{/privacy}","received_events_url":"https://api.github.com/users/shadanan/received_events","type":"User","site_admin":false},"body":"Tests for Hibernate5 and Hibernate3, and examples, forthcoming in subsequent PRs","created_at":"2015-10-18T21:53:56Z","updated_at":"2015-10-19T17:27:07Z","closed_at":null,"merged_at":null,"merge_commit_sha":"9dac5817d191aa3d2d43be56ee4553a8b16b5cca","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/yahoo/elide/pulls/12/commits","review_comments_url":"https://api.github.com/repos/yahoo/elide/pulls/12/comments","review_comment_url":"https://api.github.com/repos/yahoo/elide/pulls/comments{/number}","comments_url":"https://api.github.com/repos/yahoo/elide/issues/12/comments","statuses_url":"https://api.github.com/repos/yahoo/elide/statuses/4e3e89a8dc70b74f18a201309297feadbe87500f","head":{"label":"yahoo:hibernate5","ref":"hibernate5","sha":"4e3e89a8dc70b74f18a201309297feadbe87500f","user":{"login":"yahoo","id":16574,"avatar_url":"https://avatars.githubusercontent.com/u/16574?v=3","gravatar_id":"","url":"https://api.github.com/users/yahoo","html_url":"https://github.com/yahoo","followers_url":"https://api.github.com/users/yahoo/followers","following_url":"https://api.github.com/users/yahoo/following{/other_user}","gists_url":"https://api.github.com/users/yahoo/gists{/gist_id}","starred_url":"https://api.github.com/users/yahoo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yahoo/subscriptions","organizations_url":"https://api.github.com/users/yahoo/orgs","repos_url":"https://api.github.com/users/yahoo/repos","events_url":"https://api.github.com/users/yahoo/events{/privacy}","received_events_url":"https://api.github.com/users/yahoo/received_events","type":"Organization","site_admin":false},"repo":{"id":44124366,"name":"elide","full_name":"yahoo/elide","owner":{"login":"yahoo","id":16574,"avatar_url":"https://avatars.githubusercontent.com/u/16574?v=3","gravatar_id":"","url":"https://api.github.com/users/yahoo","html_url":"https://github.com/yahoo","followers_url":"https://api.github.com/users/yahoo/followers","following_url":"https://api.github.com/users/yahoo/following{/other_user}","gists_url":"https://api.github.com/users/yahoo/gists{/gist_id}","starred_url":"https://api.github.com/users/yahoo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yahoo/subscriptions","organizations_url":"https://api.github.com/users/yahoo/orgs","repos_url":"https://api.github.com/users/yahoo/repos","events_url":"https://api.github.com/users/yahoo/events{/privacy}","received_events_url":"https://api.github.com/users/yahoo/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/yahoo/elide","description":"Elide is a Java library that let's you stand up a JSON API web service with minimal effort","fork":false,"url":"https://api.github.com/repos/yahoo/elide","forks_url":"https://api.github.com/repos/yahoo/elide/forks","keys_url":"https://api.github.com/repos/yahoo/elide/keys{/key_id}","collaborators_url":"https://api.github.com/repos/yahoo/elide/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/yahoo/elide/teams","hooks_url":"https://api.github.com/repos/yahoo/elide/hooks","issue_events_url":"https://api.github.com/repos/yahoo/elide/issues/events{/number}","events_url":"https://api.github.com/repos/yahoo/elide/events","assignees_url":"https://api.github.com/repos/yahoo/elide/assignees{/user}","branches_url":"https://api.github.com/repos/yahoo/elide/branches{/branch}","tags_url":"https://api.github.com/repos/yahoo/elide/tags","blobs_url":"https://api.github.com/repos/yahoo/elide/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/yahoo/elide/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/yahoo/elide/git/refs{/sha}","trees_url":"https://api.github.com/repos/yahoo/elide/git/trees{/sha}","statuses_url":"https://api.github.com/repos/yahoo/elide/statuses/{sha}","languages_url":"https://api.github.com/repos/yahoo/elide/languages","stargazers_url":"https://api.github.com/repos/yahoo/elide/stargazers","contributors_url":"https://api.github.com/repos/yahoo/elide/contributors","subscribers_url":"https://api.github.com/repos/yahoo/elide/subscribers","subscription_url":"https://api.github.com/repos/yahoo/elide/subscription","commits_url":"https://api.github.com/repos/yahoo/elide/commits{/sha}","git_commits_url":"https://api.github.com/repos/yahoo/elide/git/commits{/sha}","comments_url":"https://api.github.com/repos/yahoo/elide/comments{/number}","issue_comment_url":"https://api.github.com/repos/yahoo/elide/issues/comments{/number}","contents_url":"https://api.github.com/repos/yahoo/elide/contents/{+path}","compare_url":"https://api.github.com/repos/yahoo/elide/compare/{base}...{head}","merges_url":"https://api.github.com/repos/yahoo/elide/merges","archive_url":"https://api.github.com/repos/yahoo/elide/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/yahoo/elide/downloads","issues_url":"https://api.github.com/repos/yahoo/elide/issues{/number}","pulls_url":"https://api.github.com/repos/yahoo/elide/pulls{/number}","milestones_url":"https://api.github.com/repos/yahoo/elide/milestones{/number}","notifications_url":"https://api.github.com/repos/yahoo/elide/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/yahoo/elide/labels{/name}","releases_url":"https://api.github.com/repos/yahoo/elide/releases{/id}","created_at":"2015-10-12T17:55:01Z","updated_at":"2015-10-17T15:51:14Z","pushed_at":"2015-10-19T16:13:56Z","git_url":"git://github.com/yahoo/elide.git","ssh_url":"git@github.com:yahoo/elide.git","clone_url":"https://github.com/yahoo/elide.git","svn_url":"https://github.com/yahoo/elide","homepage":"","size":578,"stargazers_count":2,"watchers_count":2,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":3,"forks":2,"open_issues":3,"watchers":2,"default_branch":"master"}},"base":{"label":"yahoo:master","ref":"master","sha":"767a9351fc5b43644591a5f72542ca03e18ea170","user":{"login":"yahoo","id":16574,"avatar_url":"https://avatars.githubusercontent.com/u/16574?v=3","gravatar_id":"","url":"https://api.github.com/users/yahoo","html_url":"https://github.com/yahoo","followers_url":"https://api.github.com/users/yahoo/followers","following_url":"https://api.github.com/users/yahoo/following{/other_user}","gists_url":"https://api.github.com/users/yahoo/gists{/gist_id}","starred_url":"https://api.github.com/users/yahoo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yahoo/subscriptions","organizations_url":"https://api.github.com/users/yahoo/orgs","repos_url":"https://api.github.com/users/yahoo/repos","events_url":"https://api.github.com/users/yahoo/events{/privacy}","received_events_url":"https://api.github.com/users/yahoo/received_events","type":"Organization","site_admin":false},"repo":{"id":44124366,"name":"elide","full_name":"yahoo/elide","owner":{"login":"yahoo","id":16574,"avatar_url":"https://avatars.githubusercontent.com/u/16574?v=3","gravatar_id":"","url":"https://api.github.com/users/yahoo","html_url":"https://github.com/yahoo","followers_url":"https://api.github.com/users/yahoo/followers","following_url":"https://api.github.com/users/yahoo/following{/other_user}","gists_url":"https://api.github.com/users/yahoo/gists{/gist_id}","starred_url":"https://api.github.com/users/yahoo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yahoo/subscriptions","organizations_url":"https://api.github.com/users/yahoo/orgs","repos_url":"https://api.github.com/users/yahoo/repos","events_url":"https://api.github.com/users/yahoo/events{/privacy}","received_events_url":"https://api.github.com/users/yahoo/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/yahoo/elide","description":"Elide is a Java library that let's you stand up a JSON API web service with minimal effort","fork":false,"url":"https://api.github.com/repos/yahoo/elide","forks_url":"https://api.github.com/repos/yahoo/elide/forks","keys_url":"https://api.github.com/repos/yahoo/elide/keys{/key_id}","collaborators_url":"https://api.github.com/repos/yahoo/elide/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/yahoo/elide/teams","hooks_url":"https://api.github.com/repos/yahoo/elide/hooks","issue_events_url":"https://api.github.com/repos/yahoo/elide/issues/events{/number}","events_url":"https://api.github.com/repos/yahoo/elide/events","assignees_url":"https://api.github.com/repos/yahoo/elide/assignees{/user}","branches_url":"https://api.github.com/repos/yahoo/elide/branches{/branch}","tags_url":"https://api.github.com/repos/yahoo/elide/tags","blobs_url":"https://api.github.com/repos/yahoo/elide/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/yahoo/elide/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/yahoo/elide/git/refs{/sha}","trees_url":"https://api.github.com/repos/yahoo/elide/git/trees{/sha}","statuses_url":"https://api.github.com/repos/yahoo/elide/statuses/{sha}","languages_url":"https://api.github.com/repos/yahoo/elide/languages","stargazers_url":"https://api.github.com/repos/yahoo/elide/stargazers","contributors_url":"https://api.github.com/repos/yahoo/elide/contributors","subscribers_url":"https://api.github.com/repos/yahoo/elide/subscribers","subscription_url":"https://api.github.com/repos/yahoo/elide/subscription","commits_url":"https://api.github.com/repos/yahoo/elide/commits{/sha}","git_commits_url":"https://api.github.com/repos/yahoo/elide/git/commits{/sha}","comments_url":"https://api.github.com/repos/yahoo/elide/comments{/number}","issue_comment_url":"https://api.github.com/repos/yahoo/elide/issues/comments{/number}","contents_url":"https://api.github.com/repos/yahoo/elide/contents/{+path}","compare_url":"https://api.github.com/repos/yahoo/elide/compare/{base}...{head}","merges_url":"https://api.github.com/repos/yahoo/elide/merges","archive_url":"https://api.github.com/repos/yahoo/elide/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/yahoo/elide/downloads","issues_url":"https://api.github.com/repos/yahoo/elide/issues{/number}","pulls_url":"https://api.github.com/repos/yahoo/elide/pulls{/number}","milestones_url":"https://api.github.com/repos/yahoo/elide/milestones{/number}","notifications_url":"https://api.github.com/repos/yahoo/elide/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/yahoo/elide/labels{/name}","releases_url":"https://api.github.com/repos/yahoo/elide/releases{/id}","created_at":"2015-10-12T17:55:01Z","updated_at":"2015-10-17T15:51:14Z","pushed_at":"2015-10-19T16:13:56Z","git_url":"git://github.com/yahoo/elide.git","ssh_url":"git@github.com:yahoo/elide.git","clone_url":"https://github.com/yahoo/elide.git","svn_url":"https://github.com/yahoo/elide","homepage":"","size":578,"stargazers_count":2,"watchers_count":2,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":3,"forks":2,"open_issues":3,"watchers":2,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/yahoo/elide/pulls/12"},"html":{"href":"https://github.com/yahoo/elide/pull/12"},"issue":{"href":"https://api.github.com/repos/yahoo/elide/issues/12"},"comments":{"href":"https://api.github.com/repos/yahoo/elide/issues/12/comments"},"review_comments":{"href":"https://api.github.com/repos/yahoo/elide/pulls/12/comments"},"review_comment":{"href":"https://api.github.com/repos/yahoo/elide/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/yahoo/elide/pulls/12/commits"},"statuses":{"href":"https://api.github.com/repos/yahoo/elide/statuses/4e3e89a8dc70b74f18a201309297feadbe87500f"}}}}