tus-android-client icon indicating copy to clipboard operation
tus-android-client copied to clipboard

Software casued connection abort while switching network

Open AshwinN796 opened this issue 1 year ago • 1 comments

Describe the bug Hello, i am facing strange issue while uploading file from android device using tus client. It gives "javax.net.ssl.SSLException: Write error: ssl=0xb400007824f03618: I/O error during system call, Software caused connection abort" exception

To Reproduce Steps to reproduce the behavior:

  1. Start file upload using wifi connection
  2. Then switch network from Wifi to mobile network
  3. See error

Error javax.net.ssl.SSLException: Write error: ssl=0xb400007824f03618: I/O error during system call, Software caused connection abort at com.google.android.gms.org.conscrypt.NativeCrypto.SSL_write(Native Method) at com.google.android.gms.org.conscrypt.NativeSsl.write(:com.google.android.gms@[email protected] (190400-455379205):3) at com.google.android.gms.org.conscrypt.ConscryptFileDescriptorSocket$SSLOutputStream.write(:com.google.android.gms@[email protected] (190400-455379205):5) at com.android.okhttp.okio.Okio$1.write(Okio.java:78) at com.android.okhttp.okio.AsyncTimeout$1.write(AsyncTimeout.java:157) at com.android.okhttp.okio.RealBufferedSink.emitCompleteSegments(RealBufferedSink.java:177) at com.android.okhttp.okio.RealBufferedSink.write(RealBufferedSink.java:47) at com.android.okhttp.internal.http.Http1xStream$ChunkedSink.write(Http1xStream.java:327) at com.android.okhttp.okio.RealBufferedSink.emitCompleteSegments(RealBufferedSink.java:177) at com.android.okhttp.okio.RealBufferedSink$1.write(RealBufferedSink.java:199) at io.tus.java.client.TusUploader.uploadChunk(TusUploader.java:190)

AshwinN796 avatar Jul 14 '22 06:07 AshwinN796

I haven't seen this error personally, but I assume this error is not preventable when switching the network. However, this is not a problem since tus is built for the purpose of resuming after such errors. Please use the TusExecutor class as shown in the usage example in the README: https://github.com/tus/tus-android-client#usage It allows you to easily recover from these errors and resume uploading.

Acconut avatar Jul 16 '22 13:07 Acconut