Copy¶
Copy operations.
Obstore provides two API designs for your convenience.
Method API¶
obstore.store.ObjectStoreMethods.copy ¶
Copy an object from one path to another in the same object store.
Refer to the documentation for copy.
obstore.store.ObjectStoreMethods.copy_async
async
¶
Call copy asynchronously.
Refer to the documentation for copy_async.
Functional API¶
obstore.copy ¶
Copy an object from one path to another in the same object store.
Parameters:
-
store(ObjectStore) –The ObjectStore instance to use.
-
from_(str) –Source path
-
to(str) –Destination path
Other Parameters:
-
overwrite(bool) –If
True, if there exists an object at the destination, it will be overwritten.If
False: will copy only if destination is empty. Performs an atomic operation if the underlying object storage supports it. If atomic operations are not supported by the underlying object storage (like S3) it will return an error.Will return an error if the destination already has an object.