{"action":"created","comment":{"url":"https://api.github.com/repos/strongbox/strongbox/pulls/comments/225235030","pull_request_review_id":164792632,"id":225235030,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIyNTIzNTAzMA==","diff_hunk":"@@ -0,0 +1,52 @@\n+package org.carlspring.strongbox.cron.jobs;\n+\n+import javax.inject.Inject;\n+\n+import org.carlspring.strongbox.cron.domain.CronTaskConfigurationDto;\n+import org.carlspring.strongbox.repository.NpmRepositoryFeatures;\n+import org.springframework.core.env.Environment;\n+\n+/**\n+ * @author Sergey Bespalov\n+ *\n+ */\n+public class FetchRemoteChangesFeedCronJob\n+        extends JavaCronJob\n+{\n+\n+    @Inject\n+    private NpmRepositoryFeatures features;\n+\n+    @Override\n+    public void executeTask(CronTaskConfigurationDto config)\n+        throws Throwable\n+    {\n+        String storageId = config.getProperty(\"storageId\");\n+        String repositoryId = config.getProperty(\"repositoryId\");\n+\n+        features.fetchRemoteChangesFeed(storageId, repositoryId);\n+    }\n+\n+    public static String calculateJobName(String storageId,\n+                                          String repositoryId)\n+    {\n+        return String.format(\"Fetch Remote Changes feed for %s:%s\", storageId, repositoryId);\n+    }\n+    \n+    @Override\n+    public boolean enabled(CronTaskConfigurationDto configuration, Environment env)\n+    {\n+        if (!super.enabled(configuration, env))\n+        {\n+            return false;\n+        }\n+        \n+        return shouldDownloadRemoteChangesFeed();\n+    }\n+\n+    public static boolean shouldDownloadRemoteChangesFeed()\n+    {\n+        return System.getProperty(\"strongbox.npm.remote.changes.enabled\") == null ||\n+                Boolean.parseBoolean(System.getProperty(\"strongbox.npm.remote.changes.enabled\"));","path":"strongbox-storage/strongbox-storage-layout-providers/strongbox-storage-npm-layout-provider/src/main/java/org/carlspring/strongbox/cron/jobs/FetchRemoteChangesFeedCronJob.java","position":50,"original_position":50,"commit_id":"cf9447d668a5102d90939662a4f5d5454f4d4e99","original_commit_id":"cf9447d668a5102d90939662a4f5d5454f4d4e99","user":{"login":"carlspring","id":1436265,"node_id":"MDQ6VXNlcjE0MzYyNjU=","avatar_url":"https://avatars3.githubusercontent.com/u/1436265?v=4","gravatar_id":"","url":"https://api.github.com/users/carlspring","html_url":"https://github.com/carlspring","followers_url":"https://api.github.com/users/carlspring/followers","following_url":"https://api.github.com/users/carlspring/following{/other_user}","gists_url":"https://api.github.com/users/carlspring/gists{/gist_id}","starred_url":"https://api.github.com/users/carlspring/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/carlspring/subscriptions","organizations_url":"https://api.github.com/users/carlspring/orgs","repos_url":"https://api.github.com/users/carlspring/repos","events_url":"https://api.github.com/users/carlspring/events{/privacy}","received_events_url":"https://api.github.com/users/carlspring/received_events","type":"User","site_admin":false},"body":"Cosmetic: For some reason, some of your multi-line `return` statements seems to be off by a character. Would you mind fixing all of these? Thanks! :)\r\n","created_at":"2018-10-15T16:35:53Z","updated_at":"2018-10-15T16:35:53Z","html_url":"https://github.com/strongbox/strongbox/pull/800#discussion_r225235030","pull_request_url":"https://api.github.com/repos/strongbox/strongbox/pulls/800","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/strongbox/strongbox/pulls/comments/225235030"},"html":{"href":"https://github.com/strongbox/strongbox/pull/800#discussion_r225235030"},"pull_request":{"href":"https://api.github.com/repos/strongbox/strongbox/pulls/800"}}},"pull_request":{"url":"https://api.github.com/repos/strongbox/strongbox/pulls/800","id":218190430,"node_id":"MDExOlB1bGxSZXF1ZXN0MjE4MTkwNDMw","html_url":"https://github.com/strongbox/strongbox/pull/800","diff_url":"https://github.com/strongbox/strongbox/pull/800.diff","patch_url":"https://github.com/strongbox/strongbox/pull/800.patch","issue_url":"https://api.github.com/repos/strongbox/strongbox/issues/800","number":800,"state":"open","locked":false,"title":"SB-1242 Package Feed download Cron job for Proxy repositories [ready]","user":{"login":"sbespalov","id":22783811,"node_id":"MDQ6VXNlcjIyNzgzODEx","avatar_url":"https://avatars2.githubusercontent.com/u/22783811?v=4","gravatar_id":"","url":"https://api.github.com/users/sbespalov","html_url":"https://github.com/sbespalov","followers_url":"https://api.github.com/users/sbespalov/followers","following_url":"https://api.github.com/users/sbespalov/following{/other_user}","gists_url":"https://api.github.com/users/sbespalov/gists{/gist_id}","starred_url":"https://api.github.com/users/sbespalov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sbespalov/subscriptions","organizations_url":"https://api.github.com/users/sbespalov/orgs","repos_url":"https://api.github.com/users/sbespalov/repos","events_url":"https://api.github.com/users/sbespalov/events{/privacy}","received_events_url":"https://api.github.com/users/sbespalov/received_events","type":"User","site_admin":false},"body":"","created_at":"2018-09-26T05:08:40Z","updated_at":"2018-10-15T16:35:53Z","closed_at":null,"merged_at":null,"merge_commit_sha":"4e5a9125f6b2b64ed540b16c7899669364fb9b2c","assignee":null,"assignees":[],"requested_reviewers":[{"login":"fuss86","id":12829566,"node_id":"MDQ6VXNlcjEyODI5NTY2","avatar_url":"https://avatars1.githubusercontent.com/u/12829566?v=4","gravatar_id":"","url":"https://api.github.com/users/fuss86","html_url":"https://github.com/fuss86","followers_url":"https://api.github.com/users/fuss86/followers","following_url":"https://api.github.com/users/fuss86/following{/other_user}","gists_url":"https://api.github.com/users/fuss86/gists{/gist_id}","starred_url":"https://api.github.com/users/fuss86/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fuss86/subscriptions","organizations_url":"https://api.github.com/users/fuss86/orgs","repos_url":"https://api.github.com/users/fuss86/repos","events_url":"https://api.github.com/users/fuss86/events{/privacy}","received_events_url":"https://api.github.com/users/fuss86/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/strongbox/strongbox/pulls/800/commits","review_comments_url":"https://api.github.com/repos/strongbox/strongbox/pulls/800/comments","review_comment_url":"https://api.github.com/repos/strongbox/strongbox/pulls/comments{/number}","comments_url":"https://api.github.com/repos/strongbox/strongbox/issues/800/comments","statuses_url":"https://api.github.com/repos/strongbox/strongbox/statuses/cf9447d668a5102d90939662a4f5d5454f4d4e99","head":{"label":"sbespalov:sbespalov_SB-1242","ref":"sbespalov_SB-1242","sha":"cf9447d668a5102d90939662a4f5d5454f4d4e99","user":{"login":"sbespalov","id":22783811,"node_id":"MDQ6VXNlcjIyNzgzODEx","avatar_url":"https://avatars2.githubusercontent.com/u/22783811?v=4","gravatar_id":"","url":"https://api.github.com/users/sbespalov","html_url":"https://github.com/sbespalov","followers_url":"https://api.github.com/users/sbespalov/followers","following_url":"https://api.github.com/users/sbespalov/following{/other_user}","gists_url":"https://api.github.com/users/sbespalov/gists{/gist_id}","starred_url":"https://api.github.com/users/sbespalov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sbespalov/subscriptions","organizations_url":"https://api.github.com/users/sbespalov/orgs","repos_url":"https://api.github.com/users/sbespalov/repos","events_url":"https://api.github.com/users/sbespalov/events{/privacy}","received_events_url":"https://api.github.com/users/sbespalov/received_events","type":"User","site_admin":false},"repo":{"id":72494340,"node_id":"MDEwOlJlcG9zaXRvcnk3MjQ5NDM0MA==","name":"strongbox","full_name":"sbespalov/strongbox","private":false,"owner":{"login":"sbespalov","id":22783811,"node_id":"MDQ6VXNlcjIyNzgzODEx","avatar_url":"https://avatars2.githubusercontent.com/u/22783811?v=4","gravatar_id":"","url":"https://api.github.com/users/sbespalov","html_url":"https://github.com/sbespalov","followers_url":"https://api.github.com/users/sbespalov/followers","following_url":"https://api.github.com/users/sbespalov/following{/other_user}","gists_url":"https://api.github.com/users/sbespalov/gists{/gist_id}","starred_url":"https://api.github.com/users/sbespalov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sbespalov/subscriptions","organizations_url":"https://api.github.com/users/sbespalov/orgs","repos_url":"https://api.github.com/users/sbespalov/repos","events_url":"https://api.github.com/users/sbespalov/events{/privacy}","received_events_url":"https://api.github.com/users/sbespalov/received_events","type":"User","site_admin":false},"html_url":"https://github.com/sbespalov/strongbox","description":null,"fork":true,"url":"https://api.github.com/repos/sbespalov/strongbox","forks_url":"https://api.github.com/repos/sbespalov/strongbox/forks","keys_url":"https://api.github.com/repos/sbespalov/strongbox/keys{/key_id}","collaborators_url":"https://api.github.com/repos/sbespalov/strongbox/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/sbespalov/strongbox/teams","hooks_url":"https://api.github.com/repos/sbespalov/strongbox/hooks","issue_events_url":"https://api.github.com/repos/sbespalov/strongbox/issues/events{/number}","events_url":"https://api.github.com/repos/sbespalov/strongbox/events","assignees_url":"https://api.github.com/repos/sbespalov/strongbox/assignees{/user}","branches_url":"https://api.github.com/repos/sbespalov/strongbox/branches{/branch}","tags_url":"https://api.github.com/repos/sbespalov/strongbox/tags","blobs_url":"https://api.github.com/repos/sbespalov/strongbox/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/sbespalov/strongbox/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/sbespalov/strongbox/git/refs{/sha}","trees_url":"https://api.github.com/repos/sbespalov/strongbox/git/trees{/sha}","statuses_url":"https://api.github.com/repos/sbespalov/strongbox/statuses/{sha}","languages_url":"https://api.github.com/repos/sbespalov/strongbox/languages","stargazers_url":"https://api.github.com/repos/sbespalov/strongbox/stargazers","contributors_url":"https://api.github.com/repos/sbespalov/strongbox/contributors","subscribers_url":"https://api.github.com/repos/sbespalov/strongbox/subscribers","subscription_url":"https://api.github.com/repos/sbespalov/strongbox/subscription","commits_url":"https://api.github.com/repos/sbespalov/strongbox/commits{/sha}","git_commits_url":"https://api.github.com/repos/sbespalov/strongbox/git/commits{/sha}","comments_url":"https://api.github.com/repos/sbespalov/strongbox/comments{/number}","issue_comment_url":"https://api.github.com/repos/sbespalov/strongbox/issues/comments{/number}","contents_url":"https://api.github.com/repos/sbespalov/strongbox/contents/{+path}","compare_url":"https://api.github.com/repos/sbespalov/strongbox/compare/{base}...{head}","merges_url":"https://api.github.com/repos/sbespalov/strongbox/merges","archive_url":"https://api.github.com/repos/sbespalov/strongbox/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/sbespalov/strongbox/downloads","issues_url":"https://api.github.com/repos/sbespalov/strongbox/issues{/number}","pulls_url":"https://api.github.com/repos/sbespalov/strongbox/pulls{/number}","milestones_url":"https://api.github.com/repos/sbespalov/strongbox/milestones{/number}","notifications_url":"https://api.github.com/repos/sbespalov/strongbox/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/sbespalov/strongbox/labels{/name}","releases_url":"https://api.github.com/repos/sbespalov/strongbox/releases{/id}","deployments_url":"https://api.github.com/repos/sbespalov/strongbox/deployments","created_at":"2016-11-01T01:54:58Z","updated_at":"2018-10-15T03:54:18Z","pushed_at":"2018-10-15T08:12:54Z","git_url":"git://github.com/sbespalov/strongbox.git","ssh_url":"git@github.com:sbespalov/strongbox.git","clone_url":"https://github.com/sbespalov/strongbox.git","svn_url":"https://github.com/sbespalov/strongbox","homepage":null,"size":10729,"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":"strongbox:master","ref":"master","sha":"e267e72f9011a64a059d0ce68194d4a4635e9408","user":{"login":"strongbox","id":5637881,"node_id":"MDEyOk9yZ2FuaXphdGlvbjU2Mzc4ODE=","avatar_url":"https://avatars0.githubusercontent.com/u/5637881?v=4","gravatar_id":"","url":"https://api.github.com/users/strongbox","html_url":"https://github.com/strongbox","followers_url":"https://api.github.com/users/strongbox/followers","following_url":"https://api.github.com/users/strongbox/following{/other_user}","gists_url":"https://api.github.com/users/strongbox/gists{/gist_id}","starred_url":"https://api.github.com/users/strongbox/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/strongbox/subscriptions","organizations_url":"https://api.github.com/users/strongbox/orgs","repos_url":"https://api.github.com/users/strongbox/repos","events_url":"https://api.github.com/users/strongbox/events{/privacy}","received_events_url":"https://api.github.com/users/strongbox/received_events","type":"Organization","site_admin":false},"repo":{"id":11830269,"node_id":"MDEwOlJlcG9zaXRvcnkxMTgzMDI2OQ==","name":"strongbox","full_name":"strongbox/strongbox","private":false,"owner":{"login":"strongbox","id":5637881,"node_id":"MDEyOk9yZ2FuaXphdGlvbjU2Mzc4ODE=","avatar_url":"https://avatars0.githubusercontent.com/u/5637881?v=4","gravatar_id":"","url":"https://api.github.com/users/strongbox","html_url":"https://github.com/strongbox","followers_url":"https://api.github.com/users/strongbox/followers","following_url":"https://api.github.com/users/strongbox/following{/other_user}","gists_url":"https://api.github.com/users/strongbox/gists{/gist_id}","starred_url":"https://api.github.com/users/strongbox/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/strongbox/subscriptions","organizations_url":"https://api.github.com/users/strongbox/orgs","repos_url":"https://api.github.com/users/strongbox/repos","events_url":"https://api.github.com/users/strongbox/events{/privacy}","received_events_url":"https://api.github.com/users/strongbox/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/strongbox/strongbox","description":"Strongbox is an artifact repository manager.","fork":false,"url":"https://api.github.com/repos/strongbox/strongbox","forks_url":"https://api.github.com/repos/strongbox/strongbox/forks","keys_url":"https://api.github.com/repos/strongbox/strongbox/keys{/key_id}","collaborators_url":"https://api.github.com/repos/strongbox/strongbox/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/strongbox/strongbox/teams","hooks_url":"https://api.github.com/repos/strongbox/strongbox/hooks","issue_events_url":"https://api.github.com/repos/strongbox/strongbox/issues/events{/number}","events_url":"https://api.github.com/repos/strongbox/strongbox/events","assignees_url":"https://api.github.com/repos/strongbox/strongbox/assignees{/user}","branches_url":"https://api.github.com/repos/strongbox/strongbox/branches{/branch}","tags_url":"https://api.github.com/repos/strongbox/strongbox/tags","blobs_url":"https://api.github.com/repos/strongbox/strongbox/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/strongbox/strongbox/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/strongbox/strongbox/git/refs{/sha}","trees_url":"https://api.github.com/repos/strongbox/strongbox/git/trees{/sha}","statuses_url":"https://api.github.com/repos/strongbox/strongbox/statuses/{sha}","languages_url":"https://api.github.com/repos/strongbox/strongbox/languages","stargazers_url":"https://api.github.com/repos/strongbox/strongbox/stargazers","contributors_url":"https://api.github.com/repos/strongbox/strongbox/contributors","subscribers_url":"https://api.github.com/repos/strongbox/strongbox/subscribers","subscription_url":"https://api.github.com/repos/strongbox/strongbox/subscription","commits_url":"https://api.github.com/repos/strongbox/strongbox/commits{/sha}","git_commits_url":"https://api.github.com/repos/strongbox/strongbox/git/commits{/sha}","comments_url":"https://api.github.com/repos/strongbox/strongbox/comments{/number}","issue_comment_url":"https://api.github.com/repos/strongbox/strongbox/issues/comments{/number}","contents_url":"https://api.github.com/repos/strongbox/strongbox/contents/{+path}","compare_url":"https://api.github.com/repos/strongbox/strongbox/compare/{base}...{head}","merges_url":"https://api.github.com/repos/strongbox/strongbox/merges","archive_url":"https://api.github.com/repos/strongbox/strongbox/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/strongbox/strongbox/downloads","issues_url":"https://api.github.com/repos/strongbox/strongbox/issues{/number}","pulls_url":"https://api.github.com/repos/strongbox/strongbox/pulls{/number}","milestones_url":"https://api.github.com/repos/strongbox/strongbox/milestones{/number}","notifications_url":"https://api.github.com/repos/strongbox/strongbox/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/strongbox/strongbox/labels{/name}","releases_url":"https://api.github.com/repos/strongbox/strongbox/releases{/id}","deployments_url":"https://api.github.com/repos/strongbox/strongbox/deployments","created_at":"2013-08-01T23:27:37Z","updated_at":"2018-10-15T12:53:36Z","pushed_at":"2018-10-15T08:46:28Z","git_url":"git://github.com/strongbox/strongbox.git","ssh_url":"git@github.com:strongbox/strongbox.git","clone_url":"https://github.com/strongbox/strongbox.git","svn_url":"https://github.com/strongbox/strongbox","homepage":"","size":10390,"stargazers_count":44,"watchers_count":44,"language":"Java","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":71,"mirror_url":null,"archived":false,"open_issues_count":115,"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":71,"open_issues":115,"watchers":44,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/strongbox/strongbox/pulls/800"},"html":{"href":"https://github.com/strongbox/strongbox/pull/800"},"issue":{"href":"https://api.github.com/repos/strongbox/strongbox/issues/800"},"comments":{"href":"https://api.github.com/repos/strongbox/strongbox/issues/800/comments"},"review_comments":{"href":"https://api.github.com/repos/strongbox/strongbox/pulls/800/comments"},"review_comment":{"href":"https://api.github.com/repos/strongbox/strongbox/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/strongbox/strongbox/pulls/800/commits"},"statuses":{"href":"https://api.github.com/repos/strongbox/strongbox/statuses/cf9447d668a5102d90939662a4f5d5454f4d4e99"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"carlspring"}}