GitHub PullRequestEvent at 2014-09-15 04:04:40
Repository: liferay-portal
Actor: brianchandotcom
Payload: {"action":"reopened","number":20876,"pull_request":{"url":"https://api.github.com/repos/brianchandotcom/liferay-portal/pulls/20876","id":20939762,"html_url":"https://github.com/brianchandotcom/liferay-portal/pull/20876","diff_url":"https://github.com/brianchandotcom/liferay-portal/pull/20876.diff","patch_url":"https://github.com/brianchandotcom/liferay-portal/pull/20876.patch","issue_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/issues/20876","number":20876,"state":"open","locked":false,"title":"LPS-49438 Upgrade Language keys in default data","user":{"login":"sergiogonzalez","id":860987,"avatar_url":"https://avatars.githubusercontent.com/u/860987?v=2","gravatar_id":"c62c82833a3fc96595a17bb81d5f4878","url":"https://api.github.com/users/sergiogonzalez","html_url":"https://github.com/sergiogonzalez","followers_url":"https://api.github.com/users/sergiogonzalez/followers","following_url":"https://api.github.com/users/sergiogonzalez/following{/other_user}","gists_url":"https://api.github.com/users/sergiogonzalez/gists{/gist_id}","starred_url":"https://api.github.com/users/sergiogonzalez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sergiogonzalez/subscriptions","organizations_url":"https://api.github.com/users/sergiogonzalez/orgs","repos_url":"https://api.github.com/users/sergiogonzalez/repos","events_url":"https://api.github.com/users/sergiogonzalez/events{/privacy}","received_events_url":"https://api.github.com/users/sergiogonzalez/received_events","type":"User","site_admin":false},"body":"Hey Brian,\r\n\r\nThis is a resend of: https://github.com/brianchandotcom/liferay-portal/pull/20847#issuecomment-54900309\r\n\r\nRegarding the list size when retrieving the companyIds and groupIds it shouldn't be an issue. We are **only retrieving the global groupId and companyId, which means that we will have 1 row per portal instance**, and most of the installations don't use portal instances and the ones that do don't have thousands of instances. We searched in other upgrades and there are queries that are similar or even worse and they don't have any pagination at all, such as: \r\n\r\nhttps://github.com/liferay/liferay-portal/blob/master/portal-impl/src/com/liferay/portal/upgrade/v6_1_0/UpgradeDocumentLibrary.java#L169\r\n```java\r\n\t\t\tps = con.prepareStatement(\r\n\t\t\t\t\"select fileEntryId, extension from DLFileEntry\");\r\n\r\n```\r\n\r\nhttps://github.com/liferay/liferay-portal/blob/master/portal-impl/src/com/liferay/portal/upgrade/v5_2_5_to_6_0_0/UpgradeGroup.java#L75\r\n```java\r\n\t\t\tps = con.prepareStatement(\r\n\t\t\t\t\"select groupId, classPK from Group_ where classNameId = \" +\r\n\t\t\t\t\tclassNameId);\r\n```\r\n\r\n\r\nRegarding the fileEntryType keys, since the beginning they were originally created using the pattern of AAA BBB CCC (without any dash or underline). In 6.2.x we were using this constants https://github.com/liferay/liferay-portal/blob/6.2.x/portal-service/src/com/liferay/portlet/documentlibrary/model/DLFileEntryTypeConstants.java and they are transformed to uppercase by line https://github.com/liferay/liferay-portal/blob/6.2.x/portal-impl/src/com/liferay/portlet/documentlibrary/service/impl/DLFileEntryTypeLocalServiceImpl.java#L79. **The result is that the keys stored in database are like IMAGE GALLERY IMAGE or MARKETING BANNER** and as we want to keep the existing document types, we need to use this kind of keys in the upgrade.\r\n\r\nThe Image Gallery Document type was introduced as part of the upgrade process to 6.1.0 when we remove the Image Gallery. The following portal.property decides if the image gallery document type should be created or not: dl.file.entry.type.ig.image.auto.create.on.upgrade. In case that the document type exists, we need to upgrade it.","created_at":"2014-09-09T08:15:44Z","updated_at":"2014-09-15T04:04:40Z","closed_at":null,"merged_at":null,"merge_commit_sha":"625acb1f9d7d79385127a7ee0797432b8d78a20b","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/pulls/20876/commits","review_comments_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/pulls/20876/comments","review_comment_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/pulls/comments/{number}","comments_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/issues/20876/comments","statuses_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/statuses/35ec6acda87fedde600513fe18e379bb4223c264","head":{"label":"sergiogonzalez:pr-20847","ref":"pr-20847","sha":"35ec6acda87fedde600513fe18e379bb4223c264","user":{"login":"sergiogonzalez","id":860987,"avatar_url":"https://avatars.githubusercontent.com/u/860987?v=2","gravatar_id":"c62c82833a3fc96595a17bb81d5f4878","url":"https://api.github.com/users/sergiogonzalez","html_url":"https://github.com/sergiogonzalez","followers_url":"https://api.github.com/users/sergiogonzalez/followers","following_url":"https://api.github.com/users/sergiogonzalez/following{/other_user}","gists_url":"https://api.github.com/users/sergiogonzalez/gists{/gist_id}","starred_url":"https://api.github.com/users/sergiogonzalez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sergiogonzalez/subscriptions","organizations_url":"https://api.github.com/users/sergiogonzalez/orgs","repos_url":"https://api.github.com/users/sergiogonzalez/repos","events_url":"https://api.github.com/users/sergiogonzalez/events{/privacy}","received_events_url":"https://api.github.com/users/sergiogonzalez/received_events","type":"User","site_admin":false},"repo":{"id":1922169,"name":"liferay-portal","full_name":"sergiogonzalez/liferay-portal","owner":{"login":"sergiogonzalez","id":860987,"avatar_url":"https://avatars.githubusercontent.com/u/860987?v=2","gravatar_id":"c62c82833a3fc96595a17bb81d5f4878","url":"https://api.github.com/users/sergiogonzalez","html_url":"https://github.com/sergiogonzalez","followers_url":"https://api.github.com/users/sergiogonzalez/followers","following_url":"https://api.github.com/users/sergiogonzalez/following{/other_user}","gists_url":"https://api.github.com/users/sergiogonzalez/gists{/gist_id}","starred_url":"https://api.github.com/users/sergiogonzalez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sergiogonzalez/subscriptions","organizations_url":"https://api.github.com/users/sergiogonzalez/orgs","repos_url":"https://api.github.com/users/sergiogonzalez/repos","events_url":"https://api.github.com/users/sergiogonzalez/events{/privacy}","received_events_url":"https://api.github.com/users/sergiogonzalez/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/sergiogonzalez/liferay-portal","description":"","fork":true,"url":"https://api.github.com/repos/sergiogonzalez/liferay-portal","forks_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/forks","keys_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/keys{/key_id}","collaborators_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/teams","hooks_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/hooks","issue_events_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/issues/events{/number}","events_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/events","assignees_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/assignees{/user}","branches_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/branches{/branch}","tags_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/tags","blobs_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/git/refs{/sha}","trees_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/git/trees{/sha}","statuses_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/statuses/{sha}","languages_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/languages","stargazers_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/stargazers","contributors_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/contributors","subscribers_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/subscribers","subscription_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/subscription","commits_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/commits{/sha}","git_commits_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/git/commits{/sha}","comments_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/comments{/number}","issue_comment_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/issues/comments/{number}","contents_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/contents/{+path}","compare_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/compare/{base}...{head}","merges_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/merges","archive_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/downloads","issues_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/issues{/number}","pulls_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/pulls{/number}","milestones_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/milestones{/number}","notifications_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/labels{/name}","releases_url":"https://api.github.com/repos/sergiogonzalez/liferay-portal/releases{/id}","created_at":"2011-06-20T06:19:51Z","updated_at":"2014-06-26T09:50:34Z","pushed_at":"2014-09-12T09:24:19Z","git_url":"git://github.com/sergiogonzalez/liferay-portal.git","ssh_url":"git@github.com:sergiogonzalez/liferay-portal.git","clone_url":"https://github.com/sergiogonzalez/liferay-portal.git","svn_url":"https://github.com/sergiogonzalez/liferay-portal","homepage":"http://liferay.com","size":3792089,"stargazers_count":3,"watchers_count":3,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":6,"forks":0,"open_issues":6,"watchers":3,"default_branch":"master"}},"base":{"label":"brianchandotcom:master","ref":"master","sha":"7272ce2738ba466e1ee4f2fe4d3fa9c03760847d","user":{"login":"brianchandotcom","id":282080,"avatar_url":"https://avatars.githubusercontent.com/u/282080?v=2","gravatar_id":"820bdfae0927075dec1dc2087c81b19d","url":"https://api.github.com/users/brianchandotcom","html_url":"https://github.com/brianchandotcom","followers_url":"https://api.github.com/users/brianchandotcom/followers","following_url":"https://api.github.com/users/brianchandotcom/following{/other_user}","gists_url":"https://api.github.com/users/brianchandotcom/gists{/gist_id}","starred_url":"https://api.github.com/users/brianchandotcom/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brianchandotcom/subscriptions","organizations_url":"https://api.github.com/users/brianchandotcom/orgs","repos_url":"https://api.github.com/users/brianchandotcom/repos","events_url":"https://api.github.com/users/brianchandotcom/events{/privacy}","received_events_url":"https://api.github.com/users/brianchandotcom/received_events","type":"User","site_admin":false},"repo":{"id":1920851,"name":"liferay-portal","full_name":"brianchandotcom/liferay-portal","owner":{"login":"brianchandotcom","id":282080,"avatar_url":"https://avatars.githubusercontent.com/u/282080?v=2","gravatar_id":"820bdfae0927075dec1dc2087c81b19d","url":"https://api.github.com/users/brianchandotcom","html_url":"https://github.com/brianchandotcom","followers_url":"https://api.github.com/users/brianchandotcom/followers","following_url":"https://api.github.com/users/brianchandotcom/following{/other_user}","gists_url":"https://api.github.com/users/brianchandotcom/gists{/gist_id}","starred_url":"https://api.github.com/users/brianchandotcom/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brianchandotcom/subscriptions","organizations_url":"https://api.github.com/users/brianchandotcom/orgs","repos_url":"https://api.github.com/users/brianchandotcom/repos","events_url":"https://api.github.com/users/brianchandotcom/events{/privacy}","received_events_url":"https://api.github.com/users/brianchandotcom/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/brianchandotcom/liferay-portal","description":"","fork":true,"url":"https://api.github.com/repos/brianchandotcom/liferay-portal","forks_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/forks","keys_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/keys{/key_id}","collaborators_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/teams","hooks_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/hooks","issue_events_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/issues/events{/number}","events_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/events","assignees_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/assignees{/user}","branches_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/branches{/branch}","tags_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/tags","blobs_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/git/refs{/sha}","trees_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/git/trees{/sha}","statuses_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/statuses/{sha}","languages_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/languages","stargazers_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/stargazers","contributors_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/contributors","subscribers_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/subscribers","subscription_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/subscription","commits_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/commits{/sha}","git_commits_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/git/commits{/sha}","comments_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/comments{/number}","issue_comment_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/issues/comments/{number}","contents_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/contents/{+path}","compare_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/compare/{base}...{head}","merges_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/merges","archive_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/downloads","issues_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/issues{/number}","pulls_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/pulls{/number}","milestones_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/milestones{/number}","notifications_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/labels{/name}","releases_url":"https://api.github.com/repos/brianchandotcom/liferay-portal/releases{/id}","created_at":"2011-06-19T21:37:56Z","updated_at":"2014-09-03T00:38:26Z","pushed_at":"2014-09-15T01:19:48Z","git_url":"git://github.com/brianchandotcom/liferay-portal.git","ssh_url":"git@github.com:brianchandotcom/liferay-portal.git","clone_url":"https://github.com/brianchandotcom/liferay-portal.git","svn_url":"https://github.com/brianchandotcom/liferay-portal","homepage":"http://liferay.com","size":4267483,"stargazers_count":27,"watchers_count":27,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":5,"mirror_url":null,"open_issues_count":2,"forks":5,"open_issues":2,"watchers":27,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/brianchandotcom/liferay-portal/pulls/20876"},"html":{"href":"https://github.com/brianchandotcom/liferay-portal/pull/20876"},"issue":{"href":"https://api.github.com/repos/brianchandotcom/liferay-portal/issues/20876"},"comments":{"href":"https://api.github.com/repos/brianchandotcom/liferay-portal/issues/20876/comments"},"review_comments":{"href":"https://api.github.com/repos/brianchandotcom/liferay-portal/pulls/20876/comments"},"review_comment":{"href":"https://api.github.com/repos/brianchandotcom/liferay-portal/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/brianchandotcom/liferay-portal/pulls/20876/commits"},"statuses":{"href":"https://api.github.com/repos/brianchandotcom/liferay-portal/statuses/35ec6acda87fedde600513fe18e379bb4223c264"}},"merged":false,"mergeable":null,"mergeable_state":"unknown","merged_by":null,"comments":2,"review_comments":0,"commits":12,"additions":469,"deletions":11,"changed_files":8}}