0
Zone z = Zone.zone2();
    Configuration cfg = new Configuration(z);
       UploadManager uploadManager=new UploadManager(cfg); 
       上面UploadManager这个代码报错, 
       引用jar为:
       gson-2.8.5.jar
       happy-dns-java-0.1.6.jar
       junit-4.13-beta-3.jar
       okhttp-4.0.0-alpha02.jar
       okio-2.2.2.jar
       qiniu-java-sdk-7.2.18.jar
       
       错误log如下:
       java.lang.NoClassDefFoundError: kotlin/Unit
okhttp3.Dispatcher.setMaxRequests(Dispatcher.kt:48)
com.qiniu.http.Client.<init>(Client.java:56)
com.qiniu.http.Client.<init>(Client.java:42)
com.qiniu.storage.UploadManager.<init>(UploadManager.java:42)
com.qiniu.storage.UploadManager.<init>(UploadManager.java:29)
com.hoosee.actions.util.FileClass.upload_qiniuFile(FileClass.java:983)
5月27日提问

1 个回答

0

换下jar包试试,本地用这个测试是没问题的。
gson-2.6.2.jar
happy-dns-java-0.1.4.jar
okhttp-3.3.1.jar
okio-1.8.0.jar
qiniu-java-sdk-7.2.18.jar

推广链接