{"action":"created","comment":{"url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/pulls/comments/67071233","id":67071233,"diff_hunk":"@@ -446,6 +471,7 @@ public Guid CorrelationId\n         public async Task<AuthenticationResult> AcquireTokenAsync(string resource, string clientId, Uri redirectUri, IPlatformParameters parameters)\n         {\n             return await this.AcquireTokenCommonAsync(resource, clientId, redirectUri, parameters, UserIdentifier.AnyUser);\n+","path":"src/ADAL.PCL/AuthenticationContext.cs","position":115,"original_position":115,"commit_id":"4c3760d1ea63c4dafe0e15f147dbb3dd446f8b2c","original_commit_id":"4c3760d1ea63c4dafe0e15f147dbb3dd446f8b2c","user":{"login":"abhishek58g","id":11414430,"avatar_url":"https://avatars.githubusercontent.com/u/11414430?v=3","gravatar_id":"","url":"https://api.github.com/users/abhishek58g","html_url":"https://github.com/abhishek58g","followers_url":"https://api.github.com/users/abhishek58g/followers","following_url":"https://api.github.com/users/abhishek58g/following{/other_user}","gists_url":"https://api.github.com/users/abhishek58g/gists{/gist_id}","starred_url":"https://api.github.com/users/abhishek58g/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/abhishek58g/subscriptions","organizations_url":"https://api.github.com/users/abhishek58g/orgs","repos_url":"https://api.github.com/users/abhishek58g/repos","events_url":"https://api.github.com/users/abhishek58g/events{/privacy}","received_events_url":"https://api.github.com/users/abhishek58g/received_events","type":"User","site_admin":false},"body":"done","created_at":"2016-06-14T22:41:03Z","updated_at":"2016-06-14T22:41:03Z","html_url":"https://github.com/AzureAD/azure-activedirectory-library-for-dotnet/pull/454#discussion_r67071233","pull_request_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/pulls/454","_links":{"self":{"href":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/pulls/comments/67071233"},"html":{"href":"https://github.com/AzureAD/azure-activedirectory-library-for-dotnet/pull/454#discussion_r67071233"},"pull_request":{"href":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/pulls/454"}}},"pull_request":{"url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/pulls/454","id":73668683,"html_url":"https://github.com/AzureAD/azure-activedirectory-library-for-dotnet/pull/454","diff_url":"https://github.com/AzureAD/azure-activedirectory-library-for-dotnet/pull/454.diff","patch_url":"https://github.com/AzureAD/azure-activedirectory-library-for-dotnet/pull/454.patch","issue_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/issues/454","number":454,"state":"open","locked":false,"title":"Abgun/resiliency","user":{"login":"abhishek58g","id":11414430,"avatar_url":"https://avatars.githubusercontent.com/u/11414430?v=3","gravatar_id":"","url":"https://api.github.com/users/abhishek58g","html_url":"https://github.com/abhishek58g","followers_url":"https://api.github.com/users/abhishek58g/followers","following_url":"https://api.github.com/users/abhishek58g/following{/other_user}","gists_url":"https://api.github.com/users/abhishek58g/gists{/gist_id}","starred_url":"https://api.github.com/users/abhishek58g/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/abhishek58g/subscriptions","organizations_url":"https://api.github.com/users/abhishek58g/orgs","repos_url":"https://api.github.com/users/abhishek58g/repos","events_url":"https://api.github.com/users/abhishek58g/events{/privacy}","received_events_url":"https://api.github.com/users/abhishek58g/received_events","type":"User","site_admin":false},"body":"Client Resiliency :- \r\n          \r\n1.  ExtendedLifeTimeToken :- A Boolean in AuthenticationResult informing the developer that a token has been returned to him because of the outage mode as opposed to ordinary logic.   \r\n2. The ExtendedLifeTimeEnabled flag would be used to enable/disable ADAL’s outage mode. It is added to AuthenticationContext. The default value of this flag would be false as we would want to present it as an optional feature.  \r\n\r\nRetry :- \r\n3. For every AcquireToken we should retry once before failing. This behavior would be present irrespective of the ExtendedLifeTime flag being set or not making our library more resilient. Retrying once after interval of one second in case of failure.\r\n\r\nResiliency :-  \r\n4. When ExtendedLifeTimeEnabled== true and on failing of the refresh token grant. AcquireToken would fail only if the ExtendedExpiresOn of the AT is elapsed. If not, we would return the stale AT in the AuthenticationResult with the ExtendedLifeToken flag set to true.\r\n5. While returning the stale token the ExtendedExpiresOn property is reflected in ExpiresOn.\r\n\r\nCode changes :- \r\n1. Check for 500 , 503 , 504 and network failure in AdalHttpClient for retry and resiliency.\r\n2. Token returning logic from cache (TokenCache , Base).\r\n3. Resiliency logic in TokenCache.\r\n","created_at":"2016-06-14T01:40:42Z","updated_at":"2016-06-14T22:41:03Z","closed_at":null,"merged_at":null,"merge_commit_sha":"2074d076aae68d6a742fbb06b28912d29da6fbfa","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/pulls/454/commits","review_comments_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/pulls/454/comments","review_comment_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/pulls/comments{/number}","comments_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/issues/454/comments","statuses_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/statuses/4c3760d1ea63c4dafe0e15f147dbb3dd446f8b2c","head":{"label":"AzureAD:abgun/resiliency","ref":"abgun/resiliency","sha":"4c3760d1ea63c4dafe0e15f147dbb3dd446f8b2c","user":{"login":"AzureAD","id":2966316,"avatar_url":"https://avatars.githubusercontent.com/u/2966316?v=3","gravatar_id":"","url":"https://api.github.com/users/AzureAD","html_url":"https://github.com/AzureAD","followers_url":"https://api.github.com/users/AzureAD/followers","following_url":"https://api.github.com/users/AzureAD/following{/other_user}","gists_url":"https://api.github.com/users/AzureAD/gists{/gist_id}","starred_url":"https://api.github.com/users/AzureAD/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AzureAD/subscriptions","organizations_url":"https://api.github.com/users/AzureAD/orgs","repos_url":"https://api.github.com/users/AzureAD/repos","events_url":"https://api.github.com/users/AzureAD/events{/privacy}","received_events_url":"https://api.github.com/users/AzureAD/received_events","type":"Organization","site_admin":false},"repo":{"id":19123031,"name":"azure-activedirectory-library-for-dotnet","full_name":"AzureAD/azure-activedirectory-library-for-dotnet","owner":{"login":"AzureAD","id":2966316,"avatar_url":"https://avatars.githubusercontent.com/u/2966316?v=3","gravatar_id":"","url":"https://api.github.com/users/AzureAD","html_url":"https://github.com/AzureAD","followers_url":"https://api.github.com/users/AzureAD/followers","following_url":"https://api.github.com/users/AzureAD/following{/other_user}","gists_url":"https://api.github.com/users/AzureAD/gists{/gist_id}","starred_url":"https://api.github.com/users/AzureAD/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AzureAD/subscriptions","organizations_url":"https://api.github.com/users/AzureAD/orgs","repos_url":"https://api.github.com/users/AzureAD/repos","events_url":"https://api.github.com/users/AzureAD/events{/privacy}","received_events_url":"https://api.github.com/users/AzureAD/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/AzureAD/azure-activedirectory-library-for-dotnet","description":"","fork":false,"url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet","forks_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/forks","keys_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/keys{/key_id}","collaborators_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/teams","hooks_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/hooks","issue_events_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/issues/events{/number}","events_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/events","assignees_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/assignees{/user}","branches_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/branches{/branch}","tags_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/tags","blobs_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/git/refs{/sha}","trees_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/git/trees{/sha}","statuses_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/statuses/{sha}","languages_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/languages","stargazers_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/stargazers","contributors_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/contributors","subscribers_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/subscribers","subscription_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/subscription","commits_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/commits{/sha}","git_commits_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/git/commits{/sha}","comments_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/comments{/number}","issue_comment_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/issues/comments{/number}","contents_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/contents/{+path}","compare_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/compare/{base}...{head}","merges_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/merges","archive_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/downloads","issues_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/issues{/number}","pulls_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/pulls{/number}","milestones_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/milestones{/number}","notifications_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/labels{/name}","releases_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/releases{/id}","deployments_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/deployments","created_at":"2014-04-24T20:29:51Z","updated_at":"2016-06-12T22:29:55Z","pushed_at":"2016-06-14T01:40:42Z","git_url":"git://github.com/AzureAD/azure-activedirectory-library-for-dotnet.git","ssh_url":"git@github.com:AzureAD/azure-activedirectory-library-for-dotnet.git","clone_url":"https://github.com/AzureAD/azure-activedirectory-library-for-dotnet.git","svn_url":"https://github.com/AzureAD/azure-activedirectory-library-for-dotnet","homepage":null,"size":7555,"stargazers_count":83,"watchers_count":83,"language":"C#","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":70,"mirror_url":null,"open_issues_count":45,"forks":70,"open_issues":45,"watchers":83,"default_branch":"master"}},"base":{"label":"AzureAD:dev","ref":"dev","sha":"fd7492df6491385eabec9940689a098bf845bb98","user":{"login":"AzureAD","id":2966316,"avatar_url":"https://avatars.githubusercontent.com/u/2966316?v=3","gravatar_id":"","url":"https://api.github.com/users/AzureAD","html_url":"https://github.com/AzureAD","followers_url":"https://api.github.com/users/AzureAD/followers","following_url":"https://api.github.com/users/AzureAD/following{/other_user}","gists_url":"https://api.github.com/users/AzureAD/gists{/gist_id}","starred_url":"https://api.github.com/users/AzureAD/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AzureAD/subscriptions","organizations_url":"https://api.github.com/users/AzureAD/orgs","repos_url":"https://api.github.com/users/AzureAD/repos","events_url":"https://api.github.com/users/AzureAD/events{/privacy}","received_events_url":"https://api.github.com/users/AzureAD/received_events","type":"Organization","site_admin":false},"repo":{"id":19123031,"name":"azure-activedirectory-library-for-dotnet","full_name":"AzureAD/azure-activedirectory-library-for-dotnet","owner":{"login":"AzureAD","id":2966316,"avatar_url":"https://avatars.githubusercontent.com/u/2966316?v=3","gravatar_id":"","url":"https://api.github.com/users/AzureAD","html_url":"https://github.com/AzureAD","followers_url":"https://api.github.com/users/AzureAD/followers","following_url":"https://api.github.com/users/AzureAD/following{/other_user}","gists_url":"https://api.github.com/users/AzureAD/gists{/gist_id}","starred_url":"https://api.github.com/users/AzureAD/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AzureAD/subscriptions","organizations_url":"https://api.github.com/users/AzureAD/orgs","repos_url":"https://api.github.com/users/AzureAD/repos","events_url":"https://api.github.com/users/AzureAD/events{/privacy}","received_events_url":"https://api.github.com/users/AzureAD/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/AzureAD/azure-activedirectory-library-for-dotnet","description":"","fork":false,"url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet","forks_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/forks","keys_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/keys{/key_id}","collaborators_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/teams","hooks_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/hooks","issue_events_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/issues/events{/number}","events_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/events","assignees_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/assignees{/user}","branches_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/branches{/branch}","tags_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/tags","blobs_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/git/refs{/sha}","trees_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/git/trees{/sha}","statuses_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/statuses/{sha}","languages_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/languages","stargazers_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/stargazers","contributors_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/contributors","subscribers_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/subscribers","subscription_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/subscription","commits_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/commits{/sha}","git_commits_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/git/commits{/sha}","comments_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/comments{/number}","issue_comment_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/issues/comments{/number}","contents_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/contents/{+path}","compare_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/compare/{base}...{head}","merges_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/merges","archive_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/downloads","issues_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/issues{/number}","pulls_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/pulls{/number}","milestones_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/milestones{/number}","notifications_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/labels{/name}","releases_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/releases{/id}","deployments_url":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/deployments","created_at":"2014-04-24T20:29:51Z","updated_at":"2016-06-12T22:29:55Z","pushed_at":"2016-06-14T01:40:42Z","git_url":"git://github.com/AzureAD/azure-activedirectory-library-for-dotnet.git","ssh_url":"git@github.com:AzureAD/azure-activedirectory-library-for-dotnet.git","clone_url":"https://github.com/AzureAD/azure-activedirectory-library-for-dotnet.git","svn_url":"https://github.com/AzureAD/azure-activedirectory-library-for-dotnet","homepage":null,"size":7555,"stargazers_count":83,"watchers_count":83,"language":"C#","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":70,"mirror_url":null,"open_issues_count":45,"forks":70,"open_issues":45,"watchers":83,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/pulls/454"},"html":{"href":"https://github.com/AzureAD/azure-activedirectory-library-for-dotnet/pull/454"},"issue":{"href":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/issues/454"},"comments":{"href":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/issues/454/comments"},"review_comments":{"href":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/pulls/454/comments"},"review_comment":{"href":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/pulls/454/commits"},"statuses":{"href":"https://api.github.com/repos/AzureAD/azure-activedirectory-library-for-dotnet/statuses/4c3760d1ea63c4dafe0e15f147dbb3dd446f8b2c"}}}}
{"actor":{"display_login":"abhishek58g"}}