Home > Net >  Upload photos to ali cloud Oss is not complete
Upload photos to ali cloud Oss is not complete

Time:10-18

Ubuntu system used in the Core Asp.Net upload pictures to ali cloud oss, upload pictures is not complete, can upload only rarely part of the normal
uploaded under Windows


The code is as follows:
Uri the Uri=new Uri (" http://oss-cn-shanghai.aliyuncs.com ");
OssClient OssClient=new OssClient (uri, AccessKeyID, AccessKeySecret);

MemoryStream requestContent=new MemoryStream (bytes);
PutObjectRequest _objRequest=new PutObjectRequest (BucketName savePath, requestContent);
Var s=ossClient. PutObject (_objRequest);

CodePudding user response:

In general should avoid using this particular platform API, especially in the copycat cloud server vendors,
  •  Tags:  
  • C#
  • Related