-
Improvement
-
Resolution: Fixed
-
Minor
-
None
The latest OkHttp (v2.7.5) is over three years old. The web has come a long way. There are a significant number of Jenkins JIRA and Zendesk issues related to using this ancient library in key plugins.
We should upgrade Jenkins to use OkHttp3.
NOTES:
- OkHttp 2.x and 3.x exist in separate packages and can run side-by-side without conflict. However, different versions of 3.x (and okhttp3 4.x) may be incompatible if clients are using obsolete classes/methods.
- OkHttp 3.12.2 is the last version that is reasonably compatible with 2.7.5. Upgrading will require some changes but not huge ones.
- OkHttp 3.13.1 has some notable incompatibilities with 2.7.5, but also some better defaults.
- OkHttp 3.14.1 removes OkHttpUrlFactory which is a serious version-incompatible API change for several plugins. The github-api library pulled in a shim that provides a workaround OkHttpUrlFactory.
Early exploration of this upgrade was started to test whether it would address issues such as JENKINS-54126.
Finding so far while using 3.12.2:
- okio v2.2.x is needed for okhttp3.
- Some special class loading settings are needed to get the right versions okhttp3 and okio to be loaded.
(Last updated May 4, 2020):
The rebuilt incremental can be found at:
https://repo.jenkins-ci.org/incrementals/org/jenkins-ci/plugins/github-branch-source/2.7.2-rc1149.0f9fd89495cc/
This version uses okhttp3 and is compatible with github-api-plugin 1.110+.
- is related to
-
JENKINS-54126 Jenkinsfile not found in PR on GitHub -- Does not meet criteria
- Closed