Skip to content

[JENKINS-56252] Futures.addCallback uses method deleted in Guava 21 #414

@jenkins-infra-bot

Description

@jenkins-infra-bot

If you update to Guava 21+ and try to run a Pipeline build you will get

java.lang.NoSuchMethodError: com.google.common.util.concurrent.MoreExecutors.sameThreadExecutor()Lcom/google/common/util/concurrent/ListeningExecutorService;
	at org.jenkinsci.plugins.workflow.support.concurrent.Futures.addCallback(Futures.java:90)
	at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution.runInCpsVmThread(CpsFlowExecution.java:738)
	at ...

due to this removal. (Note that the method was not deprecated or even marked @​Beta in Guava 11, which we currently compile against—the deprecation happened later.)


Originally reported by jglick, imported from: Futures.addCallback uses method deleted in Guava 21
  • status: Open
  • priority: Minor
  • component(s): workflow-support-plugin
  • label(s): guava
  • resolution: Unresolved
  • votes: 0
  • watchers: 4
  • imported: 20260601-173816
Raw content of original issue

If you update to Guava 21+ and try to run a Pipeline build you will get

java.lang.NoSuchMethodError: com.google.common.util.concurrent.MoreExecutors.sameThreadExecutor()Lcom/google/common/util/concurrent/ListeningExecutorService;
	at org.jenkinsci.plugins.workflow.support.concurrent.Futures.addCallback(Futures.java:90)
	at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution.runInCpsVmThread(CpsFlowExecution.java:738)
	at ...

due to this removal. (Note that the method was not deprecated or even marked @Beta in Guava 11, which we currently compile against—the deprecation happened later.)

Metadata

Metadata

Assignees

No one assigned

    Type

    No fields configured for Bug.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions