开发者社区> 问答> 正文

我用 ossiosdemo上传一张图片为什么一直不能上传成功

我用 oss_ios_demo   上传一张图片  为什么一直不能上传成功  参数都有设置 求帮助

Wed, 11 Nov 2015 02:11:30 GMT
/yunlutong/889.png[;
2015-11-11 10:11:30.900 oss_ios_demo[58951:6226522] [fg0,255,0;start to build request[;
2015-11-11 10:11:30.900 oss_ios_demo[58951:6226522] [fg0,255,0;resolved host (null) and get ip: (null)[;
2015-11-11 10:11:30.900 oss_ios_demo[58951:6226522] [fg0,255,0;built full url: (null)://(null)/889.png[;
2015-11-11 10:11:30.901 oss_ios_demo[58951:6226522] [fg0,0,255;buidlInternalHttpRequest -
method: PUT
url: (null)://(null)/889.png
header: {
    Authorization = "OSS 1iDx2qvdsMLEA42dolH7TLj0ldtCDa:6HoclE9i4DnIThacAdYQTE1HIag=";
    "Content-Disposition" = "";
    "Content-Encoding" = "";
    "Content-MD5" = "";
    "Content-Type" = "";
    Date = "Wed, 11 Nov 2015 02:11:30 GMT";
    "User-Agent" = "MBAAS_OSS_IOS_2.0.2_iPhone-OS_8.4_zh-Hans_US";
}[;
2015-11-11 10:11:30.902 oss_ios_demo[58951:6226453] [fg0,255,0;networking request completed with error: Error Domain=NSURLErrorDomain Code=-1002 "unsupported URL" UserInfo=0x7fa6106ceab0 {NSUnderlyingError=0x7fa61051dec0 "The operation couldn’t be completed. (kCFErrorDomainCFNetwork error -1002.)", NSErrorFailingURLStringKey=(null)://(null)/889.png, NSErrorFailingURLKey=(null)://(null)/889.png, NSLocalizedDescription=unsupported URL}[;
2015-11-11 10:11:30.903 oss_ios_demo[58951:6226453] [fg0,0,255;current retry count: 1, retry type: 2[;
2015-11-11 10:11:30.903 oss_ios_demo[58951:6226453] objectKey: 889.png
2015-11-11 10:11:30.904 oss_ios_demo[58951:6226453] upload object failed, error: Error Domain=com.aliyun.oss.clientError Code=6 "unsupported URL" UserInfo=0x7fa610425670 {OriginErrorCode=-1002, NSErrorFailingURLStringKey=(null)://(null)/889.png, NSErrorFailingURLKey=(null)://(null)/889.png, NSUnderlyingError=0x7fa61051dec0 "The operation couldn’t be completed. (kCFErrorDomainCFNetwork error -1002.)", NSLocalizedDescription=unsupported URL}


展开
收起
我要学会后端开发 2015-11-11 10:34:09 10244 0
2 条回答
写回答
取消 提交回答
  • Re我用 ossiosdemo上传一张图片为什么一直不能上传成功
    看了出错信息,LZ是不是没有填endpoint 和 bucket名呢?
    put请求中的对应字段是空呢
    url: (null)://(null)/889.png
    2015-11-11 19:54:47
    赞同 展开评论 打赏
  • Re我用 ossiosdemo上传一张图片为什么一直不能上传成功
    贴一下初始化代码,是不是初始化的时候endpoint没填?
    2015-11-11 11:08:11
    赞同 展开评论 打赏
问答分类:
问答地址:
问答排行榜
最热
最新

相关电子书

更多
附件下载测试 立即下载
低代码开发师(初级)实战教程 立即下载
阿里巴巴DevOps 最佳实践手册 立即下载