cono_storage 0.0.3 → 0.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: c4f70d3595ec870b0f430695e6adb6a83c0136d9
4
- data.tar.gz: d7020d32f0c1b51b0bbd1679d7d32d01d6b0d0bd
3
+ metadata.gz: ce8ea96efedf920f0974d09b95508b8dfb15fca5
4
+ data.tar.gz: cbfa1c6b9570d3a479f9b9a5a8c238e62eaee032
5
5
  SHA512:
6
- metadata.gz: 10069b0075402d145425ff22010438bde92429fe172d64eafa16024f2458498626f4b970c2a2fddefb3216c88bbd1c97beae6a0d3e8fcd8fe5eff528ef363809
7
- data.tar.gz: 7e09b9396a1ac0a48aa34d1c50f4fc993238b83ddee05ef33df60501f569072e8acad02fc8c176556e3f0900db52cdfb4eeca3d3f9c879c0ff460aa7409a376d
6
+ metadata.gz: 56b765b7649d15f5662af3ba1ff108e4ad6a9c0e5252fc447f153816e881f22261df7989db30e087b7b4484f02b49e5ce9855a45c853f4c3719134671d48b78c
7
+ data.tar.gz: 3aef9dd6fef553bfa6f04c1e7cfb25c2cb22f29996b1f24ad09adbcce191821de306a2c4fe561b58ba10e54f08eb3525a65e8b5173572fd84b6b5a44d4fcdbfb
@@ -26,7 +26,7 @@ module ConoStorage
26
26
  @tenant_id = tenant_id
27
27
  @username = username
28
28
  @password = password
29
- @endpoint = endpoint.scan(/\A(http.+\/v1)/).first.first
29
+ @endpoint = endpoint
30
30
  end
31
31
 
32
32
  %w( get head put delete post ).each do |method|
@@ -6,7 +6,7 @@ module ConoStorage
6
6
  # 指定したアカウント及びアカウントが保持するコンテナの詳細を取得します。
7
7
  #
8
8
  def get_account(params: {}, headers: {})
9
- get("/#{@tenant_id}", params, headers)
9
+ get("", params, headers)
10
10
  end
11
11
 
12
12
  # POST(アカウント)
@@ -14,7 +14,7 @@ module ConoStorage
14
14
  # アカウントのメタデータを作成、更新、削除します。
15
15
  #
16
16
  def post_account(params: {}, headers: {})
17
- post("/#{@tenant_id}", params, headers)
17
+ post("", params, headers)
18
18
  end
19
19
 
20
20
  # HEAD(アカウント)
@@ -22,7 +22,7 @@ module ConoStorage
22
22
  # アカウントのメタデータを取得します。
23
23
  #
24
24
  def head_account(params: {}, headers: {})
25
- head("/#{@tenant_id}", params, headers)
25
+ head("", params, headers)
26
26
  end
27
27
 
28
28
  # GET(コンテナ)
@@ -30,7 +30,7 @@ module ConoStorage
30
30
  # コンテナの詳細と、コンテナ内のオブジェクトの一覧を取得します。
31
31
  #
32
32
  def get_container(container, params: {}, headers: {})
33
- get("/#{@tenant_id}/#{container}", params, headers)
33
+ get("/#{container}", params, headers)
34
34
  end
35
35
 
36
36
  # PUT(コンテナ)
@@ -38,7 +38,7 @@ module ConoStorage
38
38
  # コンテナの作成、または既存のコンテナの更新をします。
39
39
  #
40
40
  def put_container(container, params: {}, headers: {})
41
- put("/#{@tenant_id}/#{container}", params, headers)
41
+ put("/#{container}", params, headers)
42
42
  end
43
43
 
44
44
  # DELETE(コンテナ)
@@ -46,7 +46,7 @@ module ConoStorage
46
46
  # コンテナを削除します。
47
47
  #
48
48
  def delete_container(container, params: {}, headers: {})
49
- delete("/#{@tenant_id}/#{container}", params, headers)
49
+ delete("/#{container}", params, headers)
50
50
  end
51
51
 
52
52
  # POST(コンテナ)
@@ -54,7 +54,7 @@ module ConoStorage
54
54
  # コンテナのメタデータを作成、更新、削除します。
55
55
  #
56
56
  def post_container(container, params: {}, headers: {})
57
- post("/#{@tenant_id}/#{container}", params, headers)
57
+ post("/#{container}", params, headers)
58
58
  end
59
59
 
60
60
  # HEAD(コンテナ)
@@ -62,7 +62,7 @@ module ConoStorage
62
62
  # コンテナのメタデータを取得します。
63
63
  #
64
64
  def head_container(container, params: {}, headers: {})
65
- head("/#{@tenant_id}/#{container}", params, headers)
65
+ head("/#{container}", params, headers)
66
66
  end
67
67
 
68
68
  # GET(オブジェクト)
@@ -70,7 +70,7 @@ module ConoStorage
70
70
  # オブジェクトのダウンロードと、オブジェクトのメタデータの取得をします。
71
71
  #
72
72
  def get_object(container, object, params: {}, headers: {})
73
- get("/#{@tenant_id}/#{container}/#{object}", params, headers)
73
+ get("/#{container}/#{object}", params, headers)
74
74
  end
75
75
 
76
76
  # PUT(オブジェクト)
@@ -79,7 +79,7 @@ module ConoStorage
79
79
  # オブジェクトが既に存在する場合はオブジェクト、またはメタデータを置き換えます。
80
80
  #
81
81
  def put_object(container, object, file, params: {}, headers: {})
82
- upload("/#{@tenant_id}/#{container}/#{object}", file, params, headers)
82
+ upload("/#{container}/#{object}", file, params, headers)
83
83
  end
84
84
 
85
85
  # DELETE(オブジェクト)
@@ -87,7 +87,7 @@ module ConoStorage
87
87
  # アップロード済みのオブジェクトを削除します。
88
88
  #
89
89
  def delete_object(container, object, params: {}, headers: {})
90
- delete("/#{@tenant_id}/#{container}/#{object}", params, headers)
90
+ delete("/#{container}/#{object}", params, headers)
91
91
  end
92
92
 
93
93
  # POST(オブジェクト)
@@ -95,7 +95,7 @@ module ConoStorage
95
95
  # オブジェクトにメタデータを付与、またはメタデータを更新します。
96
96
  #
97
97
  def post_object(container, object, params: {}, headers: {})
98
- post("/#{@tenant_id}/#{container}/#{object}", params, headers)
98
+ post("/#{container}/#{object}", params, headers)
99
99
  end
100
100
 
101
101
  # HEAD(オブジェクト)
@@ -103,7 +103,7 @@ module ConoStorage
103
103
  # オブジェクトのメタデータを取得します。
104
104
  #
105
105
  def head_object(container, object, params: {}, headers: {})
106
- head("/#{@tenant_id}/#{container}/#{object}", params, headers)
106
+ head("/#{container}/#{object}", params, headers)
107
107
  end
108
108
  end
109
109
  end
@@ -1,3 +1,3 @@
1
1
  module ConoStorage
2
- VERSION = "0.0.3"
2
+ VERSION = "0.0.4"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cono_storage
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - kkosuge
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-01-29 00:00:00.000000000 Z
11
+ date: 2015-07-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -132,8 +132,9 @@ required_rubygems_version: !ruby/object:Gem::Requirement
132
132
  version: '0'
133
133
  requirements: []
134
134
  rubyforge_project:
135
- rubygems_version: 2.2.2
135
+ rubygems_version: 2.4.5
136
136
  signing_key:
137
137
  specification_version: 4
138
138
  summary: OpenStack Swift Client for ConoHa オブジェクトストレージ
139
139
  test_files: []
140
+ has_rdoc: