{"action":"created","comment":{"url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/pulls/comments/54699879","id":54699879,"diff_hunk":"@@ -461,8 +461,16 @@ private String getPrincipalName(String username, String domainName) {\n                             throw e;\n                         }\n                     }\n-                    if (!found || duration >= 10) {\n-                        LOGGER.warning(String.format(\"AD chain lookup is taking too long (%dms). Falling back to recursive lookup\", duration));\n+                    if (!found && duration >= 10) {\n+                        LOGGER.warning(String.format(\"AD chain didn't find the group in (%dms). Falling back to recursive lookup\", duration));\n+                        groupLookupStrategy = GroupLookupStrategy.RECURSIVE;\n+                        continue;\n+                    } else if (found && duration >= 10) {\n+                        LOGGER.warning(String.format(\"AD chain lookup found the group but took too long (%dms). Falling back to recursive lookup\", duration));\n+                        groupLookupStrategy = GroupLookupStrategy.RECURSIVE;\n+                        return groups;\n+                    } else if (!found) {\n+                        LOGGER.warning(String.format(\"AD chain lookup didn't found the group. Falling back to recursive lookup\", duration));","path":"src/main/java/hudson/plugins/active_directory/ActiveDirectoryUnixAuthenticationProvider.java","position":15,"original_position":15,"commit_id":"3e534ced1e7b050fae89cee9988ebfb4c60288ac","original_commit_id":"3e534ced1e7b050fae89cee9988ebfb4c60288ac","user":{"login":"jtnord","id":494726,"avatar_url":"https://avatars.githubusercontent.com/u/494726?v=3","gravatar_id":"","url":"https://api.github.com/users/jtnord","html_url":"https://github.com/jtnord","followers_url":"https://api.github.com/users/jtnord/followers","following_url":"https://api.github.com/users/jtnord/following{/other_user}","gists_url":"https://api.github.com/users/jtnord/gists{/gist_id}","starred_url":"https://api.github.com/users/jtnord/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jtnord/subscriptions","organizations_url":"https://api.github.com/users/jtnord/orgs","repos_url":"https://api.github.com/users/jtnord/repos","events_url":"https://api.github.com/users/jtnord/events{/privacy}","received_events_url":"https://api.github.com/users/jtnord/received_events","type":"User","site_admin":false},"body":"Nit: the English could be clearer.\r\n\"Group lookup via Active Directory\\'s 'matching rule in chain' extension failed. Falling back to recursive group lookup strategy for this and future queries\"","created_at":"2016-03-02T09:41:42Z","updated_at":"2016-03-02T09:41:42Z","html_url":"https://github.com/jenkinsci/active-directory-plugin/pull/24#discussion_r54699879","pull_request_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/pulls/24","_links":{"self":{"href":"https://api.github.com/repos/jenkinsci/active-directory-plugin/pulls/comments/54699879"},"html":{"href":"https://github.com/jenkinsci/active-directory-plugin/pull/24#discussion_r54699879"},"pull_request":{"href":"https://api.github.com/repos/jenkinsci/active-directory-plugin/pulls/24"}}},"pull_request":{"url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/pulls/24","id":61359624,"html_url":"https://github.com/jenkinsci/active-directory-plugin/pull/24","diff_url":"https://github.com/jenkinsci/active-directory-plugin/pull/24.diff","patch_url":"https://github.com/jenkinsci/active-directory-plugin/pull/24.patch","issue_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/issues/24","number":24,"state":"open","locked":false,"title":"[FIXED JENKINS-33260] Change the logic when resolving groups","user":{"login":"fbelzunc","id":3898648,"avatar_url":"https://avatars.githubusercontent.com/u/3898648?v=3","gravatar_id":"","url":"https://api.github.com/users/fbelzunc","html_url":"https://github.com/fbelzunc","followers_url":"https://api.github.com/users/fbelzunc/followers","following_url":"https://api.github.com/users/fbelzunc/following{/other_user}","gists_url":"https://api.github.com/users/fbelzunc/gists{/gist_id}","starred_url":"https://api.github.com/users/fbelzunc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fbelzunc/subscriptions","organizations_url":"https://api.github.com/users/fbelzunc/orgs","repos_url":"https://api.github.com/users/fbelzunc/repos","events_url":"https://api.github.com/users/fbelzunc/events{/privacy}","received_events_url":"https://api.github.com/users/fbelzunc/received_events","type":"User","site_admin":false},"body":"```\r\nif (!found || duration >= 10) {\r\n                        LOGGER.warning(String.format(\"AD chain lookup is taking too long (%dms). Falling back to recursive lookup\", duration));\r\n                        groupLookupStrategy = GroupLookupStrategy.RECURSIVE;\r\n                        continue;\r\n                    }\r\n```\r\n\r\nThis logic smells wrong. We could have found the responses - just taken more than 10 seconds.\r\n\r\nhttps://issues.jenkins-ci.org/browse/JENKINS-33260\r\n\r\n@reviewbybees CC @jtnord ","created_at":"2016-03-02T07:08:49Z","updated_at":"2016-03-02T09:41:42Z","closed_at":null,"merged_at":null,"merge_commit_sha":"15679b2eb48feb326f736f5ad039196187c65cd8","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/pulls/24/commits","review_comments_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/pulls/24/comments","review_comment_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/pulls/comments{/number}","comments_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/issues/24/comments","statuses_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/statuses/3e534ced1e7b050fae89cee9988ebfb4c60288ac","head":{"label":"fbelzunc:JENKINS-33260","ref":"JENKINS-33260","sha":"3e534ced1e7b050fae89cee9988ebfb4c60288ac","user":{"login":"fbelzunc","id":3898648,"avatar_url":"https://avatars.githubusercontent.com/u/3898648?v=3","gravatar_id":"","url":"https://api.github.com/users/fbelzunc","html_url":"https://github.com/fbelzunc","followers_url":"https://api.github.com/users/fbelzunc/followers","following_url":"https://api.github.com/users/fbelzunc/following{/other_user}","gists_url":"https://api.github.com/users/fbelzunc/gists{/gist_id}","starred_url":"https://api.github.com/users/fbelzunc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fbelzunc/subscriptions","organizations_url":"https://api.github.com/users/fbelzunc/orgs","repos_url":"https://api.github.com/users/fbelzunc/repos","events_url":"https://api.github.com/users/fbelzunc/events{/privacy}","received_events_url":"https://api.github.com/users/fbelzunc/received_events","type":"User","site_admin":false},"repo":{"id":50431523,"name":"active-directory-plugin","full_name":"fbelzunc/active-directory-plugin","owner":{"login":"fbelzunc","id":3898648,"avatar_url":"https://avatars.githubusercontent.com/u/3898648?v=3","gravatar_id":"","url":"https://api.github.com/users/fbelzunc","html_url":"https://github.com/fbelzunc","followers_url":"https://api.github.com/users/fbelzunc/followers","following_url":"https://api.github.com/users/fbelzunc/following{/other_user}","gists_url":"https://api.github.com/users/fbelzunc/gists{/gist_id}","starred_url":"https://api.github.com/users/fbelzunc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fbelzunc/subscriptions","organizations_url":"https://api.github.com/users/fbelzunc/orgs","repos_url":"https://api.github.com/users/fbelzunc/repos","events_url":"https://api.github.com/users/fbelzunc/events{/privacy}","received_events_url":"https://api.github.com/users/fbelzunc/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/fbelzunc/active-directory-plugin","description":"Jenkins active-directory plugin","fork":true,"url":"https://api.github.com/repos/fbelzunc/active-directory-plugin","forks_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/forks","keys_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/keys{/key_id}","collaborators_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/teams","hooks_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/hooks","issue_events_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/issues/events{/number}","events_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/events","assignees_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/assignees{/user}","branches_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/branches{/branch}","tags_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/tags","blobs_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/git/refs{/sha}","trees_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/git/trees{/sha}","statuses_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/statuses/{sha}","languages_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/languages","stargazers_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/stargazers","contributors_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/contributors","subscribers_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/subscribers","subscription_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/subscription","commits_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/commits{/sha}","git_commits_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/git/commits{/sha}","comments_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/comments{/number}","issue_comment_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/issues/comments{/number}","contents_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/contents/{+path}","compare_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/compare/{base}...{head}","merges_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/merges","archive_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/downloads","issues_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/issues{/number}","pulls_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/pulls{/number}","milestones_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/milestones{/number}","notifications_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/labels{/name}","releases_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/releases{/id}","deployments_url":"https://api.github.com/repos/fbelzunc/active-directory-plugin/deployments","created_at":"2016-01-26T13:49:55Z","updated_at":"2016-01-26T13:49:56Z","pushed_at":"2016-03-02T09:15:09Z","git_url":"git://github.com/fbelzunc/active-directory-plugin.git","ssh_url":"git@github.com:fbelzunc/active-directory-plugin.git","clone_url":"https://github.com/fbelzunc/active-directory-plugin.git","svn_url":"https://github.com/fbelzunc/active-directory-plugin","homepage":"http://jenkins-ci.org/","size":372,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":false,"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":"jenkinsci:master","ref":"master","sha":"96a21ce114ebf85de4b3a09c93c5c4828a284834","user":{"login":"jenkinsci","id":107424,"avatar_url":"https://avatars.githubusercontent.com/u/107424?v=3","gravatar_id":"","url":"https://api.github.com/users/jenkinsci","html_url":"https://github.com/jenkinsci","followers_url":"https://api.github.com/users/jenkinsci/followers","following_url":"https://api.github.com/users/jenkinsci/following{/other_user}","gists_url":"https://api.github.com/users/jenkinsci/gists{/gist_id}","starred_url":"https://api.github.com/users/jenkinsci/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jenkinsci/subscriptions","organizations_url":"https://api.github.com/users/jenkinsci/orgs","repos_url":"https://api.github.com/users/jenkinsci/repos","events_url":"https://api.github.com/users/jenkinsci/events{/privacy}","received_events_url":"https://api.github.com/users/jenkinsci/received_events","type":"Organization","site_admin":false},"repo":{"id":1163445,"name":"active-directory-plugin","full_name":"jenkinsci/active-directory-plugin","owner":{"login":"jenkinsci","id":107424,"avatar_url":"https://avatars.githubusercontent.com/u/107424?v=3","gravatar_id":"","url":"https://api.github.com/users/jenkinsci","html_url":"https://github.com/jenkinsci","followers_url":"https://api.github.com/users/jenkinsci/followers","following_url":"https://api.github.com/users/jenkinsci/following{/other_user}","gists_url":"https://api.github.com/users/jenkinsci/gists{/gist_id}","starred_url":"https://api.github.com/users/jenkinsci/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jenkinsci/subscriptions","organizations_url":"https://api.github.com/users/jenkinsci/orgs","repos_url":"https://api.github.com/users/jenkinsci/repos","events_url":"https://api.github.com/users/jenkinsci/events{/privacy}","received_events_url":"https://api.github.com/users/jenkinsci/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/jenkinsci/active-directory-plugin","description":"Jenkins active-directory plugin","fork":false,"url":"https://api.github.com/repos/jenkinsci/active-directory-plugin","forks_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/forks","keys_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/teams","hooks_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/hooks","issue_events_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/issues/events{/number}","events_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/events","assignees_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/assignees{/user}","branches_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/branches{/branch}","tags_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/tags","blobs_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/git/refs{/sha}","trees_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/statuses/{sha}","languages_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/languages","stargazers_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/stargazers","contributors_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/contributors","subscribers_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/subscribers","subscription_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/subscription","commits_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/commits{/sha}","git_commits_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/git/commits{/sha}","comments_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/comments{/number}","issue_comment_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/issues/comments{/number}","contents_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/contents/{+path}","compare_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/merges","archive_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/downloads","issues_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/issues{/number}","pulls_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/pulls{/number}","milestones_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/milestones{/number}","notifications_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/labels{/name}","releases_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/releases{/id}","deployments_url":"https://api.github.com/repos/jenkinsci/active-directory-plugin/deployments","created_at":"2010-12-13T05:26:01Z","updated_at":"2016-02-11T23:06:50Z","pushed_at":"2016-03-02T09:15:09Z","git_url":"git://github.com/jenkinsci/active-directory-plugin.git","ssh_url":"git@github.com:jenkinsci/active-directory-plugin.git","clone_url":"https://github.com/jenkinsci/active-directory-plugin.git","svn_url":"https://github.com/jenkinsci/active-directory-plugin","homepage":"http://jenkins-ci.org/","size":415,"stargazers_count":27,"watchers_count":27,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":43,"mirror_url":null,"open_issues_count":5,"forks":43,"open_issues":5,"watchers":27,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/jenkinsci/active-directory-plugin/pulls/24"},"html":{"href":"https://github.com/jenkinsci/active-directory-plugin/pull/24"},"issue":{"href":"https://api.github.com/repos/jenkinsci/active-directory-plugin/issues/24"},"comments":{"href":"https://api.github.com/repos/jenkinsci/active-directory-plugin/issues/24/comments"},"review_comments":{"href":"https://api.github.com/repos/jenkinsci/active-directory-plugin/pulls/24/comments"},"review_comment":{"href":"https://api.github.com/repos/jenkinsci/active-directory-plugin/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/jenkinsci/active-directory-plugin/pulls/24/commits"},"statuses":{"href":"https://api.github.com/repos/jenkinsci/active-directory-plugin/statuses/3e534ced1e7b050fae89cee9988ebfb4c60288ac"}}}}