aws-sdk-resources 2.2.31 → 2.2.32
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 57c6c50c557eb4ceeb67b3e529051f7df6b27cef
|
4
|
+
data.tar.gz: 9f5dd5b4952d25a2b7392d09f0d2b1d00f25ba8d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d5513b6e0bbf2d8b664a396e040d2727512188be574a0e122b5fd2cc84719e4d3dc2162ca0dd11b1129a533d15e5b35a28f6d4ec92cd2bc3141e28c391a4310b
|
7
|
+
data.tar.gz: cf738fcde5161bb4739e262e12098e9be61952df4c40d569e18e35854c32610ba92f96fb246590d9f4dfb99e8da4db48f54f10f0691784b23ab3b6a34370b84d
|
@@ -5,7 +5,7 @@ module Aws
|
|
5
5
|
# @api private
|
6
6
|
class ObjectCopier
|
7
7
|
|
8
|
-
# @param [S3::
|
8
|
+
# @param [S3::Object] object
|
9
9
|
def initialize(object, options = {})
|
10
10
|
@object = object
|
11
11
|
@options = options.merge(client: @object.client)
|
@@ -36,7 +36,7 @@ module Aws
|
|
36
36
|
|
37
37
|
def copy_source(source)
|
38
38
|
case source
|
39
|
-
when String then
|
39
|
+
when String then source
|
40
40
|
when Hash
|
41
41
|
src = "#{source[:bucket]}/#{escape(source[:key])}"
|
42
42
|
src += "?versionId=#{source[:version_id]}" if source.key?(:version_id)
|
@@ -120,8 +120,16 @@ module Aws
|
|
120
120
|
|
121
121
|
client = options[:copy_source_client] || @client
|
122
122
|
|
123
|
-
|
124
|
-
|
123
|
+
if vid_match = options[:copy_source].match(/([^\/]+?)\/(.+)\?versionId=(.+)/)
|
124
|
+
bucket, key, version_id = vid_match[1,3]
|
125
|
+
else
|
126
|
+
bucket, key = options[:copy_source].match(/([^\/]+?)\/(.+)/)[1,2]
|
127
|
+
end
|
128
|
+
|
129
|
+
key = CGI.unescape(key)
|
130
|
+
opts = { bucket: bucket, key: key }
|
131
|
+
opts[:version_id] = version_id if version_id
|
132
|
+
client.head_object(opts).content_length
|
125
133
|
end
|
126
134
|
|
127
135
|
def default_part_size(source_size)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: aws-sdk-resources
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.2.
|
4
|
+
version: 2.2.32
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Amazon Web Services
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-04-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: aws-sdk-core
|
@@ -16,14 +16,14 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - '='
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 2.2.
|
19
|
+
version: 2.2.32
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - '='
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: 2.2.
|
26
|
+
version: 2.2.32
|
27
27
|
description: Provides resource oriented interfaces and other higher-level abstractions
|
28
28
|
for many AWS services. This gem is part of the official AWS SDK for Ruby.
|
29
29
|
email:
|