Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-65381

Getting java.lang.NoClassDefFoundError: Could not initialize class com.amazonaws.services.s3.S3CredentialsProviderChain

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Blocker Blocker
    • pipeline-aws-plugin
    • None
    • Jenkins - 2.263.1
      Amazon Web Services SDK - 1.11.976
      Pipeline: AWS Steps - 1.43

      (Very) intermittently when trying to download files from S3 using `s3Download`.

      Downloading s3://.../TENSORFLOWVIEW-tensorflow to file:/opt/jenkins/workspace/.../TENSORFLOWVIEW-tensorflow
      

      results in:

      hudson.remoting.Channel$CallSiteStackTrace: Remote call to EC2 (dev-ec2) - Ubuntu_18.04_c5a12xlarge (sir-691g4igq)
      2021-04-15 18:08:52  		at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1800)
      2021-04-15 18:08:52  		at hudson.remoting.UserRequest$ExceptionResponse.retrieve(UserRequest.java:357)
      2021-04-15 18:08:52  		at hudson.remoting.Channel.call(Channel.java:1001)
      2021-04-15 18:08:52  		at hudson.FilePath.act(FilePath.java:1070)
      2021-04-15 18:08:52  		at hudson.FilePath.act(FilePath.java:1059)
      2021-04-15 18:08:52  		at de.taimos.pipeline.aws.S3DownloadStep$Execution.run(S3DownloadStep.java:149)
      2021-04-15 18:08:52  		at de.taimos.pipeline.aws.S3DownloadStep$Execution.run(S3DownloadStep.java:113)
      2021-04-15 18:08:52  		at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution.lambda$start$0(SynchronousNonBlockingStepExecution.java:47)
      2021-04-15 18:08:52  		at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
      2021-04-15 18:08:52  		at java.util.concurrent.FutureTask.run(FutureTask.java:266)
      2021-04-15 18:08:52  		at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
      2021-04-15 18:08:52  		at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
      2021-04-15 18:08:52  		at java.lang.Thread.run(Thread.java:748)
      2021-04-15 18:08:52  java.lang.NoClassDefFoundError: Could not initialize class com.amazonaws.services.s3.S3CredentialsProviderChain
      2021-04-15 18:08:52  	at com.amazonaws.services.s3.AmazonS3ClientBuilder.standard(AmazonS3ClientBuilder.java:46)
      2021-04-15 18:08:52  	at de.taimos.pipeline.aws.AbstractS3Step$S3ClientOptions.createAmazonS3ClientBuilder(AbstractS3Step.java:87)
      2021-04-15 18:08:52  	at de.taimos.pipeline.aws.S3DownloadStep$RemoteDownloader.invoke(S3DownloadStep.java:177)
      2021-04-15 18:08:52  	at de.taimos.pipeline.aws.S3DownloadStep$RemoteDownloader.invoke(S3DownloadStep.java:156)
      2021-04-15 18:08:52  	at hudson.FilePath$FileCallableWrapper.call(FilePath.java:3122)
      2021-04-15 18:08:52  	at hudson.remoting.UserRequest.perform(UserRequest.java:211)
      2021-04-15 18:08:52  	at hudson.remoting.UserRequest.perform(UserRequest.java:54)
      2021-04-15 18:08:52  	at hudson.remoting.Request$2.run(Request.java:375)
      2021-04-15 18:08:52  	at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:73)
      2021-04-15 18:08:52  	at java.util.concurrent.FutureTask.run(FutureTask.java:264)
      2021-04-15 18:08:52  	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
      2021-04-15 18:08:52  	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
      2021-04-15 18:08:52  	at java.lang.Thread.run(Thread.java:834)
      2021-04-15 18:08:52  Caused: java.io.IOException: Remote call on EC2 (dev-ec2) - Ubuntu_18.04_c5a12xlarge (sir-691g4igq) failed
      2021-04-15 18:08:52  	at hudson.remoting.Channel.call(Channel.java:1007)
      2021-04-15 18:08:52  	at hudson.FilePath.act(FilePath.java:1070)
      2021-04-15 18:08:52  	at hudson.FilePath.act(FilePath.java:1059)
      2021-04-15 18:08:52  	at de.taimos.pipeline.aws.S3DownloadStep$Execution.run(S3DownloadStep.java:149)
      2021-04-15 18:08:52  	at de.taimos.pipeline.aws.S3DownloadStep$Execution.run(S3DownloadStep.java:113)
      2021-04-15 18:08:52  	at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution.lambda$start$0(SynchronousNonBlockingStepExecution.java:47)
      2021-04-15 18:08:52  	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
      2021-04-15 18:08:52  	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
      2021-04-15 18:08:52  	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
      2021-04-15 18:08:52  	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
      2021-04-15 18:08:52  	at java.lang.Thread.run(Thread.java:748)
      

      Thinking it might be linked to JENKINS-26677.

      Not sure if it helps but only one build, out of 8, failed like this and all builds since have worked too.

            hoegertn Thorsten Hoeger
            canuck1987 Tim Brown
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: