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

OSS uploadFile 方法返回 etag 信息异常 #178

Open
sxin0 opened this issue Jul 9, 2021 · 1 comment
Open

OSS uploadFile 方法返回 etag 信息异常 #178

sxin0 opened this issue Jul 9, 2021 · 1 comment

Comments

@sxin0
Copy link

sxin0 commented Jul 9, 2021

调用方式

etag返回信息多了双引号!!!,请看示例!!!
etag返回34长度的带双引号字符: "961728770973094694ADF7907576434A"

$ossClient = new OssClient('<access_key_id>','<access_key_secret>','<endpoint>');
$result = $ossClient->uploadFile('<bucket>', '<fileName>', '<filePath>');
var_dump($result);die;
// 输出
array(17) {
  ["server"]=>
  string(9) "AliyunOSS"
  ["date"]=>
  string(29) "Fri, 09 Jul 2021 08:19:25 GMT"
  ["content-length"]=>
  string(1) "0"
  ["connection"]=>
  string(10) "keep-alive"
  ["x-oss-request-id"]=>
  string(24) "60E8068xxx..."
  ["x-oss-server-side-encryption"]=>
  string(6) "AES256"
  ["etag"]=>
  string(34) ""961728770973094694ADF7907576434A""     -- 注意看这里
  ["x-oss-hash-crc64ecma"]=>
  string(20) "10741xxx..."
  ...

版本信息

> composer show aliyuncs/oss-sdk-php
name     : aliyuncs/oss-sdk-php
descrip. : Aliyun OSS SDK for PHP
keywords : 
versions : * v2.4.2
type     : library
license  : MIT License (MIT) (OSI approved) https://spdx.org/licenses/MIT.html#licenseText
homepage : http://www.aliyun.com/product/oss/
source   : [git] https://github.com/aliyun/aliyun-oss-php-sdk.git 0c9d902c33847c07efc66c4cdf823deaea8fc2b6
dist     : [zip] https://api.github.com/repos/aliyun/aliyun-oss-php-sdk/zipball/0c9d902c33847c07efc66c4cdf823deaea8fc2b6 0c9d902c33847c07efc66c4cdf823deaea8fc2b6
path     : /data/xxx/vendor/aliyuncs/oss-sdk-php
names    : aliyuncs/oss-sdk-php

support
issues : https://github.com/aliyun/aliyun-oss-php-sdk/issues
source : https://github.com/aliyun/aliyun-oss-php-sdk/tree/v2.4.2

autoload
psr-4
OSS\ => src/OSS

requires
php >=5.3

requires (dev)
phpunit/phpunit *
satooshi/php-coveralls *
@sxin0
Copy link
Author

sxin0 commented Aug 25, 2021

@huiguangjun
一个问题几个月没人处理,咋滴忙着上热点新闻呢?说好的福报呢

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