{"action":"created","comment":{"url":"https://api.github.com/repos/puppetlabs/clj-i18n/pulls/comments/75764651","id":75764651,"diff_hunk":"@@ -61,14 +61,16 @@\n     (map #(-> % slurp read-string (assoc :source %) check-locales check-and-normalize-packages)\n          (info-files))))\n \n-(defn info-map\n-  \"Turn the result of infos into a map mapping the package name to locales\n-  and bundle name.\n-\n-  To facilitate testing, we allow multiple infos with the same :package as\n-  long as they agree on the :bundle. The result of such a setup is that\n-  the :locales for such a package are the union of all the locales from\n-  those info files\"\n+(def string-length-comparator\n+  (reify java.util.Comparator\n+    (compare [_ lhs rhs]\n+      (clojure.core/compare (count lhs) (count rhs)))))","path":"src/puppetlabs/i18n/core.clj","position":15,"original_position":15,"commit_id":"86fe851a98e3be37ce5fd695eca9d5f258f74201","original_commit_id":"86fe851a98e3be37ce5fd695eca9d5f258f74201","user":{"login":"senior","id":215910,"avatar_url":"https://avatars.githubusercontent.com/u/215910?v=3","gravatar_id":"","url":"https://api.github.com/users/senior","html_url":"https://github.com/senior","followers_url":"https://api.github.com/users/senior/followers","following_url":"https://api.github.com/users/senior/following{/other_user}","gists_url":"https://api.github.com/users/senior/gists{/gist_id}","starred_url":"https://api.github.com/users/senior/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/senior/subscriptions","organizations_url":"https://api.github.com/users/senior/orgs","repos_url":"https://api.github.com/users/senior/repos","events_url":"https://api.github.com/users/senior/events{/privacy}","received_events_url":"https://api.github.com/users/senior/received_events","type":"User","site_admin":false},"body":"Oh right, the reverse at the end. I'll fix that and add a test.","created_at":"2016-08-22T21:41:52Z","updated_at":"2016-08-22T21:41:52Z","html_url":"https://github.com/puppetlabs/clj-i18n/pull/25#discussion_r75764651","pull_request_url":"https://api.github.com/repos/puppetlabs/clj-i18n/pulls/25","_links":{"self":{"href":"https://api.github.com/repos/puppetlabs/clj-i18n/pulls/comments/75764651"},"html":{"href":"https://github.com/puppetlabs/clj-i18n/pull/25#discussion_r75764651"},"pull_request":{"href":"https://api.github.com/repos/puppetlabs/clj-i18n/pulls/25"}}},"pull_request":{"url":"https://api.github.com/repos/puppetlabs/clj-i18n/pulls/25","id":82246332,"html_url":"https://github.com/puppetlabs/clj-i18n/pull/25","diff_url":"https://github.com/puppetlabs/clj-i18n/pull/25.diff","patch_url":"https://github.com/puppetlabs/clj-i18n/pull/25.patch","issue_url":"https://api.github.com/repos/puppetlabs/clj-i18n/issues/25","number":25,"state":"open","locked":false,"title":"(PDB-2985) Cache info-map to reduce CPU usage","user":{"login":"senior","id":215910,"avatar_url":"https://avatars.githubusercontent.com/u/215910?v=3","gravatar_id":"","url":"https://api.github.com/users/senior","html_url":"https://github.com/senior","followers_url":"https://api.github.com/users/senior/followers","following_url":"https://api.github.com/users/senior/following{/other_user}","gists_url":"https://api.github.com/users/senior/gists{/gist_id}","starred_url":"https://api.github.com/users/senior/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/senior/subscriptions","organizations_url":"https://api.github.com/users/senior/orgs","repos_url":"https://api.github.com/users/senior/repos","events_url":"https://api.github.com/users/senior/events{/privacy}","received_events_url":"https://api.github.com/users/senior/received_events","type":"User","site_admin":false},"body":"This commit switches bundle-for-namespace to use a cached copy of\r\ninfo-map, rather than regenerating it on each call. Regenerating the\r\ninfo-map on each translate call and use a lot of CPU and slow down users\r\nof the library.","created_at":"2016-08-22T19:13:51Z","updated_at":"2016-08-22T21:41:52Z","closed_at":null,"merged_at":null,"merge_commit_sha":"58fbe29834dd3c7753d49abddad1f9e914c2882f","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/puppetlabs/clj-i18n/pulls/25/commits","review_comments_url":"https://api.github.com/repos/puppetlabs/clj-i18n/pulls/25/comments","review_comment_url":"https://api.github.com/repos/puppetlabs/clj-i18n/pulls/comments{/number}","comments_url":"https://api.github.com/repos/puppetlabs/clj-i18n/issues/25/comments","statuses_url":"https://api.github.com/repos/puppetlabs/clj-i18n/statuses/86fe851a98e3be37ce5fd695eca9d5f258f74201","head":{"label":"senior:ticket/master/pdb-2985-excessive-translate-cpu-usage","ref":"ticket/master/pdb-2985-excessive-translate-cpu-usage","sha":"86fe851a98e3be37ce5fd695eca9d5f258f74201","user":{"login":"senior","id":215910,"avatar_url":"https://avatars.githubusercontent.com/u/215910?v=3","gravatar_id":"","url":"https://api.github.com/users/senior","html_url":"https://github.com/senior","followers_url":"https://api.github.com/users/senior/followers","following_url":"https://api.github.com/users/senior/following{/other_user}","gists_url":"https://api.github.com/users/senior/gists{/gist_id}","starred_url":"https://api.github.com/users/senior/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/senior/subscriptions","organizations_url":"https://api.github.com/users/senior/orgs","repos_url":"https://api.github.com/users/senior/repos","events_url":"https://api.github.com/users/senior/events{/privacy}","received_events_url":"https://api.github.com/users/senior/received_events","type":"User","site_admin":false},"repo":{"id":57080921,"name":"clj-i18n","full_name":"senior/clj-i18n","owner":{"login":"senior","id":215910,"avatar_url":"https://avatars.githubusercontent.com/u/215910?v=3","gravatar_id":"","url":"https://api.github.com/users/senior","html_url":"https://github.com/senior","followers_url":"https://api.github.com/users/senior/followers","following_url":"https://api.github.com/users/senior/following{/other_user}","gists_url":"https://api.github.com/users/senior/gists{/gist_id}","starred_url":"https://api.github.com/users/senior/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/senior/subscriptions","organizations_url":"https://api.github.com/users/senior/orgs","repos_url":"https://api.github.com/users/senior/repos","events_url":"https://api.github.com/users/senior/events{/privacy}","received_events_url":"https://api.github.com/users/senior/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/senior/clj-i18n","description":"Clojure i18n library and utilities","fork":true,"url":"https://api.github.com/repos/senior/clj-i18n","forks_url":"https://api.github.com/repos/senior/clj-i18n/forks","keys_url":"https://api.github.com/repos/senior/clj-i18n/keys{/key_id}","collaborators_url":"https://api.github.com/repos/senior/clj-i18n/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/senior/clj-i18n/teams","hooks_url":"https://api.github.com/repos/senior/clj-i18n/hooks","issue_events_url":"https://api.github.com/repos/senior/clj-i18n/issues/events{/number}","events_url":"https://api.github.com/repos/senior/clj-i18n/events","assignees_url":"https://api.github.com/repos/senior/clj-i18n/assignees{/user}","branches_url":"https://api.github.com/repos/senior/clj-i18n/branches{/branch}","tags_url":"https://api.github.com/repos/senior/clj-i18n/tags","blobs_url":"https://api.github.com/repos/senior/clj-i18n/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/senior/clj-i18n/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/senior/clj-i18n/git/refs{/sha}","trees_url":"https://api.github.com/repos/senior/clj-i18n/git/trees{/sha}","statuses_url":"https://api.github.com/repos/senior/clj-i18n/statuses/{sha}","languages_url":"https://api.github.com/repos/senior/clj-i18n/languages","stargazers_url":"https://api.github.com/repos/senior/clj-i18n/stargazers","contributors_url":"https://api.github.com/repos/senior/clj-i18n/contributors","subscribers_url":"https://api.github.com/repos/senior/clj-i18n/subscribers","subscription_url":"https://api.github.com/repos/senior/clj-i18n/subscription","commits_url":"https://api.github.com/repos/senior/clj-i18n/commits{/sha}","git_commits_url":"https://api.github.com/repos/senior/clj-i18n/git/commits{/sha}","comments_url":"https://api.github.com/repos/senior/clj-i18n/comments{/number}","issue_comment_url":"https://api.github.com/repos/senior/clj-i18n/issues/comments{/number}","contents_url":"https://api.github.com/repos/senior/clj-i18n/contents/{+path}","compare_url":"https://api.github.com/repos/senior/clj-i18n/compare/{base}...{head}","merges_url":"https://api.github.com/repos/senior/clj-i18n/merges","archive_url":"https://api.github.com/repos/senior/clj-i18n/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/senior/clj-i18n/downloads","issues_url":"https://api.github.com/repos/senior/clj-i18n/issues{/number}","pulls_url":"https://api.github.com/repos/senior/clj-i18n/pulls{/number}","milestones_url":"https://api.github.com/repos/senior/clj-i18n/milestones{/number}","notifications_url":"https://api.github.com/repos/senior/clj-i18n/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/senior/clj-i18n/labels{/name}","releases_url":"https://api.github.com/repos/senior/clj-i18n/releases{/id}","deployments_url":"https://api.github.com/repos/senior/clj-i18n/deployments","created_at":"2016-04-25T22:37:50Z","updated_at":"2016-04-25T22:37:51Z","pushed_at":"2016-08-22T19:13:14Z","git_url":"git://github.com/senior/clj-i18n.git","ssh_url":"git@github.com:senior/clj-i18n.git","clone_url":"https://github.com/senior/clj-i18n.git","svn_url":"https://github.com/senior/clj-i18n","homepage":null,"size":111,"stargazers_count":0,"watchers_count":0,"language":"Clojure","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"puppetlabs:master","ref":"master","sha":"03d57123300dc91bc2ba5dcbf0fc9f9de01775f9","user":{"login":"puppetlabs","id":234268,"avatar_url":"https://avatars.githubusercontent.com/u/234268?v=3","gravatar_id":"","url":"https://api.github.com/users/puppetlabs","html_url":"https://github.com/puppetlabs","followers_url":"https://api.github.com/users/puppetlabs/followers","following_url":"https://api.github.com/users/puppetlabs/following{/other_user}","gists_url":"https://api.github.com/users/puppetlabs/gists{/gist_id}","starred_url":"https://api.github.com/users/puppetlabs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/puppetlabs/subscriptions","organizations_url":"https://api.github.com/users/puppetlabs/orgs","repos_url":"https://api.github.com/users/puppetlabs/repos","events_url":"https://api.github.com/users/puppetlabs/events{/privacy}","received_events_url":"https://api.github.com/users/puppetlabs/received_events","type":"Organization","site_admin":false},"repo":{"id":34360399,"name":"clj-i18n","full_name":"puppetlabs/clj-i18n","owner":{"login":"puppetlabs","id":234268,"avatar_url":"https://avatars.githubusercontent.com/u/234268?v=3","gravatar_id":"","url":"https://api.github.com/users/puppetlabs","html_url":"https://github.com/puppetlabs","followers_url":"https://api.github.com/users/puppetlabs/followers","following_url":"https://api.github.com/users/puppetlabs/following{/other_user}","gists_url":"https://api.github.com/users/puppetlabs/gists{/gist_id}","starred_url":"https://api.github.com/users/puppetlabs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/puppetlabs/subscriptions","organizations_url":"https://api.github.com/users/puppetlabs/orgs","repos_url":"https://api.github.com/users/puppetlabs/repos","events_url":"https://api.github.com/users/puppetlabs/events{/privacy}","received_events_url":"https://api.github.com/users/puppetlabs/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/puppetlabs/clj-i18n","description":"Clojure i18n library and utilities","fork":false,"url":"https://api.github.com/repos/puppetlabs/clj-i18n","forks_url":"https://api.github.com/repos/puppetlabs/clj-i18n/forks","keys_url":"https://api.github.com/repos/puppetlabs/clj-i18n/keys{/key_id}","collaborators_url":"https://api.github.com/repos/puppetlabs/clj-i18n/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/puppetlabs/clj-i18n/teams","hooks_url":"https://api.github.com/repos/puppetlabs/clj-i18n/hooks","issue_events_url":"https://api.github.com/repos/puppetlabs/clj-i18n/issues/events{/number}","events_url":"https://api.github.com/repos/puppetlabs/clj-i18n/events","assignees_url":"https://api.github.com/repos/puppetlabs/clj-i18n/assignees{/user}","branches_url":"https://api.github.com/repos/puppetlabs/clj-i18n/branches{/branch}","tags_url":"https://api.github.com/repos/puppetlabs/clj-i18n/tags","blobs_url":"https://api.github.com/repos/puppetlabs/clj-i18n/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/puppetlabs/clj-i18n/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/puppetlabs/clj-i18n/git/refs{/sha}","trees_url":"https://api.github.com/repos/puppetlabs/clj-i18n/git/trees{/sha}","statuses_url":"https://api.github.com/repos/puppetlabs/clj-i18n/statuses/{sha}","languages_url":"https://api.github.com/repos/puppetlabs/clj-i18n/languages","stargazers_url":"https://api.github.com/repos/puppetlabs/clj-i18n/stargazers","contributors_url":"https://api.github.com/repos/puppetlabs/clj-i18n/contributors","subscribers_url":"https://api.github.com/repos/puppetlabs/clj-i18n/subscribers","subscription_url":"https://api.github.com/repos/puppetlabs/clj-i18n/subscription","commits_url":"https://api.github.com/repos/puppetlabs/clj-i18n/commits{/sha}","git_commits_url":"https://api.github.com/repos/puppetlabs/clj-i18n/git/commits{/sha}","comments_url":"https://api.github.com/repos/puppetlabs/clj-i18n/comments{/number}","issue_comment_url":"https://api.github.com/repos/puppetlabs/clj-i18n/issues/comments{/number}","contents_url":"https://api.github.com/repos/puppetlabs/clj-i18n/contents/{+path}","compare_url":"https://api.github.com/repos/puppetlabs/clj-i18n/compare/{base}...{head}","merges_url":"https://api.github.com/repos/puppetlabs/clj-i18n/merges","archive_url":"https://api.github.com/repos/puppetlabs/clj-i18n/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/puppetlabs/clj-i18n/downloads","issues_url":"https://api.github.com/repos/puppetlabs/clj-i18n/issues{/number}","pulls_url":"https://api.github.com/repos/puppetlabs/clj-i18n/pulls{/number}","milestones_url":"https://api.github.com/repos/puppetlabs/clj-i18n/milestones{/number}","notifications_url":"https://api.github.com/repos/puppetlabs/clj-i18n/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/puppetlabs/clj-i18n/labels{/name}","releases_url":"https://api.github.com/repos/puppetlabs/clj-i18n/releases{/id}","deployments_url":"https://api.github.com/repos/puppetlabs/clj-i18n/deployments","created_at":"2015-04-22T00:59:04Z","updated_at":"2016-07-08T00:25:36Z","pushed_at":"2016-08-22T19:13:52Z","git_url":"git://github.com/puppetlabs/clj-i18n.git","ssh_url":"git@github.com:puppetlabs/clj-i18n.git","clone_url":"https://github.com/puppetlabs/clj-i18n.git","svn_url":"https://github.com/puppetlabs/clj-i18n","homepage":null,"size":111,"stargazers_count":1,"watchers_count":1,"language":"Clojure","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":17,"mirror_url":null,"open_issues_count":1,"forks":17,"open_issues":1,"watchers":1,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/puppetlabs/clj-i18n/pulls/25"},"html":{"href":"https://github.com/puppetlabs/clj-i18n/pull/25"},"issue":{"href":"https://api.github.com/repos/puppetlabs/clj-i18n/issues/25"},"comments":{"href":"https://api.github.com/repos/puppetlabs/clj-i18n/issues/25/comments"},"review_comments":{"href":"https://api.github.com/repos/puppetlabs/clj-i18n/pulls/25/comments"},"review_comment":{"href":"https://api.github.com/repos/puppetlabs/clj-i18n/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/puppetlabs/clj-i18n/pulls/25/commits"},"statuses":{"href":"https://api.github.com/repos/puppetlabs/clj-i18n/statuses/86fe851a98e3be37ce5fd695eca9d5f258f74201"}}}}
{"actor":{"display_login":"senior"}}