Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

七牛上传文件过大IO中断 #20

Open
DogerRain opened this issue Dec 3, 2019 · 0 comments
Open

七牛上传文件过大IO中断 #20

DogerRain opened this issue Dec 3, 2019 · 0 comments

Comments

@DogerRain
Copy link

            Zone z = Zone.autoZone();
            Configuration c = new Configuration(z);
            //创建上传对象
            UploadManager uploadManager = new UploadManager(c);
            //调用put方法上传
            Response res = uploadManager.put(FilePath, key, auth.uploadToken(qiniu.getBn()));

这里res返回报IO中断了,但是文件最后确实上传成功了,而且项目会重启:
Completed initialization in 18 ms
2019-12-03 10:48:40.912 INFO 11012 --- [nio-8848-exec-1] c.y.system.controller.QiNiuController : 文件原始路径=========>E:\projet\RainBlog\target\classes\upload
2019-12-03 10:48:40.912 INFO 11012 --- [nio-8848-exec-1] c.y.system.controller.QiNiuController : 新文件名称===========>1575341320897.jpg
2019-12-03 10:48:44.797 INFO 11012 --- [ Thread-5] o.s.s.concurrent.ThreadPoolTaskExecutor : Shutting down ExecutorService 'applicationTaskExecutor'
2019-12-03 10:48:44.800 INFO 11012 --- [ Thread-5] com.alibaba.druid.pool.DruidDataSource : {dataSource-1} closed
java.io.InterruptedIOException: thread interrupted
at okio.Timeout.throwIfReached(Timeout.java:145)
at okio.Okio$1.write(Okio.java:76)
at okio.AsyncTimeout$1.write(AsyncTimeout.java:180)
at okio.RealBufferedSink.emitCompleteSegments(RealBufferedSink.java:171)
at okio.RealBufferedSink.write(RealBufferedSink.java:41)
at okhttp3.internal.http1.Http1Codec$FixedLengthSink.write(Http1Codec.java:292)
at okio.ForwardingSink.write(ForwardingSink.java:35)
at okhttp3.internal.http.CallServerInterceptor$CountingSink.write(CallServerInterceptor.java:134)
at okio.RealBufferedSink.emitCompleteSegments(RealBufferedSink.java:171)
at okio.RealBufferedSink.write(RealBufferedSink.java:91)
at com.qiniu.http.Client$3.writeTo(Client.java:130)
at okhttp3.internal.http.CallServerInterceptor.intercept(CallServerInterceptor.java:72)
at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147)
at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121)
at com.qiniu.http.Client$1.intercept(Client.java:69)
at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147)
at okhttp3.internal.connection.ConnectInterceptor.intercept(ConnectInterceptor.java:45)
at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147)
at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121)
at okhttp3.internal.cache.CacheInterceptor.intercept(CacheInterceptor.java:93)
at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147)
at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121)
at okhttp3.internal.http.BridgeInterceptor.intercept(BridgeInterceptor.java:93)
at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147)
at okhttp3.internal.http.RetryAndFollowUpInterceptor.intercept(RetryAndFollowUpInterceptor.java:125)
at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147)
at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121)
at okhttp3.RealCall.getResponseWithInterceptorChain(RealCall.java:200)

不知道作者是否遇到过

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant