Feature/enable cookie store at request level#1567
Feature/enable cookie store at request level#1567tranchitam wants to merge 4 commits intoAsyncHttpClient:mainfrom
Conversation
| @@ -71,12 +71,19 @@ public boolean exitAfterIntercept(Channel channel, | |||
|
|
|||
| // This MUST BE called before Redirect30xInterceptor because latter assumes cookie store is already updated | |||
| CookieStore cookieStore = config.getCookieStore(); | |||
There was a problem hiding this comment.
CookieStore cookieStore = request.getCookieStore() != null ? request.getCookieStore() : config.getCookieStore() ;
| CookieStore cookieStore = config.getCookieStore(); | ||
| if (cookieStore != null) { | ||
| CookieStore requestCookieStore = request.getCookieStore(); | ||
| if (cookieStore != null || requestCookieStore != null) { |
|
|
||
| if (requestCookieStore != null) { | ||
| requestCookieStore.add(request.getUri(), c); | ||
| } |
|
@tranchitam Did you get a chance to have a look at my comments. The idea is to be able to override the global CookieStore with one scoped at request level. Those 2 are exclusive and only one should be updated. |
6ea11f4 to
f8fab66
Compare
… into feature/enable-cookie-store-at-request-level
|
Hi @slandelle, I already updated the pull request to fix your comments. Please take a look. Thanks |
|
@slandelle Can you have a look? |
|
Also there is #1610 now, however seems liks it's just re-using the commits from this pull request here. |
|
@slandelle Could you please take a look to this one? |
|
Hi @slandelle, @TomGranot have you got time to take a look into this pull request again? If there is no issue, we really want to merge this PR to master as soon as possible. |
Motivations:
Changes:
RequesthasgetCookieStore()method.RequestBuilderhassetCookieStore()method to set cookie store -> cookie store at request level isnullby default.Results:
Related issue:
#1565