org.jclouds.http.HttpResponseException: error after writing 159744/1772194 bytes to PUT https://jclouds-test.s3.amazonaws.com/main-testimg.png HTTP/1.1 connecting to PUT https://jclouds-test.s3.amazonaws.com/main-testimg.png HTTP/1.1

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • When the blobstore fails to upload a file, it might be worth retrying a couple of times rather than just aborting the whole process. OTOH, the failure would occur *before* any machines are launched, so the loss is limited. Here's an example stacktrace of a failed upload: Created blob cache container 'fr6mxqa4d6aa' located in '[id=EU, scope=REGION, description=EU, parent=aws-s3, iso3166Codes=[IE], metadata={}]' Uploading 'mydecorator-1.0-SNAPSHOT.tar.gz' to 'fr6mxqa4d6aa' blob cache. Jul 29, 2011 8:53:50 AM org.jclouds.logging.jdk.JDKLogger logWarn WARNING: Cannot retry after server error, command is not replayable: [method=AWSS3AsyncClient.putObject, request=PUT https://fr6mxqa4d6aa.s3.amazonaws.com/mydecorator-1.0-SNAPSHOT.tar.gz HTTP/1.1] Exception in thread "main" org.jclouds.http.HttpResponseException: error after writing 335872/637480 bytes to PUT https://fr6mxqa4d6aa.s3.amazonaws.com/mydecorator-1.0-SNAPSHOT.tar.gz HTTP/1.1 connecting to PUT https://fr6mxqa4d6aa.s3.amazonaws.com/mydecorator-1.0-SNAPSHOT.tar.gz HTTP/1.1 at org.jclouds.http.internal.BaseHttpCommandExecutorService$HttpResponseCallable.call(BaseHttpCommandExecutorService.java:183) at org.jclouds.http.internal.BaseHttpCommandExecutorService$HttpResponseCallable.call(BaseHttpCommandExecutorService.java:134) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334) at java.util.concurrent.FutureTask.run(FutureTask.java:166) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) at java.lang.Thread.run(Thread.java:679) Caused by: java.lang.RuntimeException: error after writing 335872/637480 bytes to PUT https://fr6mxqa4d6aa.s3.amazonaws.com/mydecorator-1.0-SNAPSHOT.tar.gz HTTP/1.1 at org.jclouds.http.internal.JavaUrlHttpCommandExecutorService.convert(JavaUrlHttpCommandExecutorService.java:245) at org.jclouds.http.internal.JavaUrlHttpCommandExecutorService.convert(JavaUrlHttpCommandExecutorService.java:77) at org.jclouds.http.internal.BaseHttpCommandExecutorService$HttpResponseCallable.call(BaseHttpCommandExecutorService.java:156) ... 6 more Caused by: java.io.IOException: Error writing request body to server at sun.net.www.protocol.http.HttpURLConnection$StreamingOutputStream.checkError(HttpURLConnection.java:2716) at sun.net.www.protocol.http.HttpURLConnection$StreamingOutputStream.write(HttpURLConnection.java:2699) at com.google.common.io.CountingOutputStream.write(CountingOutputStream.java:51) at com.google.common.io.ByteStreams.copy(ByteStreams.java:172) at org.jclouds.io.payloads.BasePayload.writeTo(BasePayload.java:67) at org.jclouds.http.internal.JavaUrlHttpCommandExecutorService.convert(JavaUrlHttpCommandExecutorService.java:243) ... 8 more Removing blob cache 'fr6mxqa4d6aa'
    via by Karel Vervaeke,
  • Re: put blob fails for s3 ap-northeast-1
    via by Ignasi Barrera,
  • GitHub comment 222#300679906
    via GitHub by benmur
    ,
  • If I GET a WebResource and read from the entity input stream until the end and then try to POST or PUT to the same resource, the second operation immediately fails with the following exception stack. If I do not read the InputStream to the end, the PUT succeeds fine. I wrote up and included a test case that is attached. com.sun.jersey.api.client.ClientHandlerException: java.io.IOException: Error writing request body to server at com.sun.jersey.client.urlconnection.URLConnectionClientHandler.handle(URLConnectionClientHandler.java:131) at com.sun.jersey.api.client.Client.handle(Client.java:629) at com.sun.jersey.api.client.WebResource.handle(WebResource.java:601) at com.sun.jersey.api.client.WebResource.put(WebResource.java:211) at jersey.GetPutTest.testGetFollowedByPut(GetPutTest.java:40) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:44) at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15) at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:41) at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:20) at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:28) at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:31) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:73) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:46) at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:180) at org.junit.runners.ParentRunner.access$000(ParentRunner.java:41) at org.junit.runners.ParentRunner$1.evaluate(ParentRunner.java:173) at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:28) at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:31) at org.junit.runners.ParentRunner.run(ParentRunner.java:220) at org.apache.maven.surefire.junit4.JUnit4TestSet.execute(JUnit4TestSet.java:59) at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTestSet(AbstractDirectoryTestSuite.java:115) at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(AbstractDirectoryTestSuite.java:102) at org.apache.maven.surefire.Surefire.run(Surefire.java:180) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(SurefireBooter.java:350) at org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.java:1021) Caused by: java.io.IOException: Error writing request body to server at sun.net.www.protocol.http.HttpURLConnection$StreamingOutputStream.checkError(HttpURLConnection.java:2802) at sun.net.www.protocol.http.HttpURLConnection$StreamingOutputStream.write(HttpURLConnection.java:2785) at com.sun.jersey.api.client.CommittingOutputStream.write(CommittingOutputStream.java:90) at com.sun.jersey.core.util.ReaderWriter.writeTo(ReaderWriter.java:115) at com.sun.jersey.core.provider.AbstractMessageReaderWriterProvider.writeTo(AbstractMessageReaderWriterProvider.java:76) at com.sun.jersey.core.impl.provider.entity.FileProvider.writeTo(FileProvider.java:103) at com.sun.jersey.core.impl.provider.entity.FileProvider.writeTo(FileProvider.java:64) at com.sun.jersey.api.client.RequestWriter.writeRequestEntity(RequestWriter.java:311) at com.sun.jersey.client.urlconnection.URLConnectionClientHandler._invoke(URLConnectionClientHandler.java:181) at com.sun.jersey.client.urlconnection.URLConnectionClientHandler.handle(URLConnectionClientHandler.java:129) ... 32 more
    via by joven,
    • org.jclouds.http.HttpResponseException: error after writing 159744/1772194 bytes to PUT https://jclouds-test.s3.amazonaws.com/main-testimg.png HTTP/1.1 connecting to PUT https://jclouds-test.s3.amazonaws.com/main-testimg.png HTTP/1.1 at org.jclouds.http.internal.BaseHttpCommandExecutorService$HttpResponseCallable.call(BaseHttpCommandExecutorService.java:185) at org.jclouds.http.internal.BaseHttpCommandExecutorService$HttpResponseCallable.call(BaseHttpCommandExecutorService.java:1) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) at java.util.concurrent.FutureTask.run(FutureTask.java:138) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:662) Caused by: java.lang.RuntimeException: error after writing 159744/1772194 bytes to PUT https://jclouds-test.s3.amazonaws.com/main-testimg.png HTTP/1.1 at org.jclouds.http.internal.JavaUrlHttpCommandExecutorService.convert(JavaUrlHttpCommandExecutorService.java:247) at org.jclouds.http.internal.JavaUrlHttpCommandExecutorService.convert(JavaUrlHttpCommandExecutorService.java:1) at org.jclouds.http.internal.BaseHttpCommandExecutorService$HttpResponseCallable.call(BaseHttpCommandExecutorService.java:157) ... 6 more Caused by: java.io.IOException: Error writing request body to server at sun.net.www.protocol.http.HttpURLConnection$StreamingOutputStream.checkError(HttpURLConnection.java:2802) at sun.net.www.protocol.http.HttpURLConnection$StreamingOutputStream.write(HttpURLConnection.java:2785) at com.google.common.io.CountingOutputStream.write(CountingOutputStream.java:51) at com.google.common.io.ByteStreams.copy(ByteStreams.java:171) at org.jclouds.io.payloads.BasePayload.writeTo(BasePayload.java:68) at org.jclouds.http.internal.JavaUrlHttpCommandExecutorService.convert(JavaUrlHttpCommandExecutorService.java:245) ... 8 more

    Users with the same issue

    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    16 more bugmates