Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[JEP-233] Blog post about Guava library upgrade #4640

Merged
merged 9 commits into from
Nov 9, 2021
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions content/_data/authors/basil.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
name: "Basil Crow"
github: basil
twitter: bcrow
linkedin: basilcrow
---
Basil is a long-time Jenkins user and contributor, a Jenkins core maintainer, and the maintainer of the plugin:email-ext[Email Extension], plugin:timestamper[Timestamper], and plugin:swarm[Swarm] plugins (among others).
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

First blog post! 👋

Basil enjoys working on open source software in his free time.
71 changes: 71 additions & 0 deletions content/blog/2021/11/2021-11-TODO-guava-upgrade.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
---
layout: post
title: "Guava library upgrade (breaking changes!)"
tags:
- jenkins
- core
- developer
- announcement
author: basil
description: >
Jenkins has upgraded the Guava library to the latest version.
As a result, plugins must be upgraded for compatibility.
opengraph:
image: /images/post-images/2021-11-guava-upgrade/guava-upgrade.png
---

image:/images/post-images/2021-11-guava-upgrade/guava-upgrade.png[Guava Upgrade, role=center]

== Summary

Jenkins bundles https://guava.dev/[Guava], a core Java library from Google.
Beginning with Jenkins 2.TODO (released on TODO), Jenkins has upgraded the Guava library from https://github.com/google/guava/releases/tag/v11.0.1[11.0.1] (released on January 9, 2012) to https://github.com/google/guava/releases/tag/v31.0.1[31.0.1] (released on September 27, 2021).
basil marked this conversation as resolved.
Show resolved Hide resolved
Plugins have already been prepared to support the new version of Guava in link:https://issues.jenkins.io/issues/?jql=labels%20in%20(JEP-233)[JEP-233].
**Use the Plugin Manager to upgrade all plugins before _and_ after upgrading to Jenkins 2.TODO.**

== Motivation

Many security-conscious organizations using, or planning to use, Jenkins run off-the-shelf security scanners to look for known vulnerabilities.
These commonly flag the obsolete Guava library as susceptible to a serialization-related vulnerability (https://github.com/google/guava/wiki/CVE-2018-10237[CVE-2018-10237]) and recommend upgrading.
While Jenkins uses link:/blog/2018/03/15/jep-200-lts/[JEP-200] to form an explicit list of allowed classes for deserialization,
and the two Guava classes affected by CVE-2018-10237 are not and will never be added to the list,
it is time-consuming for the link:/security/team/[security team] to respond to purported security reports
and for users to justify exemptions from policy to use Jenkins anyway.

Furthermore, the decade-old version of Guava has long been a maintenance burden for Jenkins developers.
In a world where Dependabot offers upgrades to libraries released just hours before,
it is unpleasant to be working with dependencies that are many years old.

For more information, see https://github.com/jenkinsci/jep/blob/master/jep/233/README.adoc[JEP-233].

== Upgrading

The vast majority of plugins have already been prepared to support the new version of Guava in link:https://issues.jenkins.io/issues/?jql=labels%20in%20(JEP-233)[JEP-233].
Jenkins users need only upgrade plugins to compatible versions as documented in the "Released As" field in Jira.
**It is critical to use the Plugin Manager to upgrade all plugins before _and_ after upgrading to Jenkins 2.TODO.**
Failure to upgrade plugins to compatible versions may result in `ClassNotFoundException`, `NoClassDefFoundError`, or other low-level Java errors.

== Reporting issues

If you find a regression in a plugin, please file a bug report in Jira:

* link:https://issues.jenkins.io/issues/?jql=labels%20in%20(JEP-233)%20and%20status%20not%20in%20(resolved%2C%20closed)[Open JEP-233 issues]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Jira makes it hard to find but there a search term for "unresolved". Slightly cleaner than "not in (resolved, closed)".

Suggested change
* link:https://issues.jenkins.io/issues/?jql=labels%20in%20(JEP-233)%20and%20status%20not%20in%20(resolved%2C%20closed)[Open JEP-233 issues]
* link:https://issues.jenkins.io/issues/?jql=resolution%20%3D%20Unresolved%20AND%20labels%20%3D%20JEP-233[Open JEP-233 issues]

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This query excludes issues whose status is "Fixed but Unreleased." I want to include such issues in the query because from the user's perspective the plugin still has a compatibility problem until a release occurs.


When reporting an issue, include the following information:

. Use the `JEP-233` label.
. Provide the _complete_ list of installed plugins as suggested in the link:/doc/book/system-administration/diagnosing-errors/#how-to-report-a-bug[bug reporting guidelines].
. Provide the _complete_ stack trace, if relevant.
. Provide steps to reproduce the issue _from scratch_ on a minimal Jenkins installation; the scenario should fail when the steps are followed on Jenkins 2.TODO or later and pass when the steps are followed on Jenkins 2.TODO or earlier.

If you maintain a Jenkins plugin with an open JEP-233 issue,
then please check if there is a pull request awaiting merge or release.
If you use an unmaintained Jenkins plugin with an open JEP-233 issue,
consider stepping up and link:/doc/developer/plugin-governance/adopt-a-plugin/[adopting the plugin] to release a compatible version.

== Conclusion

We expect to see a bit of disruption from these changes
but hope that in the long run they will save time for core and plugin developers
and lead to a more secure and stable tool.
Please reach out on the link:/mailing-lists/[developers' list] with any questions or suggestions.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.