-
Notifications
You must be signed in to change notification settings - Fork 28
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Fix] Obs multipart name extraction fix (#541)
- Loading branch information
1 parent
258608f
commit 58c7a2e
Showing
6 changed files
with
109 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -27,6 +27,7 @@ Open Telekom Cloud related User Guides | |
mrs | ||
modelarts | ||
nat | ||
obs | ||
rds | ||
sfsturbo | ||
smn | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
Object Storage Service (OBS) | ||
============================ | ||
|
||
Object Storage Service (OBS) is an object-based storage service | ||
that provides customers with massive, secure, reliable, | ||
and cost-effective data storage capabilities, such as bucket creation, | ||
modification, and deletion, as well as object upload, download, and deletion. | ||
|
||
.. contents:: Table of Contents | ||
:local: | ||
|
||
Object | ||
------ | ||
|
||
Multipart upload | ||
^^^^^^^^^^^^^^^^ | ||
|
||
This interface is used to create an OBS multipart upload. | ||
:class:`~otcextensions.sdk.obs.v1.obj.Object`. | ||
|
||
.. literalinclude:: ../examples/obs/multipart_upload.py | ||
:lines: 16-33 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
# Licensed under the Apache License, Version 2.0 (the "License"); you may | ||
# not use this file except in compliance with the License. You may obtain | ||
# a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT | ||
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the | ||
# License for the specific language governing permissions and limitations | ||
# under the License. | ||
import openstack | ||
from otcextensions import sdk | ||
""" | ||
Create an multipart upload of a large object | ||
""" | ||
|
||
openstack.enable_logging(True) | ||
conn = openstack.connect(cloud='otc') | ||
sdk.register_otc_extensions(conn) | ||
sdk.get_ak_sk(conn) | ||
|
||
container = conn.obs.create_container( | ||
name='test-multipart', | ||
storage_acl='public-read-write', | ||
storage_class='STANDARD' | ||
) | ||
|
||
obj = conn.obs.upload_object( | ||
name='myfile.zip', | ||
container=container, | ||
segment_size=1400000 | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
fixes: | ||
- | | ||
SDK OBS container headers assigning | ||
- | | ||
SDK OBS object multipart upload fix |