GitHub user MarkMielke opened a pull request:
https://github.com/apache/httpcomponents-client/pull/108
Fix HttpClient 4.5.4 regression in BasicCookieStore serialization.
HttpClient 4.5.4 modified BasicCookieStore to introduce a new
ReadWriteLock field to improve performance. Unfortunately this
also changed the serialized data structure, and any objects
serialized using HttpClient 4.5.3 and before would be unusable
after restore in HttpClient 4.5.4 due to the new "lock" field
being null.
The fix is to change "lock" to be transient, and ensure it is
correctly instantiated upon object restore. This restores
compatibility with HttpClient 4.5.3, as well as maintaining
compatible with the intermediate versions containing the
regression. This also avoids unnecessary serialization of
the new "lock" field, which does not need to be persisted.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/MarkMielke/httpcomponents-client 4.5.x
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/httpcomponents-client/pull/108.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #108
----
commit 517396df0ce598d29b7f77d3bf977e26e651b217
Author: Mark Mielke <mmielke@...>
Date: 2018-08-08T10:43:55Z
Fix HttpClient 4.5.4 regression in BasicCookieStore serialization.
HttpClient 4.5.4 modified BasicCookieStore to introduce a new
ReadWriteLock field to improve performance. Unfortunately this
also changed the serialized data structure, and any objects
serialized using HttpClient 4.5.3 and before would be unusable
after restore in HttpClient 4.5.4 due to the new "lock" field
being null.
The fix is to change "lock" to be transient, and ensure it is
correctly instantiated upon object restore. This restores
compatibility with HttpClient 4.5.3, as well as maintaining
compatible with the intermediate versions containing the
regression. This also avoids unnecessary serialization of
the new "lock" field, which does not need to be persisted.
----
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]