java.io.IOException: Call fails for Destination [bucketName=REDACTED, objectName=REDACTED]: com.amazonaws.ResetException: Failed to reset the request input stream; If the request involves an input stream, the maximum stream buffer size can be configured via request.getRequestClientOptions().setReadLimit(int):: Failed after 1 tries.

Jenkins JIRA | Joshua Spence | 8 months ago
  1. 0

    After upgrading the S3 plugin to version 0.9.2 we are seeing S3 uploads fail intermittently. Below is a stack trace (with some details redacted): ``` Publish artifacts to S3 Bucket Using S3 profile: REDACTED Publish artifacts to S3 Bucket bucket=REDACTED, file=9fc530ed8ac7866e6cfcc5132c34614b1e5e6dbd region=us-east-1, upload from slave=false managed=false , server encryption false Publish artifacts to S3 Bucket bucket=REDACTED, file=master region=us-east-1, upload from slave=false managed=false , server encryption false ERROR: Failed to upload files java.io.IOException: Call fails for Destination [bucketName=REDACTED, objectName=REDACTED]: com.amazonaws.ResetException: Failed to reset the request input stream; If the request involves an input stream, the maximum stream buffer size can be configured via request.getRequestClientOptions().setReadLimit(int):: Failed after 1 tries. at hudson.plugins.s3.S3Profile.repeat(S3Profile.java:220) at hudson.plugins.s3.S3Profile.upload(S3Profile.java:145) at hudson.plugins.s3.S3BucketPublisher.perform(S3BucketPublisher.java:193) at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:78) at hudson.tasks.BuildStepMonitor$2.perform(BuildStepMonitor.java:32) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:782) at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:723) at hudson.model.Build$BuildExecution.post2(Build.java:185) at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:668) at hudson.model.Run.execute(Run.java:1763) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:98) at hudson.model.Executor.run(Executor.java:410) Caused by: com.amazonaws.ResetException: Failed to reset the request input stream; If the request involves an input stream, the maximum stream buffer size can be configured via request.getRequestClientOptions().setReadLimit(int) at com.amazonaws.http.AmazonHttpClient.executeOneRequest(AmazonHttpClient.java:755) at com.amazonaws.http.AmazonHttpClient.executeHelper(AmazonHttpClient.java:576) at com.amazonaws.http.AmazonHttpClient.doExecute(AmazonHttpClient.java:362) at com.amazonaws.http.AmazonHttpClient.executeWithTimer(AmazonHttpClient.java:328) at com.amazonaws.http.AmazonHttpClient.execute(AmazonHttpClient.java:307) at com.amazonaws.services.s3.AmazonS3Client.invoke(AmazonS3Client.java:3659) at com.amazonaws.services.s3.AmazonS3Client.doUploadPart(AmazonS3Client.java:2795) at com.amazonaws.services.s3.AmazonS3Client.uploadPart(AmazonS3Client.java:2780) at com.amazonaws.services.s3.transfer.internal.UploadCallable.uploadPartsInSeries(UploadCallable.java:255) at com.amazonaws.services.s3.transfer.internal.UploadCallable.uploadInParts(UploadCallable.java:189) at com.amazonaws.services.s3.transfer.internal.UploadCallable.call(UploadCallable.java:121) at com.amazonaws.services.s3.transfer.internal.UploadMonitor.call(UploadMonitor.java:139) at com.amazonaws.services.s3.transfer.internal.UploadMonitor.call(UploadMonitor.java:47) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) Caused by: java.io.IOException: Resetting to invalid mark at java.io.BufferedInputStream.reset(BufferedInputStream.java:448) at com.amazonaws.internal.SdkBufferedInputStream.reset(SdkBufferedInputStream.java:106) at com.amazonaws.internal.SdkFilterInputStream.reset(SdkFilterInputStream.java:102) at com.amazonaws.event.ProgressInputStream.reset(ProgressInputStream.java:139) at com.amazonaws.internal.SdkFilterInputStream.reset(SdkFilterInputStream.java:102) at com.amazonaws.http.AmazonHttpClient.executeOneRequest(AmazonHttpClient.java:753) ... 16 more Build step 'Publish artifacts to S3 Bucket' changed build result to UNSTABLE ``` The file being uploaded is a 450MB tarball.

    Jenkins JIRA | 8 months ago | Joshua Spence
    java.io.IOException: Call fails for Destination [bucketName=REDACTED, objectName=REDACTED]: com.amazonaws.ResetException: Failed to reset the request input stream; If the request involves an input stream, the maximum stream buffer size can be configured via request.getRequestClientOptions().setReadLimit(int):: Failed after 1 tries.
  2. 0

    [JENKINS-34216] Failed to reset the request input stream - Jenkins JIRA

    jenkins-ci.org | 5 months ago
    com.amazonaws.ResetException: Failed to reset the request input stream; If the request involves an input stream, the maximum stream buffer size can be configured via request.getRequestClientOptions().setReadLimit(int):: Failed after 1 tries.
  3. 0

    [JIRA] [s3-plugin] (JENKINS-34216) Failed to reset the request input stream

    Google Groups | 8 months ago | jo...@freelancer.com (JIRA)
    java.io.IOException: Call fails for Destination <span class="error">[bucketName=REDACTED, objectName=REDACTED]</span>: com.amazonaws.ResetException: Failed to reset the request input stream; If the request involves an input stream, the maximum stream buffer size can be configured via request.getRequestClientOptions().setReadLimit(int):: Failed after 1 tries.
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    After upgrading the S3 plugin to version 0.9.2 we are seeing S3 uploads fail intermittently. Below is a stack trace (with some details redacted): ``` Publish artifacts to S3 Bucket Using S3 profile: REDACTED Publish artifacts to S3 Bucket bucket=REDACTED, file=9fc530ed8ac7866e6cfcc5132c34614b1e5e6dbd region=us-east-1, upload from slave=false managed=false , server encryption false Publish artifacts to S3 Bucket bucket=REDACTED, file=master region=us-east-1, upload from slave=false managed=false , server encryption false ERROR: Failed to upload files java.io.IOException: Call fails for Destination [bucketName=REDACTED, objectName=REDACTED]: com.amazonaws.ResetException: Failed to reset the request input stream; If the request involves an input stream, the maximum stream buffer size can be configured via request.getRequestClientOptions().setReadLimit(int):: Failed after 1 tries. at hudson.plugins.s3.S3Profile.repeat(S3Profile.java:220) at hudson.plugins.s3.S3Profile.upload(S3Profile.java:145) at hudson.plugins.s3.S3BucketPublisher.perform(S3BucketPublisher.java:193) at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:78) at hudson.tasks.BuildStepMonitor$2.perform(BuildStepMonitor.java:32) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:782) at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:723) at hudson.model.Build$BuildExecution.post2(Build.java:185) at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:668) at hudson.model.Run.execute(Run.java:1763) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:98) at hudson.model.Executor.run(Executor.java:410) Caused by: com.amazonaws.ResetException: Failed to reset the request input stream; If the request involves an input stream, the maximum stream buffer size can be configured via request.getRequestClientOptions().setReadLimit(int) at com.amazonaws.http.AmazonHttpClient.executeOneRequest(AmazonHttpClient.java:755) at com.amazonaws.http.AmazonHttpClient.executeHelper(AmazonHttpClient.java:576) at com.amazonaws.http.AmazonHttpClient.doExecute(AmazonHttpClient.java:362) at com.amazonaws.http.AmazonHttpClient.executeWithTimer(AmazonHttpClient.java:328) at com.amazonaws.http.AmazonHttpClient.execute(AmazonHttpClient.java:307) at com.amazonaws.services.s3.AmazonS3Client.invoke(AmazonS3Client.java:3659) at com.amazonaws.services.s3.AmazonS3Client.doUploadPart(AmazonS3Client.java:2795) at com.amazonaws.services.s3.AmazonS3Client.uploadPart(AmazonS3Client.java:2780) at com.amazonaws.services.s3.transfer.internal.UploadCallable.uploadPartsInSeries(UploadCallable.java:255) at com.amazonaws.services.s3.transfer.internal.UploadCallable.uploadInParts(UploadCallable.java:189) at com.amazonaws.services.s3.transfer.internal.UploadCallable.call(UploadCallable.java:121) at com.amazonaws.services.s3.transfer.internal.UploadMonitor.call(UploadMonitor.java:139) at com.amazonaws.services.s3.transfer.internal.UploadMonitor.call(UploadMonitor.java:47) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) Caused by: java.io.IOException: Resetting to invalid mark at java.io.BufferedInputStream.reset(BufferedInputStream.java:448) at com.amazonaws.internal.SdkBufferedInputStream.reset(SdkBufferedInputStream.java:106) at com.amazonaws.internal.SdkFilterInputStream.reset(SdkFilterInputStream.java:102) at com.amazonaws.event.ProgressInputStream.reset(ProgressInputStream.java:139) at com.amazonaws.internal.SdkFilterInputStream.reset(SdkFilterInputStream.java:102) at com.amazonaws.http.AmazonHttpClient.executeOneRequest(AmazonHttpClient.java:753) ... 16 more Build step 'Publish artifacts to S3 Bucket' changed build result to UNSTABLE ``` The file being uploaded is a 450MB tarball.

    Jenkins JIRA | 8 months ago | Joshua Spence
    java.io.IOException: Call fails for Destination [bucketName=REDACTED, objectName=REDACTED]: com.amazonaws.ResetException: Failed to reset the request input stream; If the request involves an input stream, the maximum stream buffer size can be configured via request.getRequestClientOptions().setReadLimit(int):: Failed after 1 tries.
  6. 0

    AWS S3: Uploading large file fails with ResetException: Failed to reset the request input stream

    Stack Overflow | 2 years ago | lolski
    com.amazonaws.ResetException: Failed to reset the request input stream; If the request involves an input stream, the maximum stream buffer size can be configured via request.getRequestClientOptions().setReadLimit(int)

    3 unregistered visitors
    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.io.IOException

      Resetting to invalid mark

      at java.io.BufferedInputStream.reset()
    2. Java RT
      BufferedInputStream.reset
      1. java.io.BufferedInputStream.reset(BufferedInputStream.java:448)
      1 frame
    3. AWS SDK for Java - Core
      AmazonHttpClient.execute
      1. com.amazonaws.internal.SdkBufferedInputStream.reset(SdkBufferedInputStream.java:106)
      2. com.amazonaws.internal.SdkFilterInputStream.reset(SdkFilterInputStream.java:102)
      3. com.amazonaws.event.ProgressInputStream.reset(ProgressInputStream.java:139)
      4. com.amazonaws.internal.SdkFilterInputStream.reset(SdkFilterInputStream.java:102)
      5. com.amazonaws.http.AmazonHttpClient.executeOneRequest(AmazonHttpClient.java:753)
      6. com.amazonaws.http.AmazonHttpClient.executeHelper(AmazonHttpClient.java:576)
      7. com.amazonaws.http.AmazonHttpClient.doExecute(AmazonHttpClient.java:362)
      8. com.amazonaws.http.AmazonHttpClient.executeWithTimer(AmazonHttpClient.java:328)
      9. com.amazonaws.http.AmazonHttpClient.execute(AmazonHttpClient.java:307)
      9 frames
    4. AWS Java SDK for Amazon S3
      UploadMonitor.call
      1. com.amazonaws.services.s3.AmazonS3Client.invoke(AmazonS3Client.java:3659)
      2. com.amazonaws.services.s3.AmazonS3Client.doUploadPart(AmazonS3Client.java:2795)
      3. com.amazonaws.services.s3.AmazonS3Client.uploadPart(AmazonS3Client.java:2780)
      4. com.amazonaws.services.s3.transfer.internal.UploadCallable.uploadPartsInSeries(UploadCallable.java:255)
      5. com.amazonaws.services.s3.transfer.internal.UploadCallable.uploadInParts(UploadCallable.java:189)
      6. com.amazonaws.services.s3.transfer.internal.UploadCallable.call(UploadCallable.java:121)
      7. com.amazonaws.services.s3.transfer.internal.UploadMonitor.call(UploadMonitor.java:139)
      8. com.amazonaws.services.s3.transfer.internal.UploadMonitor.call(UploadMonitor.java:47)
      8 frames
    5. Java RT
      Thread.run
      1. java.util.concurrent.FutureTask.run(FutureTask.java:266)
      2. java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
      3. java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
      4. java.lang.Thread.run(Thread.java:745)
      4 frames