aliyun / aliyun-oss-java-sdk

Aliyun OSS SDK for Java
1.22k stars 805 forks source link

版本3.16.0 上传putObject空指针异常 #467

Open 99246255 opened 1 year ago

99246255 commented 1 year ago

版本3.16.0

PutObjectResult putObjectResult = client.putObject(config.getBucketName(), putObjectBytesCmd.getKey(), putObjectBytesCmd.getInputStream(), metadata);

java.lang.NullPointerException: null at com.aliyun.oss.common.comm.DefaultServiceClient$DefaultRetryStrategy.shouldRetry(DefaultServiceClient.java:212) at com.aliyun.oss.common.comm.ServiceClient.shouldRetry(ServiceClient.java:320) at com.aliyun.oss.common.comm.ServiceClient.sendRequestImpl(ServiceClient.java:168) at com.aliyun.oss.common.comm.ServiceClient.sendRequest(ServiceClient.java:85) at com.aliyun.oss.internal.OSSOperation.send(OSSOperation.java:134) at com.aliyun.oss.internal.OSSOperation.doOperation(OSSOperation.java:192) at com.aliyun.oss.internal.OSSOperation.doOperation(OSSOperation.java:153) at com.aliyun.oss.internal.OSSObjectOperation.writeObjectInternal(OSSObjectOperation.java:1195) at com.aliyun.oss.internal.OSSObjectOperation.putObject(OSSObjectOperation.java:130) at com.aliyun.oss.OSSClient.putObject(OSSClient.java:619) at com.aliyun.oss.OSSClient.putObject(OSSClient.java:603)

99246255 commented 1 year ago

3.6.1版本仍有 专有云偶尔报错 2023-03-30 15:18:29,530 [http-nio-15062-exec-8] [WARN ]--[logId] com.aliyun.oss 70 -- [Server]Unable to execute HTTP request: null

[ResponseError]:

403 Forbidden

Request forbidden by administrative rules.

2023-03-30 15:18:29,536 [http-nio-15062-exec-8] [ERROR]--[logId] c.j.s.t.h.GlobalExceptionHandler 175 -- 系统异常:class java.lang.NullPointerException java.lang.NullPointerException: null at com.aliyun.oss.common.comm.DefaultServiceClient$DefaultRetryStrategy.shouldRetry(DefaultServiceClient.java:212) at com.aliyun.oss.common.comm.ServiceClient.shouldRetry(ServiceClient.java:320) at com.aliyun.oss.common.comm.ServiceClient.sendRequestImpl(ServiceClient.java:168) at com.aliyun.oss.common.comm.ServiceClient.sendRequest(ServiceClient.java:85) at com.aliyun.oss.internal.OSSOperation.send(OSSOperation.java:134) at com.aliyun.oss.internal.OSSOperation.doOperation(OSSOperation.java:192) at com.aliyun.oss.internal.OSSOperation.doOperation(OSSOperation.java:153) at com.aliyun.oss.internal.OSSObjectOperation.writeObjectInternal(OSSObjectOperation.java:1195) at com.aliyun.oss.internal.OSSObjectOperation.putObject(OSSObjectOperation.java:130) at com.aliyun.oss.OSSClient.putObject(OSSClient.java:619) at com.aliyun.oss.OSSClient.putObject(OSSClient.java:603)